* [PATCH v2] fbdev/fsl-diu-fb: Fix srapse warning due to virt_to_phys() prototype change
@ 2023-11-21 0:01 Stanislav Kinsburskii
2023-11-25 8:57 ` Helge Deller
0 siblings, 1 reply; 2+ messages in thread
From: Stanislav Kinsburskii @ 2023-11-21 0:01 UTC (permalink / raw)
To: timur, deller, linux-fbdev, dri-devel, linux-kernel
Explicitly cast __iomem pointer to const void* with __force to fix the
following warning:
incorrect type in argument 1 (different address spaces)
expected void const volatile *address
got char [noderef] __iomem *screen_base
Signed-off-by: Stanislav Kinsburskii <skinsburskii@linux.microsoft.com>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202311161120.BgyxTBMQ-lkp@intel.com/
---
drivers/video/fbdev/fsl-diu-fb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/video/fbdev/fsl-diu-fb.c b/drivers/video/fbdev/fsl-diu-fb.c
index 7fbd9f069ac2..b0fda5bd1964 100644
--- a/drivers/video/fbdev/fsl-diu-fb.c
+++ b/drivers/video/fbdev/fsl-diu-fb.c
@@ -877,7 +877,7 @@ static int map_video_memory(struct fb_info *info)
}
mutex_lock(&info->mm_lock);
info->screen_base = p;
- info->fix.smem_start = virt_to_phys(info->screen_base);
+ info->fix.smem_start = virt_to_phys((__force const void *)info->screen_base);
info->fix.smem_len = smem_len;
mutex_unlock(&info->mm_lock);
info->screen_size = info->fix.smem_len;
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v2] fbdev/fsl-diu-fb: Fix srapse warning due to virt_to_phys() prototype change
2023-11-21 0:01 [PATCH v2] fbdev/fsl-diu-fb: Fix srapse warning due to virt_to_phys() prototype change Stanislav Kinsburskii
@ 2023-11-25 8:57 ` Helge Deller
0 siblings, 0 replies; 2+ messages in thread
From: Helge Deller @ 2023-11-25 8:57 UTC (permalink / raw)
To: Stanislav Kinsburskii, timur, linux-fbdev, dri-devel, linux-kernel
On 11/21/23 01:01, Stanislav Kinsburskii wrote:
> Explicitly cast __iomem pointer to const void* with __force to fix the
> following warning:
>
> incorrect type in argument 1 (different address spaces)
> expected void const volatile *address
> got char [noderef] __iomem *screen_base
>
> Signed-off-by: Stanislav Kinsburskii <skinsburskii@linux.microsoft.com>
> Reported-by: kernel test robot <lkp@intel.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202311161120.BgyxTBMQ-lkp@intel.com/
> ---
> drivers/video/fbdev/fsl-diu-fb.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/video/fbdev/fsl-diu-fb.c b/drivers/video/fbdev/fsl-diu-fb.c
> index 7fbd9f069ac2..b0fda5bd1964 100644
> --- a/drivers/video/fbdev/fsl-diu-fb.c
> +++ b/drivers/video/fbdev/fsl-diu-fb.c
> @@ -877,7 +877,7 @@ static int map_video_memory(struct fb_info *info)
> }
> mutex_lock(&info->mm_lock);
> info->screen_base = p;
> - info->fix.smem_start = virt_to_phys(info->screen_base);
> + info->fix.smem_start = virt_to_phys((__force const void *)info->screen_base);
> info->fix.smem_len = smem_len;
> mutex_unlock(&info->mm_lock);
> info->screen_size = info->fix.smem_len;
applied to fbdev git tree (with some typos corrected).
Helge
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-11-25 8:57 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-21 0:01 [PATCH v2] fbdev/fsl-diu-fb: Fix srapse warning due to virt_to_phys() prototype change Stanislav Kinsburskii
2023-11-25 8:57 ` Helge Deller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).