Re: [PATCH v3 4/4] fbdev: sh_mobile_lcdc: Make FB_DEVICE dependency optional

From
Andy Shevchenko <hidden>
Date
2025-12-30 11:35:35
Also in
dri-devel, linux-omap, linux-staging, lkml
Reply to
Chintan Patel, 2025-12-30
On Mon, Dec 29, 2025 at 09:28:22PM -0800, Chintan Patel wrote:
The sh_mobile_lcdc driver exposes overlay configuration via sysfs, but the
core driver does not require CONFIG_FB_DEVICE.

Make sysfs support optional by defining overlay_sysfs_groups conditionally
using PTR_IF(). The driver always sets .dev_groups, and the kernel
naturally skips NULL attribute groups while the code remains buildable
and type-checked.
...
quoted hunk ↗ jump to hunk
+static const struct attribute_group *overlay_sysfs_groups[] = {
+	PTR_IF(IS_ENABLED(CONFIG_FB_DEVICE), &overlay_sysfs_group),
+	NULL,
Please, drop comma at the end of the terminator entry.
+};
-- 
With Best Regards,
Andy Shevchenko

Thread (20 messages) 20 messages, 6 authors, last reply 2026-01-06
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help