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:
linux-fbdev, linux-omap, linux-staging, lkml
From: Andy Shevchenko <hidden>
Date: 2025-12-30 11:35:35
Also in:
linux-fbdev, linux-omap, linux-staging, lkml
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.
...
+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