[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <fb977502-ec9b-c847-6b9c-049bd226f4b1@infradead.org>
Date: Mon, 31 Jul 2023 16:22:09 -0700
From: Randy Dunlap <rdunlap@...radead.org>
To: Thomas Zimmermann <tzimmermann@...e.de>, deller@....de,
mpe@...erman.id.au, npiggin@...il.com, christophe.leroy@...roup.eu,
sam@...nborg.org, javierm@...hat.com, bagasdotme@...il.com,
rd.dunlab@...il.com, regressions@...mhuis.info,
sfr@...b.auug.org.au
Cc: linux-kernel@...r.kernel.org, linux-fbdev@...r.kernel.org,
linuxppc-dev@...ts.ozlabs.org, regressions@...ts.linux.dev,
linux-next@...r.kernel.org, dri-devel@...ts.freedesktop.org
Subject: Re: [PATCH] fbdev/ps3fb: Build without kernel device
On 7/31/23 10:55, Thomas Zimmermann wrote:
> Use fb_info() to print status message at the end of the probe function,
> which avoids decoding the devices. fb_info() works with or without an
> fbdev kernel device. Fixes the following error:
>
> ../drivers/video/fbdev/ps3fb.c: In function 'ps3fb_probe':
> ../drivers/video/fbdev/ps3fb.c:1172:40: error: 'struct fb_info' has no member named 'dev'
> 1172 | dev_driver_string(info->dev), dev_name(info->dev),
> | ^~
> ../include/linux/dev_printk.h:110:37: note: in definition of macro 'dev_printk_index_wrap'
> 110 | _p_func(dev, fmt, ##__VA_ARGS__); \
> | ^~~~~~~~~~~
> ../drivers/video/fbdev/ps3fb.c:1171:9: note: in expansion of macro 'dev_info'
> 1171 | dev_info(info->device, "%s %s, using %u KiB of video memory\n",
> | ^~~~~~~~
> ../drivers/video/fbdev/ps3fb.c:1172:61: error: 'struct fb_info' has no member named 'dev'
> 1172 | dev_driver_string(info->dev), dev_name(info->dev),
> | ^~
> ../include/linux/dev_printk.h:110:37: note: in definition of macro 'dev_printk_index_wrap'
> 110 | _p_func(dev, fmt, ##__VA_ARGS__); \
> | ^~~~~~~~~~~
> ../drivers/video/fbdev/ps3fb.c:1171:9: note: in expansion of macro 'dev_info'
> 1171 | dev_info(info->device, "%s %s, using %u KiB of video memory\n",
> | ^~~~~~~~
>
> Reported-by: Randy Dunlap <rdunlap@...radead.org>
> Closes: https://lore.kernel.org/lkml/ccc63065-2976-88ef-1211-731330bf2866@infradead.org/
> Signed-off-by: Thomas Zimmermann <tzimmermann@...e.de>
> Fixes: 701d2054fa31 ("fbdev: Make support for userspace interfaces configurable")
> Cc: Michael Ellerman <mpe@...erman.id.au>
> Cc: Sam Ravnborg <sam@...nborg.org>
> Cc: Helge Deller <deller@....de>
> Cc: Javier Martinez Canillas <javierm@...hat.com>
> Cc: Randy Dunlap <rdunlap@...radead.org>
> Cc: Bagas Sanjaya <bagasdotme@...il.com>
> Cc: Thorsten Leemhuis <regressions@...mhuis.info>
> Cc: dri-devel@...ts.freedesktop.org
> Cc: linux-fbdev@...r.kernel.org
> Cc: linuxppc-dev@...ts.ozlabs.org
Acked-by: Randy Dunlap <rdunlap@...radead.org>
Tested-by: Randy Dunlap <rdunlap@...radead.org> # build-tested
Thanks.
> ---
> drivers/video/fbdev/ps3fb.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/video/fbdev/ps3fb.c b/drivers/video/fbdev/ps3fb.c
> index 5aedc30c5f7e..64d291d6b153 100644
> --- a/drivers/video/fbdev/ps3fb.c
> +++ b/drivers/video/fbdev/ps3fb.c
> @@ -1168,9 +1168,7 @@ static int ps3fb_probe(struct ps3_system_bus_device *dev)
>
> ps3_system_bus_set_drvdata(dev, info);
>
> - dev_info(info->device, "%s %s, using %u KiB of video memory\n",
> - dev_driver_string(info->dev), dev_name(info->dev),
> - info->fix.smem_len >> 10);
> + fb_info(info, "using %u KiB of video memory\n", info->fix.smem_len >> 10);
>
> task = kthread_run(ps3fbd, info, DEVICE_NAME);
> if (IS_ERR(task)) {
--
~Randy
Powered by blists - more mailing lists