All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/hisilicon: get the BO from drm_fb rather than hibmc_fb
@ 2019-12-31  6:50 ` Tian Tao
  0 siblings, 0 replies; 4+ messages in thread
From: Tian Tao @ 2019-12-31  6:50 UTC (permalink / raw)
  To: puck.chen, airlied, daniel, tzimmermann, kraxel,
	alexander.deucher, tglx, dri-devel, xinliang.liu, linux-kernel
  Cc: linuxarm

since we can get the BO from drm_fb rather than hibmc_fb,do not need
the hibmc_fb.so we delete the local variable hibmc_fb.

Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
Signed-off-by: Gong junjie <gongjunjie2@huawei.com>
---
 drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
index 6bf4334..12b38ac 100644
--- a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
+++ b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
@@ -105,14 +105,12 @@ static void hibmc_plane_atomic_update(struct drm_plane *plane,
 	s64 gpu_addr = 0;
 	unsigned int line_l;
 	struct hibmc_drm_private *priv = plane->dev->dev_private;
-	struct hibmc_framebuffer *hibmc_fb;
 	struct drm_gem_vram_object *gbo;
 
 	if (!state->fb)
 		return;
 
-	hibmc_fb = to_hibmc_framebuffer(state->fb);
-	gbo = drm_gem_vram_of_gem(hibmc_fb->obj);
+	gbo = drm_gem_vram_of_gem(state->fb->obj[0]);
 
 	gpu_addr = drm_gem_vram_offset(gbo);
 	if (WARN_ON_ONCE(gpu_addr < 0))
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] drm/hisilicon: get the BO from drm_fb rather than hibmc_fb
@ 2019-12-31  6:50 ` Tian Tao
  0 siblings, 0 replies; 4+ messages in thread
From: Tian Tao @ 2019-12-31  6:50 UTC (permalink / raw)
  To: puck.chen, airlied, daniel, tzimmermann, kraxel,
	alexander.deucher, tglx, dri-devel, xinliang.liu, linux-kernel
  Cc: linuxarm

since we can get the BO from drm_fb rather than hibmc_fb,do not need
the hibmc_fb.so we delete the local variable hibmc_fb.

Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
Signed-off-by: Gong junjie <gongjunjie2@huawei.com>
---
 drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
index 6bf4334..12b38ac 100644
--- a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
+++ b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
@@ -105,14 +105,12 @@ static void hibmc_plane_atomic_update(struct drm_plane *plane,
 	s64 gpu_addr = 0;
 	unsigned int line_l;
 	struct hibmc_drm_private *priv = plane->dev->dev_private;
-	struct hibmc_framebuffer *hibmc_fb;
 	struct drm_gem_vram_object *gbo;
 
 	if (!state->fb)
 		return;
 
-	hibmc_fb = to_hibmc_framebuffer(state->fb);
-	gbo = drm_gem_vram_of_gem(hibmc_fb->obj);
+	gbo = drm_gem_vram_of_gem(state->fb->obj[0]);
 
 	gpu_addr = drm_gem_vram_offset(gbo);
 	if (WARN_ON_ONCE(gpu_addr < 0))
-- 
2.7.4

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] drm/hisilicon: get the BO from drm_fb rather than hibmc_fb
  2019-12-31  6:50 ` Tian Tao
@ 2020-01-06 13:04   ` Thomas Zimmermann
  -1 siblings, 0 replies; 4+ messages in thread
From: Thomas Zimmermann @ 2020-01-06 13:04 UTC (permalink / raw)
  To: Tian Tao, puck.chen, airlied, daniel, kraxel, alexander.deucher,
	tglx, dri-devel, xinliang.liu, linux-kernel
  Cc: linuxarm


[-- Attachment #1.1: Type: text/plain, Size: 1740 bytes --]

Hi

Am 31.12.19 um 07:50 schrieb Tian Tao:
> since we can get the BO from drm_fb rather than hibmc_fb,do not need
> the hibmc_fb.so we delete the local variable hibmc_fb.
> 
> Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
> Signed-off-by: Gong junjie <gongjunjie2@huawei.com>
> ---
>  drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
> index 6bf4334..12b38ac 100644
> --- a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
> +++ b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
> @@ -105,14 +105,12 @@ static void hibmc_plane_atomic_update(struct drm_plane *plane,
>  	s64 gpu_addr = 0;
>  	unsigned int line_l;
>  	struct hibmc_drm_private *priv = plane->dev->dev_private;
> -	struct hibmc_framebuffer *hibmc_fb;
>  	struct drm_gem_vram_object *gbo;
>  
>  	if (!state->fb)
>  		return;
>  
> -	hibmc_fb = to_hibmc_framebuffer(state->fb);
> -	gbo = drm_gem_vram_of_gem(hibmc_fb->obj);
> +	gbo = drm_gem_vram_of_gem(state->fb->obj[0]);
>  
>  	gpu_addr = drm_gem_vram_offset(gbo);
>  	if (WARN_ON_ONCE(gpu_addr < 0))
> 

Thanks for the patch. This has meanwhile been fixed as part of

	commit 3e10d2ffd245f996c36f87b0a8027a719e6135c3
	Author: Thomas Zimmermann <tzimmermann@suse.de>
	Date:   Tue Dec 3 09:38:16 2019 +0100

	    drm/hisilicon/hibmc: Replace struct hibmc_framebuffer with
		generic code

Best regards
Thomas

-- 
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Maxfeldstr. 5, 90409 Nürnberg, Germany
(HRB 36809, AG Nürnberg)
Geschäftsführer: Felix Imendörffer


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] drm/hisilicon: get the BO from drm_fb rather than hibmc_fb
@ 2020-01-06 13:04   ` Thomas Zimmermann
  0 siblings, 0 replies; 4+ messages in thread
From: Thomas Zimmermann @ 2020-01-06 13:04 UTC (permalink / raw)
  To: Tian Tao, puck.chen, airlied, daniel, kraxel, alexander.deucher,
	tglx, dri-devel, xinliang.liu, linux-kernel
  Cc: linuxarm


[-- Attachment #1.1.1: Type: text/plain, Size: 1740 bytes --]

Hi

Am 31.12.19 um 07:50 schrieb Tian Tao:
> since we can get the BO from drm_fb rather than hibmc_fb,do not need
> the hibmc_fb.so we delete the local variable hibmc_fb.
> 
> Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
> Signed-off-by: Gong junjie <gongjunjie2@huawei.com>
> ---
>  drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
> index 6bf4334..12b38ac 100644
> --- a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
> +++ b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
> @@ -105,14 +105,12 @@ static void hibmc_plane_atomic_update(struct drm_plane *plane,
>  	s64 gpu_addr = 0;
>  	unsigned int line_l;
>  	struct hibmc_drm_private *priv = plane->dev->dev_private;
> -	struct hibmc_framebuffer *hibmc_fb;
>  	struct drm_gem_vram_object *gbo;
>  
>  	if (!state->fb)
>  		return;
>  
> -	hibmc_fb = to_hibmc_framebuffer(state->fb);
> -	gbo = drm_gem_vram_of_gem(hibmc_fb->obj);
> +	gbo = drm_gem_vram_of_gem(state->fb->obj[0]);
>  
>  	gpu_addr = drm_gem_vram_offset(gbo);
>  	if (WARN_ON_ONCE(gpu_addr < 0))
> 

Thanks for the patch. This has meanwhile been fixed as part of

	commit 3e10d2ffd245f996c36f87b0a8027a719e6135c3
	Author: Thomas Zimmermann <tzimmermann@suse.de>
	Date:   Tue Dec 3 09:38:16 2019 +0100

	    drm/hisilicon/hibmc: Replace struct hibmc_framebuffer with
		generic code

Best regards
Thomas

-- 
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Maxfeldstr. 5, 90409 Nürnberg, Germany
(HRB 36809, AG Nürnberg)
Geschäftsführer: Felix Imendörffer


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

[-- Attachment #2: Type: text/plain, Size: 160 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-01-06 13:04 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-31  6:50 [PATCH] drm/hisilicon: get the BO from drm_fb rather than hibmc_fb Tian Tao
2019-12-31  6:50 ` Tian Tao
2020-01-06 13:04 ` Thomas Zimmermann
2020-01-06 13:04   ` Thomas Zimmermann

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.