public inbox for linux-leds@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/1] leds/build: allow tristate for leds-syscon
@ 2026-03-02  6:26 Bevan Weiss
  2026-03-02  6:26 ` [PATCH 1/1] " Bevan Weiss
  2026-03-04 10:49 ` [PATCH 0/1] " Bevan Weiss
  0 siblings, 2 replies; 3+ messages in thread
From: Bevan Weiss @ 2026-03-02  6:26 UTC (permalink / raw)
  To: lee, pavel, linux-leds; +Cc: linux-kernel, Bevan Weiss

My first submission to a linux-kernel list, so apologies for any errors.

In OpenWrt one core kernel image is built for a particular subtarget,
after which it's only modules that can be excluded from an rootfs image to
reduce the space consumed.  Unfortunately leds-syscon currently doesn't
seem to allow for being compiled as a module where it could be excluded
from an image. In my testing, it seemed relatively straight forward to
enable this however.
I wouldn't anticipate issues for other systems, as they would still be
able to request CONFIG_LEDS_SYSCON=y to get the current behaviour,
identical to how they currently operate.


Bevan Weiss (1):
  leds/build: allow tristate for leds-syscon

 drivers/leds/Kconfig       | 4 ++--
 drivers/leds/leds-syscon.c | 3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH 1/1] leds/build: allow tristate for leds-syscon
  2026-03-02  6:26 [PATCH 0/1] leds/build: allow tristate for leds-syscon Bevan Weiss
@ 2026-03-02  6:26 ` Bevan Weiss
  2026-03-04 10:49 ` [PATCH 0/1] " Bevan Weiss
  1 sibling, 0 replies; 3+ messages in thread
From: Bevan Weiss @ 2026-03-02  6:26 UTC (permalink / raw)
  To: lee, pavel, linux-leds; +Cc: linux-kernel, Bevan Weiss

Having leds-syscon as only bool (y/n) config poses issues with OpenWrt
build system where all boards under a subtarget need to share the same
config options. This results in kernel bloat for all boards when only
a few actually need leds-syscon.
This change allows leds-syscon to be tristate (y/m/n), which means it can
be built as a module for all boards, and then selectively packaged for
their unique rootfs's



Signed-off-by: Bevan Weiss <bevan.weiss@gmail.com>
---
 drivers/leds/Kconfig       | 4 ++--
 drivers/leds/leds-syscon.c | 3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig
index 597d7a79c988..ea3afc76a9c6 100644
--- a/drivers/leds/Kconfig
+++ b/drivers/leds/Kconfig
@@ -903,8 +903,8 @@ config LEDS_POWERNV
 	  will be called leds-powernv.
 
 config LEDS_SYSCON
-	bool "LED support for LEDs on system controllers"
-	depends on LEDS_CLASS=y
+	tristate "LED support for LEDs on system controllers"
+	depends on LEDS_CLASS
 	depends on MFD_SYSCON
 	depends on OF
 	help
diff --git a/drivers/leds/leds-syscon.c b/drivers/leds/leds-syscon.c
index d633ad519d0c..13a9cdc13367 100644
--- a/drivers/leds/leds-syscon.c
+++ b/drivers/leds/leds-syscon.c
@@ -135,3 +135,6 @@ static struct platform_driver syscon_led_driver = {
 	},
 };
 builtin_platform_driver(syscon_led_driver);
+
+MODULE_DESCRIPTION("SYSCON LED driver");
+MODULE_LICENSE("GPL");
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 0/1] leds/build: allow tristate for leds-syscon
  2026-03-02  6:26 [PATCH 0/1] leds/build: allow tristate for leds-syscon Bevan Weiss
  2026-03-02  6:26 ` [PATCH 1/1] " Bevan Weiss
@ 2026-03-04 10:49 ` Bevan Weiss
  1 sibling, 0 replies; 3+ messages in thread
From: Bevan Weiss @ 2026-03-04 10:49 UTC (permalink / raw)
  To: lee, pavel, linux-leds; +Cc: linux-kernel

On Mon,  2 Mar 2026 17:26:45 +1100
Bevan Weiss <bevan.weiss@gmail.com> wrote:

> My first submission to a linux-kernel list, so apologies for any
> errors.

Sorry all, please ignore this patch.
I'll review, and send a V2 once I sort out some of the issues here. 


Regards,
Bevan Weiss

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-03-04 10:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-02  6:26 [PATCH 0/1] leds/build: allow tristate for leds-syscon Bevan Weiss
2026-03-02  6:26 ` [PATCH 1/1] " Bevan Weiss
2026-03-04 10:49 ` [PATCH 0/1] " Bevan Weiss

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox