lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID:
 <SYAPR01MB2863FAF8B39141E2FC402D21B2A0A@SYAPR01MB2863.ausprd01.prod.outlook.com>
Date: Wed, 10 Dec 2025 18:30:06 +0000
From: Jonathan Brophy <J.Brophy@...killsystems.co.nz>
To: "andriy.shevchenko@...ux.intel.com" <andriy.shevchenko@...ux.intel.com>
CC: "lee@...nel.org" <lee@...nel.org>, "linux-leds@...r.kernel.org"
	<linux-leds@...r.kernel.org>, Pavel Machek <pavel@...nel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH v1 1/1] leds: Unexport of_led_get()

> Can you elaborate? I think your downstream code (I have no other ideas where you Q came from)
> uses some outdated approaches. Try to look at the problem from the level of the existing APIs and 
> frameworks. We shouldn't really have such an issue (but it might be some special use case, I admit).

I'm trying to create a virtual led driver but with the removal of of_led_get() im struggling to find a way to make it work.

I investigated alternative approaches to avoid of_led_get() dependency, including:

Direct class_find_device(led_class, ...) calls - Failed because led_class is not exported (static in led-class.c)
bus_find_device_by_fwnode() - Failed because LED devices are class devices, not bus devices
Manual iteration via class_dev_iter_init() - Failed because I cannot obtain the led_class pointer

of_led_get() appears to be the only viable solution because:

It's the only exported function with access to the non-exported leds_class
It handles GPIO LED matching quirks (parent node vs child node)
It provides proper reference counting via led_put()

Should led_class be exported, or is there a planned fwnode-based alternative to of_led_get?



With Best Regards,
Jonathan brophy



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ