summaryrefslogtreecommitdiff
path: root/drivers/video/fbdev
AgeCommit message (Collapse)AuthorFilesLines
2023-08-04fbdev/grvga: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-18-tzimmermann@suse.de
2023-08-04fbdev/goldfishfb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-17-tzimmermann@suse.de
2023-08-04fbdev/geode/lxfb: Use fbdev I/O helpersThomas Zimmermann2-7/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Cc: Andres Salomon <dilinger@queued.net> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-16-tzimmermann@suse.de
2023-08-04fbdev/geode/gxfb: Use fbdev I/O helpersThomas Zimmermann2-7/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Cc: Andres Salomon <dilinger@queued.net> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-15-tzimmermann@suse.de
2023-08-04fbdev/geode/gx1fb: Use fbdev I/O helpersThomas Zimmermann2-7/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Cc: Andres Salomon <dilinger@queued.net> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-14-tzimmermann@suse.de
2023-08-04fbdev/g364fb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-13-tzimmermann@suse.de
2023-08-04fbdev/fsl-diu-fb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Cc: Timur Tabi <timur@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-12-tzimmermann@suse.de
2023-08-04fbdev/fm2fb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-11-tzimmermann@suse.de
2023-08-04fbdev/efifb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Cc: Peter Jones <pjones@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-10-tzimmermann@suse.de
2023-08-04fbdev/da8xx-fb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-9-tzimmermann@suse.de
2023-08-04fbdev/chipsfb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-8-tzimmermann@suse.de
2023-08-04fbdev/carminefb: Use fbdev I/O helpersThomas Zimmermann2-7/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-7-tzimmermann@suse.de
2023-08-04fbdev/aty128fb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-6-tzimmermann@suse.de
2023-08-04fbdev/atmel_lcdfb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Cc: Nicolas Ferre <nicolas.ferre@microchip.com> Cc: Alexandre Belloni <alexandre.belloni@bootlin.com> Cc: Claudiu Beznea <claudiu.beznea@microchip.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-5-tzimmermann@suse.de
2023-08-04fbdev/asiliantfb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-4-tzimmermann@suse.de
2023-08-04fbdev/acornfb: Use fbdev I/O helpersThomas Zimmermann2-6/+2
Set struct fb_ops and with FB_DEFAULT_IOMEM_OPS, fbdev's initializer for I/O memory. Sets the callbacks to the cfb_ and fb_io_ functions. Select the correct modules with Kconfig's FB_IOMEM_HELPERS token. The macro and token set the currently selected values, so there is no functional change. v3: * use _IOMEM_ in commit message v2: * updated to use _IOMEM_ tokens Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230803184034.6456-3-tzimmermann@suse.de
2023-08-03fbdev/ps3fb: Build without kernel deviceThomas Zimmermann1-3/+1
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@infradead.org> Closes: https://lore.kernel.org/lkml/ccc63065-2976-88ef-1211-731330bf2866@infradead.org/ Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Fixes: 701d2054fa31 ("fbdev: Make support for userspace interfaces configurable") Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Sam Ravnborg <sam@ravnborg.org> Cc: Helge Deller <deller@gmx.de> Cc: Javier Martinez Canillas <javierm@redhat.com> Cc: Randy Dunlap <rdunlap@infradead.org> Cc: Bagas Sanjaya <bagasdotme@gmail.com> Cc: Thorsten Leemhuis <regressions@leemhuis.info> Cc: dri-devel@lists.freedesktop.org Cc: linux-fbdev@vger.kernel.org Cc: linuxppc-dev@lists.ozlabs.org Acked-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Randy Dunlap <rdunlap@infradead.org> Tested-by: Randy Dunlap <rdunlap@infradead.org> # build-tested Link: https://patchwork.freedesktop.org/patch/msgid/20230731175535.11345-1-tzimmermann@suse.de
2023-08-03fbcon: Make fbcon_registered_fb and fbcon_num_registered_fb staticGUO Zihua1-2/+2
fbcon_registered_fb and fbcon_num_registered_fb is not referred outside drivers/video/fbdev/core/fbcon.c, so make them static. Signed-off-by: GUO Zihua <guozihua@huawei.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: https://patchwork.freedesktop.org/patch/msgid/20230803020939.491-1-guozihua@huawei.com
2023-07-31fbdev: Align deferred I/O with naming of helpersThomas Zimmermann5-15/+15
Deferred-I/O generator macros generate callbacks for struct fb_ops that operate on memory ranges in I/O address space or system address space. Rename the macros to use the _IOMEM_ and _SYSMEM_ infixes of their underlying helpers. Adapt all users. No functional changes. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230729193157.15446-5-tzimmermann@suse.de
2023-07-31fbdev: Use _DMAMEM_ infix for DMA-memory helpersThomas Zimmermann1-1/+1
Change the infix for fbdev's DMA-memory helpers from _DMA_ to _DMAMEM_. The helpers perform operations within DMA-able memory, but they don't perform DMA operations. Naming should make this clear. Adapt all users. No functional changes. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230729193157.15446-4-tzimmermann@suse.de
2023-07-31fbdev: Use _SYSMEM_ infix for system-memory helpersThomas Zimmermann2-8/+8
Change the infix for fbdev's system-memory helpers from _SYS_ to _SYSMEM_. The helpers perform operations within system memory, but not on the state of the operating system itself. Naming should make this clear. Adapt all users. No functional changes. Suggested-by: Helge Deller <deller@gmx.de> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230729193157.15446-3-tzimmermann@suse.de
2023-07-31fbdev: Use _IOMEM_ infix for I/O-memory helpersThomas Zimmermann1-1/+1
Change the infix for fbdev's I/O-memory helpers from _IO_ to _IOMEM_ to distiguish them from other types of I/O, such as file operations. The helpers operate on memory ranges in the I/O address space and the naming should make this clear. Adapt all users. No functional changes. Suggested-by: Helge Deller <deller@gmx.de> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230729193157.15446-2-tzimmermann@suse.de
2023-07-28Revert "fbcon: Use kzalloc() in fbcon_prepare_logo()"Geert Uytterhoeven1-1/+1
This reverts commit a6a00d7e8ffd78d1cdb7a43f1278f081038c638f. This commit is redundant, as the root cause that resulted in a false positive was fixed by commit 27f644dc5a77f8d9 ("x86: kmsan: use C versions of memset16/memset32/memset64"). Closes: https://lore.kernel.org/r/CAMuHMdUH4CU9EfoirSxjivg08FDimtstn7hizemzyQzYeq6b6g@mail.gmail.com/ Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Javier Martinez Canillas <javierm@redhat.com> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/bd8b71bb13af21cc48af40349db440f794336d3a.1690535849.git.geert+renesas@glider.be
2023-07-24fbdev: Add fb_ops init macros for framebuffers in DMA-able memoryThomas Zimmermann1-0/+8
Add initializer macros for struct fb_ops for framebuffers in DMA-able memory areas. Also add a corresponding Kconfig token. As of now, this is equivalent to system framebuffers and mostly useful for labeling drivers correctly. A later patch may add a generic DMA-specific mmap operation. Linux offers a number of dma_mmap_*() helpers for different use cases. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Javier Martinez Canillas <javierm@redhat.com> Acked-by: Maxime Ripard <mripard@kernel.org> Cc: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230707083422.18691-2-tzimmermann@suse.de
2023-07-24fbdev: Document that framebuffer_alloc() returns zero'ed dataThomas Zimmermann1-1/+2
Most fbdev drivers depend on framebuffer_alloc() to initialize the allocated memory to 0. Document this guarantee. v3: * slightly reword the sentence (Miguel) Suggested-by: Miguel Ojeda <ojeda@kernel.org> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Miguel Ojeda <ojeda@kernel.org> Reviewed-by: Sui Jingfeng <suijingfeng@loongson.cn> Cc: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-19-tzimmermann@suse.de
2023-07-24fbdev/pxafb: Remove flag FBINFO_FLAG_DEFAULTThomas Zimmermann1-1/+0
The flag FBINFO_FLAG_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by devm_kzalloc(). So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-17-tzimmermann@suse.de
2023-07-24fbdev/atafb: Remove flag FBINFO_FLAG_DEFAULTThomas Zimmermann1-1/+0
The flag FBINFO_FLAG_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by a static declaration. So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-16-tzimmermann@suse.de
2023-07-24fbdev: Remove FBINFO_FLAG_DEFAULT from framebuffer_alloc()'ed structsThomas Zimmermann24-29/+10
The flag FBINFO_FLAG_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by framebuffer_alloc(). So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v4: * clarify commit message (Geert, Dan) v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Jaya Kumar <jayalk@intworks.biz> Cc: Helge Deller <deller@gmx.de> Cc: Peter Jones <pjones@redhat.com> Cc: Sascha Hauer <s.hauer@pengutronix.de> Cc: Pengutronix Kernel Team <kernel@pengutronix.de> Cc: Shawn Guo <shawnguo@kernel.org> Cc: Fabio Estevam <festevam@gmail.com> Cc: NXP Linux Team <linux-imx@nxp.com> Cc: Maik Broemme <mbroemme@libmpq.org> Cc: Jingoo Han <jingoohan1@gmail.com> Cc: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Cc: Teddy Wang <teddy.wang@siliconmotion.com> Cc: Michal Januszewski <spock@gentoo.org> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-15-tzimmermann@suse.de
2023-07-24fbdev: Remove FBINFO_FLAG_DEFAULT from kzalloc()'ed structsThomas Zimmermann2-4/+2
The flag FBINFO_FLAG_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by kzalloc(). So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v4: * clarify commit message (Geert, Dan) v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-14-tzimmermann@suse.de
2023-07-24fbdev/fsl-diu-fb: Remove flag FBINFO_DEFAULTThomas Zimmermann1-1/+1
The flag FBINFO_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by dmam_alloc_coherent(__GFP_ZERO). So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Timur Tabi <timur@kernel.org> Cc: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-7-tzimmermann@suse.de
2023-07-24fbdev: Remove FBINFO_DEFAULT from framebuffer_alloc()'ed structsThomas Zimmermann64-81/+41
The flag FBINFO_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by framebuffer_alloc(). So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v4: * clarify commit message (Geert, Dan) v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Helge Deller <deller@gmx.de> Cc: Nicolas Ferre <nicolas.ferre@microchip.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Ferenc Bakonyi <fero@drama.obuda.kando.hu> Cc: "K. Y. Srinivasan" <kys@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Cc: Wei Liu <wei.liu@kernel.org> Cc: Dexuan Cui <decui@microsoft.com> Cc: Antonino Daplas <adaplas@gmail.com> Cc: Maik Broemme <mbroemme@libmpq.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Nicholas Piggin <npiggin@gmail.com> Cc: Christophe Leroy <christophe.leroy@csgroup.eu> Cc: Kristoffer Ericson <kristoffer.ericson@gmail.com> Cc: Hans de Goede <hdegoede@redhat.com> Cc: Steve Glendinning <steve.glendinning@shawell.net> Cc: Bernie Thompson <bernie@plugable.com> Cc: Florian Tobias Schandinat <FlorianSchandinat@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-6-tzimmermann@suse.de
2023-07-24fbdev: Remove FBINFO_DEFAULT from devm_kzalloc()'ed structsThomas Zimmermann4-5/+1
The flag FBINFO_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by devm_kzalloc(). So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v4: * clarify commit message (Geert, Dan) v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-5-tzimmermann@suse.de
2023-07-24fbdev: Remove FBINFO_DEFAULT from kzalloc()'ed structsThomas Zimmermann5-6/+4
The flag FBINFO_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by kzalloc(). So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v4: * clarify commit message (Geert, Dan) v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Helge Deller <deller@gmx.de> Cc: Russell King <linux@armlinux.org.uk> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-4-tzimmermann@suse.de
2023-07-24fbdev: Remove FBINFO_DEFAULT from static structsThomas Zimmermann6-6/+3
The flag FBINFO_DEFAULT is 0 and has no effect, as struct fbinfo.flags has been allocated to zero by a static declaration. So do not set it. Flags should signal differences from the default values. After cleaning up all occurrences of FBINFO_DEFAULT, the token will be removed. v4: * clarify commit message (Geert, Dan) v2: * fix commit message (Miguel) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Cc: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230715185343.7193-3-tzimmermann@suse.de
2023-07-24Merge drm/drm-next into drm-misc-nextThomas Zimmermann11-24/+57
Backmerging to get v6.5-rc2. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
2023-07-22fbdev: Split frame buffer support in FB and FB_CORE symbolsJavier Martinez Canillas3-19/+31
Currently the CONFIG_FB option has to be enabled even if no legacy fbdev drivers are needed (e.g: only to have support for framebuffer consoles). The DRM subsystem has a fbdev emulation layer, but depends on CONFIG_FB and so it can only be enabled if that dependency is enabled as well. That means fbdev drivers have to be explicitly disabled if users want to enable CONFIG_FB, only to use fbcon and/or the DRM fbdev emulation layer. This patch introduces a non-visible CONFIG_FB_CORE symbol that could be enabled just to have core support needed for CONFIG_DRM_FBDEV_EMULATION, allowing CONFIG_FB to be disabled (and automatically disabling all the fbdev drivers). Nothing from fb_backlight.o and fbmon.o is used by the DRM fbdev emulation layer so these two objects can be compiled out when CONFIG_FB is disabled. Signed-off-by: Javier Martinez Canillas <javierm@redhat.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Tested-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230719081544.741051-4-javierm@redhat.com
2023-07-22fbdev: Move core fbdev symbols to a separate Kconfig fileJavier Martinez Canillas2-185/+188
The drivers/video/fbdev/Kconfig defines both symbols for fbdev drivers and core fbdev symbols, that can be enabled independently of the fbdev drivers. Split the Kconfig in two, one that only has the symbols for fbdev drivers and another one that contains the fbdev core symbols. Suggested-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Tested-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230719081544.741051-3-javierm@redhat.com
2023-07-17Merge tag 'drm-misc-next-2023-07-13' of ↵Daniel Vetter33-1088/+964
git://anongit.freedesktop.org/drm/drm-misc into drm-next drm-misc-next for v6.6: UAPI Changes: * fbdev: * Make fbdev userspace interfaces optional; only leaves the framebuffer console active * prime: * Support dma-buf self-import for all drivers automatically: improves support for many userspace compositors Cross-subsystem Changes: * backlight: * Fix interaction with fbdev in several drivers * base: Convert struct platform.remove to return void; part of a larger, tree-wide effort * dma-buf: Acquire reservation lock for mmap() in exporters; part of an on-going effort to simplify locking around dma-bufs * fbdev: * Use Linux device instead of fbdev device in many places * Use deferred-I/O helper macros in various drivers * i2c: Convert struct i2c from .probe_new to .probe; part of a larger, tree-wide effort * video: * Avoid including <linux/screen_info.h> Core Changes: * atomic: * Improve logging * prime: * Remove struct drm_driver.gem_prime_mmap plus driver updates: all drivers now implement this callback with drm_gem_prime_mmap() * gem: * Support execution contexts: provides locking over multiple GEM objects * ttm: * Support init_on_free * Swapout fixes Driver Changes: * accel: * ivpu: MMU updates; Support debugfs * ast: * Improve device-model detection * Cleanups * bridge: * dw-hdmi: Improve support for YUV420 bus format * dw-mipi-dsi: Fix enable/disable of DSI controller * lt9611uxc: Use MODULE_FIRMWARE() * ps8640: Remove broken EDID code * samsung-dsim: Fix command transfer * tc358764: Handle HS/VS polarity; Use BIT() macro; Various cleanups * Cleanups * ingenic: * Kconfig REGMAP fixes * loongson: * Support display controller * mgag200: * Minor fixes * mxsfb: * Support disabling overlay planes * nouveau: * Improve VRAM detection * Various fixes and cleanups * panel: * panel-edp: Support AUO B116XAB01.4 * Support Visionox R66451 plus DT bindings * Cleanups * ssd130x: * Support per-controller default resolution plus DT bindings * Reduce memory-allocation overhead * Cleanups * tidss: * Support TI AM625 plus DT bindings * Implement new connector model plus driver updates * vkms * Improve write-back support * Documentation fixes Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> From: Thomas Zimmermann <tzimmermann@suse.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230713090830.GA23281@linux-uq9g
2023-07-11fbdev/hyperv_fb: Include <linux/screen_info.h>Thomas Zimmermann1-0/+1
Include <linux/screen_info.h> to get the global screen_info state. Fixes the following errors: >> drivers/video/fbdev/hyperv_fb.c:1033:10: error: use of undeclared identifier 'screen_info' 1033 | base = screen_info.lfb_base; | ^ drivers/video/fbdev/hyperv_fb.c:1034:10: error: use of undeclared identifier 'screen_info' 1034 | size = screen_info.lfb_size; | ^ >> drivers/video/fbdev/hyperv_fb.c:1080:3: error: must use 'struct' tag to refer to type 'screen_info' 1080 | screen_info.lfb_size = 0; | ^ | struct >> drivers/video/fbdev/hyperv_fb.c:1080:14: error: expected identifier or '(' 1080 | screen_info.lfb_size = 0; | ^ drivers/video/fbdev/hyperv_fb.c:1081:3: error: must use 'struct' tag to refer to type 'screen_info' 1081 | screen_info.lfb_base = 0; | ^ | struct drivers/video/fbdev/hyperv_fb.c:1081:14: error: expected identifier or '(' 1081 | screen_info.lfb_base = 0; | ^ drivers/video/fbdev/hyperv_fb.c:1082:3: error: must use 'struct' tag to refer to type 'screen_info' 1082 | screen_info.orig_video_isVGA = 0; | ^ | struct drivers/video/fbdev/hyperv_fb.c:1082:14: error: expected identifier or '(' 1082 | screen_info.orig_video_isVGA = 0; | ^ 8 errors generated. Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202307101042.rqehuauj-lkp@intel.com/ Fixes: 8b0d13545b09 ("efi: Do not include <linux/screen_info.h> from EFI header") Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Cc: "K. Y. Srinivasan" <kys@microsoft.com> (supporter:Hyper-V/Azure CORE AND DRIVERS) Cc: Haiyang Zhang <haiyangz@microsoft.com> (supporter:Hyper-V/Azure CORE AND DRIVERS) Cc: Wei Liu <wei.liu@kernel.org> (supporter:Hyper-V/Azure CORE AND DRIVERS) Cc: Dexuan Cui <decui@microsoft.com> (supporter:Hyper-V/Azure CORE AND DRIVERS) Cc: Helge Deller <deller@gmx.de> (maintainer:FRAMEBUFFER LAYER) Cc: Javier Martinez Canillas <javierm@redhat.com> Cc: Sui Jingfeng <suijingfeng@loongson.cn> Cc: Ard Biesheuvel <ardb@kernel.org> Cc: Russell King <linux@armlinux.org.uk> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will@kernel.org> Cc: Arnd Bergmann <arnd@arndb.de> Cc: linux-efi@vger.kernel.org Cc: linux-hyperv@vger.kernel.org (open list:Hyper-V/Azure CORE AND DRIVERS) Cc: linux-fbdev@vger.kernel.org (open list:FRAMEBUFFER LAYER) Cc: dri-devel@lists.freedesktop.org (open list:FRAMEBUFFER LAYER) Reviewed-by: Javier Martinez Canillas <javierm@redhat.com> Reviewed-by: Sui Jingfeng <suijingfeng@loongson.cn> Link: https://patchwork.freedesktop.org/patch/msgid/20230710075848.23087-1-tzimmermann@suse.de
2023-07-08fbdev/xen-fbfront: Generate deferred I/O opsThomas Zimmermann1-41/+20
Use the existing generator macros to create deferred-I/O helpers for xen-fbfront and set them in the fb_ops structure. Functions for damage handling on memory ranges and areas are provided by the driver. Xen-fbfront's implementation of fb_write writes to system memory, so the generated code can use the respective helper internally. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-11-tzimmermann@suse.de
2023-07-08fbdev/xen-fbfront: Select FB_SYS_HELPERS_DEFERREDThomas Zimmermann1-5/+1
The Kconfig token FB_SYS_HELPERS_DEFERRED selects everything that is required for deferred I/O on system-memory framebuffers. Select it from XEN_FBDEV_FRONTEND in favor of the existing identical selection. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-10-tzimmermann@suse.de
2023-07-08fbdev/ssd1307fb: Generate deferred I/O opsThomas Zimmermann1-58/+11
Use the existing generator macros to create deferred-I/O helpers for ssd1307fb and set them in the fb_ops structure. Functions for damage handling on memory ranges and areas are provided by the driver. Ssd1307fb's implementation of fb_write writes to system memory, so the generated code can use the respective helper internally. This also fixes a long-standing bug where fb_write returned an errno code instead of the number of written bytes. See the commit message of commit 921b7383f348 ("fbdev: Return number of bytes read or written") for more details. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-9-tzimmermann@suse.de
2023-07-08fbdev/ssd1307fb: Select FB_SYS_HELPERS_DEFERREDThomas Zimmermann1-5/+1
The Kconfig token FB_SYS_HELPERS_DEFERRED selects everything that is required for deferred I/O on system-memory framebuffers. Select it from FB_SSD1307 in favor of the existing identical selection. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-8-tzimmermann@suse.de
2023-07-08fbdev/metronomefb: Generate deferred I/O opsThomas Zimmermann1-66/+8
Use the existing generator macros to create deferred-I/O helpers for metronomefb and set them in the fb_ops structure. Functions for damage handling on memory ranges and areas are provided by the driver. Metronomefb's implementation of fb_write writes to system memory, so the generated code can use the respective helper internally. This also fixes a long-standing bug where fb_write returned an errno code instead of the number of written bytes. See the commit message of commit 921b7383f348 ("fbdev: Return number of bytes read or written") for more details. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-7-tzimmermann@suse.de
2023-07-08fbdev/metronomefb: Select FB_SYS_HELPERS_DEFERREDThomas Zimmermann1-5/+1
The Kconfig token FB_SYS_HELPERS_DEFERRED selects everything that is required for deferred I/O on system-memory framebuffers. Select it from FB_METRONOME in favor of the existing identical selection. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-6-tzimmermann@suse.de
2023-07-08fbdev/hecubafb: Generate deferred I/O opsThomas Zimmermann1-70/+8
Use the existing generator macros to create deferred-I/O helpers for hecubafb and set them in the fb_ops structure. Functions for damage handling on memory ranges and areas are provided by the driver. Hecubafb's implementation of fb_write writes to system memory, so the generated code can use the respective helper internally. This also fixes a long-standing bug where fb_write returned an errno code instead of the number of written bytes. See the commit message of commit 921b7383f348 ("fbdev: Return number of bytes read or written") for more details. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-5-tzimmermann@suse.de
2023-07-08fbdev/hecubafb: Select FB_SYS_HELPERS_DEFERREDThomas Zimmermann1-6/+1
The Kconfig token FB_SYS_HELPERS_DEFERRED selects everything that is required for deferred I/O on system-memory framebuffers. Select it from FB_HECUBA. Deferred I/O helpers were previously selected by n411, which builds upon hecubafb. Remove these select statements in favor of the new one. N411 does not implement any framebuffer I/O by itself. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-4-tzimmermann@suse.de
2023-07-08fbdev/broadsheetfb: Generate deferred I/O opsThomas Zimmermann1-70/+8
Use the existing generator macros to create deferred-I/O helpers for broadsheetfb and set them in the fb_ops structure. Functions for damage handling on memory ranges and areas are provided by the driver. Broadsheedfb's implementation of fb_write writes to system memory, so the generated code can use the respective helper internally. This also fixes a long-standing bug where fb_write returned an errno code instead of the number of written bytes. See the commit message of commit 921b7383f348 ("fbdev: Return number of bytes read or written") for more details. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-3-tzimmermann@suse.de
2023-07-08fbdev/broadsheetfb: Select FB_SYS_HELPERS_DEFERREDThomas Zimmermann1-5/+1
The Kconfig token FB_SYS_HELPERS_DEFERRED selects everything that is required for deferred I/O on system-memory framebuffers. Select it from FB_BROADSHEET in favor of the existing identical selection. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706151432.20674-2-tzimmermann@suse.de
2023-07-08fbdev/sm712fb: Do not include <linux/screen_info.h>Thomas Zimmermann1-2/+7
Sm712fb's dependency on <linux/screen_info.h> is artificial in that it only uses struct screen_info for its internals. Replace the use of struct screen_info with a custom data structure and remove the include of <linux/screen_info.h>. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Javier Martinez Canillas <javierm@redhat.com> Cc: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Cc: Teddy Wang <teddy.wang@siliconmotion.com> Cc: Helge Deller <deller@gmx.de> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Link: https://patchwork.freedesktop.org/patch/msgid/20230706104852.27451-3-tzimmermann@suse.de