Skip to content

fbdev: Make CONFIG_FB_DEVICE optional for drivers

Chintan Patel dri-devel linux-fbdev linux-omap linux-staging lkml 3 versions – Applied

Status from this message: applied to fbdev.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest4 patches 8 repliesApplied
  2. v34 patches 15 repliesSuperseded
  3. v24 patches 6 repliesSuperseded

Changes in v4 from the cover letter

- PTR_IF() was removed and overlay sysfs is now optional via __maybe_unused and #ifdef CONFIG_FB_DEVICE (suggested by Helge Deller)
- Decouple variable definition and assignment in omapfb_remove/create_sysfs (suggested by Andy Shevchenko)
- Added Reviewed-by tags:
- fb: Add dev_of_fbinfo(): Helge Deller, Andy Shevchenko
- staging: fbtft: Helge Deller

Patches in v4 Applied

#Subject and filesSizeRepliesApplied
1/4fb: Add dev_of_fbinfo() helper for optional sysfs supportinclude/linux/fb.h+9 -03 replies
2/4staging: fbtft: Make FB_DEVICE dependency optionaldrivers/staging/fbtft/Kconfig drivers/staging/fbtft/fbtft-sysfs.c+20 -52 replies
3/4fbdev: omapfb: Make FB_DEVICE dependency optionaldrivers/video/fbdev/omap2/omapfb/Kconfig drivers/video/fbdev/omap2/omapfb/omapfb-sysfs.c+16 -52 replies
4/4fbdev: sh_mobile_lcdc: Make FB_DEVICE dependency optionaldrivers/video/fbdev/sh_mobile_lcdcfb.c+4 -11 reply

Reviews trailers per patch

All 4 patches have a Reviewed-by or Acked-by.

PatchHelge DellerAndy ShevchenkoThomas Zimmermann
1/4R-b R-b R-b
2/4R-b R-b R-b
3/4R-b
4/4R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v4 thread

Cover letter [PATCH v4 0/4] fbdev: Make CONFIG_FB_DEVICE optional for drivers

This series makes CONFIG_FB_DEVICE optional for fbdev drivers that use it only for sysfs interfaces, addressing Thomas Zimmermann’s TODO to remove hard FB_DEVICE dependencies.

The series introduces a small helper, dev_of_fbinfo(), which returns NULL when CONFIG_FB_DEVICE=n. This allows sysfs code paths to be skipped via runtime checks, avoids #ifdef CONFIG_FB_DEVICE clutter, and keeps full compile-time syntax checking.

---
Changes in v4:
- PTR_IF() was removed and overlay sysfs is now optional via __maybe_unused and #ifdef CONFIG_FB_DEVICE (suggested by Helge Deller)
- Decouple variable definition and assignment in omapfb_remove/create_sysfs (suggested by Andy Shevchenko)
- Added Reviewed-by tags:
- fb: Add dev_of_fbinfo(): Helge Deller, Andy Shevchenko
- staging: fbtft: Helge Deller

Changes in v3:
- Use PTR_IF() to conditionally include overlay_sysfs_group in overlay_sysfs_groups(suggested by Andy Shevchenko)
- Decouple variable definition and assignment in fbtft_sysfs_init/exit(suggested by Andy Shevchenko)

Changes in v2:
- Add dev_of_fbinfo() helper (suggested by Helge Deller)
- Replace #ifdef CONFIG_FB_DEVICE blocks with runtime NULL checks
- Switch to fb_dbg() / fb_info() logging (suggested by Thomas Zimmermann)

---

Chintan Patel (4):
fb: Add dev_of_fbinfo() helper for optional sysfs support
staging: fbtft: Make FB_DEVICE dependency optional
fbdev: omapfb: Make FB_DEVICE dependency optional
fbdev: sh_mobile_lcdc: Make FB_DEVICE dependency optional

 drivers/staging/fbtft/Kconfig                 |  5 ++++-
 drivers/staging/fbtft/fbtft-sysfs.c           | 20 +++++++++++++++----
 drivers/video/fbdev/omap2/omapfb/Kconfig      |  3 ++-
 .../video/fbdev/omap2/omapfb/omapfb-sysfs.c   | 18 +++++++++++++----
 drivers/video/fbdev/sh_mobile_lcdcfb.c        |  5 ++++-
 include/linux/fb.h                            |  9 +++++++++
 6 files changed, 49 insertions(+), 11 deletions(-)
Signature · 1 line
2.43.0