mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] video: fbdev: s3c-fb: fix sparse warnings about using incorrect types
       [not found] <CGME20190627125803eucas1p1eb6a37f5fa96fd732e41ab1501367de5@eucas1p1.samsung.com>
@ 2019-06-27 12:58 ` Bartlomiej Zolnierkiewicz
  2019-06-28  5:50   ` Jingoo Han
  0 siblings, 1 reply; 3+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2019-06-27 12:58 UTC (permalink / raw)
  To: linux-fbdev, dri-devel, linux-kernel; +Cc: Jingoo Han

Use ->screen_buffer instead of ->screen_base to fix sparse warnings.

[ Please see commit 17a7b0b4d974 ("fb.h: Provide alternate screen_base
  pointer") for details. ]

Reported-by: kbuild test robot <lkp@intel.com>
Cc: Jingoo Han <jingoohan1@gmail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
---
 drivers/video/fbdev/s3c-fb.c |   12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

Index: b/drivers/video/fbdev/s3c-fb.c
===================================================================
--- a/drivers/video/fbdev/s3c-fb.c
+++ b/drivers/video/fbdev/s3c-fb.c
@@ -1105,14 +1105,14 @@ static int s3c_fb_alloc_memory(struct s3
 
 	dev_dbg(sfb->dev, "want %u bytes for window\n", size);
 
-	fbi->screen_base = dma_alloc_wc(sfb->dev, size, &map_dma, GFP_KERNEL);
-	if (!fbi->screen_base)
+	fbi->screen_buffer = dma_alloc_wc(sfb->dev, size, &map_dma, GFP_KERNEL);
+	if (!fbi->screen_buffer)
 		return -ENOMEM;
 
 	dev_dbg(sfb->dev, "mapped %x to %p\n",
-		(unsigned int)map_dma, fbi->screen_base);
+		(unsigned int)map_dma, fbi->screen_buffer);
 
-	memset(fbi->screen_base, 0x0, size);
+	memset(fbi->screen_buffer, 0x0, size);
 	fbi->fix.smem_start = map_dma;
 
 	return 0;
@@ -1129,9 +1129,9 @@ static void s3c_fb_free_memory(struct s3
 {
 	struct fb_info *fbi = win->fbinfo;
 
-	if (fbi->screen_base)
+	if (fbi->screen_buffer)
 		dma_free_wc(sfb->dev, PAGE_ALIGN(fbi->fix.smem_len),
-		            fbi->screen_base, fbi->fix.smem_start);
+			    fbi->screen_buffer, fbi->fix.smem_start);
 }
 
 /**

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

* Re: [PATCH] video: fbdev: s3c-fb: fix sparse warnings about using incorrect types
  2019-06-27 12:58 ` [PATCH] video: fbdev: s3c-fb: fix sparse warnings about using incorrect types Bartlomiej Zolnierkiewicz
@ 2019-06-28  5:50   ` Jingoo Han
  2019-06-28 10:37     ` Bartlomiej Zolnierkiewicz
  0 siblings, 1 reply; 3+ messages in thread
From: Jingoo Han @ 2019-06-28  5:50 UTC (permalink / raw)
  To: Bartlomiej Zolnierkiewicz, linux-fbdev, dri-devel, linux-kernel
  Cc: Han Jingoo

On 6/27/19, 9:58 PM, Bartlomiej Zolnierkiewicz wrote:
> 
> Use ->screen_buffer instead of ->screen_base to fix sparse warnings.
>
> [ Please see commit 17a7b0b4d974 ("fb.h: Provide alternate screen_base
>   pointer") for details. ]
>
> Reported-by: kbuild test robot <lkp@intel.com>
> Cc: Jingoo Han <jingoohan1@gmail.com>

Acked-by: Jingoo Han <jingoohan1@gmail.com>

Best regards,
Jingoo Han

> Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
> ---
>  drivers/video/fbdev/s3c-fb.c |   12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
>
> Index: b/drivers/video/fbdev/s3c-fb.c
> ===================================================================
> --- a/drivers/video/fbdev/s3c-fb.c
> +++ b/drivers/video/fbdev/s3c-fb.c
> @@ -1105,14 +1105,14 @@ static int s3c_fb_alloc_memory(struct s3
>  
>  	dev_dbg(sfb->dev, "want %u bytes for window\n", size);
>  
> -	fbi->screen_base = dma_alloc_wc(sfb->dev, size, &map_dma, GFP_KERNEL);
> -	if (!fbi->screen_base)
> +	fbi->screen_buffer = dma_alloc_wc(sfb->dev, size, &map_dma, GFP_KERNEL);
> +	if (!fbi->screen_buffer)
>  		return -ENOMEM;
>  
>  	dev_dbg(sfb->dev, "mapped %x to %p\n",
> -		(unsigned int)map_dma, fbi->screen_base);
> +		(unsigned int)map_dma, fbi->screen_buffer);
>  
> -	memset(fbi->screen_base, 0x0, size);
> +	memset(fbi->screen_buffer, 0x0, size);
>  	fbi->fix.smem_start = map_dma;
>  
>  	return 0;
> @@ -1129,9 +1129,9 @@ static void s3c_fb_free_memory(struct s3
>  {
>  	struct fb_info *fbi = win->fbinfo;
>  
> -	if (fbi->screen_base)
> +	if (fbi->screen_buffer)
>  		dma_free_wc(sfb->dev, PAGE_ALIGN(fbi->fix.smem_len),
> -		            fbi->screen_base, fbi->fix.smem_start);
> +			    fbi->screen_buffer, fbi->fix.smem_start);
>  }
>  
>  /**

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

* Re: [PATCH] video: fbdev: s3c-fb: fix sparse warnings about using incorrect types
  2019-06-28  5:50   ` Jingoo Han
@ 2019-06-28 10:37     ` Bartlomiej Zolnierkiewicz
  0 siblings, 0 replies; 3+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2019-06-28 10:37 UTC (permalink / raw)
  To: Jingoo Han; +Cc: linux-fbdev, dri-devel, linux-kernel


On 6/28/19 7:50 AM, Jingoo Han wrote:
> On 6/27/19, 9:58 PM, Bartlomiej Zolnierkiewicz wrote:
>>
>> Use ->screen_buffer instead of ->screen_base to fix sparse warnings.
>>
>> [ Please see commit 17a7b0b4d974 ("fb.h: Provide alternate screen_base
>>   pointer") for details. ]
>>
>> Reported-by: kbuild test robot <lkp@intel.com>
>> Cc: Jingoo Han <jingoohan1@gmail.com>
> 
> Acked-by: Jingoo Han <jingoohan1@gmail.com>

Thanks, I queued the patch for v5.3.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

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

end of thread, other threads:[~2019-06-28 10:37 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20190627125803eucas1p1eb6a37f5fa96fd732e41ab1501367de5@eucas1p1.samsung.com>
2019-06-27 12:58 ` [PATCH] video: fbdev: s3c-fb: fix sparse warnings about using incorrect types Bartlomiej Zolnierkiewicz
2019-06-28  5:50   ` Jingoo Han
2019-06-28 10:37     ` Bartlomiej Zolnierkiewicz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®