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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <96765a57-9e02-4f9e-837c-c0513e74ade4@baylibre.com>
Date: Wed, 16 Apr 2025 13:38:14 -0500
From: David Lechner <dlechner@...libre.com>
To: Linus Walleij <linus.walleij@...aro.org>,
 Jonathan Santos <Jonathan.Santos@...log.com>
Cc: linux-iio@...r.kernel.org, devicetree@...r.kernel.org,
 linux-kernel@...r.kernel.org, linux-gpio@...r.kernel.org, lars@...afoo.de,
 Michael.Hennerich@...log.com, marcelo.schmitt@...log.com, jic23@...nel.org,
 robh@...nel.org, krzk+dt@...nel.org, conor+dt@...nel.org,
 marcelo.schmitt1@...il.com, brgl@...ev.pl, lgirdwood@...il.com,
 broonie@...nel.org, jonath4nns@...il.com
Subject: Re: [PATCH v5 01/14] dt-bindings: trigger-source: add generic GPIO
 trigger source

On 4/16/25 2:43 AM, Linus Walleij wrote:
> Hi Jonathan,
> 
> thanks for your patch!
> 
> On Fri, Apr 11, 2025 at 5:56 PM Jonathan Santos
> <Jonathan.Santos@...log.com> wrote:
> 
>> Inspired by pwn-trigger, create a new binding for using a GPIO
>> pin as a trigger source.
>>
>> Signed-off-by: Jonathan Santos <Jonathan.Santos@...log.com>
> 
> Is this actually documenting the trigger sources I implemented for LED
> here?
> https://lore.kernel.org/all/20230926-gpio-led-trigger-dt-v2-0-e06e458b788e@linaro.org/

No. This is something more like "pwm-clock" where it is converting a gpios
phandle to a trigger-sources phandle. Doing it this way comes from some
discussion on using trigger-sources for the SPI offload stuff I was working
on recently. [1]

As a result of that work, there are generic bindings for trigger-sources and
#trigger-source cells in dtschma now that can be used by any node. [2]

The way the leds subsystem does it where you can have trigger-sources = <&gpio 0>
or <&ohci_port1> directly has the issue where it isn't easy for the consumer
to know what type of node the provider is. Effectively, we have to have the
linux,default-trigger property to tell us what the provider node type is. By
adding this extra node in between we can get that type info more naturally than
the linux-specific property. And each subsystem won't have to have extra code
added for trigger-sources like you had to add for gpios.

[1]: https://lore.kernel.org/all/20241031-croon-boss-3b30ff9e9333@spud/
[2]: https://github.com/devicetree-org/dt-schema/commit/93ee8008959e362548168eaa7bdc20c115f3d586




Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ