This is used to override the various defaults the ath9k driver has for
LED pin values.
Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
.../bindings/net/wireless/qca,ath9k.yaml | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml b/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml
index d16ca8e0a25d..58c7b873cecb 100644
--- a/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml
+++ b/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml
@@ -50,6 +50,19 @@ properties:
ieee80211-freq-limit: true
+ led:
+ type: object
+ $ref: /schemas/leds/common.yaml#
+ additionalProperties: false
+ properties:
+ led-active-low:
+ description:
+ LED is enabled with ground signal.
+ type: boolean
+
+ led-sources:
+ maxItems: 1
+
qca,no-eeprom:
$ref: /schemas/types.yaml#/definitions/flag
description:
@@ -102,5 +115,8 @@ examples:
compatible = "qca,ar9130-wifi";
reg = <0x180c0000 0x230000>;
interrupts = <2>;
+ led {
+ led-sources = <0>;
+ };
};
};
--
2.50.0
On Fri, Jul 04, 2025 at 02:42:17PM -0700, Rosen Penev wrote: > This is used to override the various defaults the ath9k driver has for > LED pin values. > > Signed-off-by: Rosen Penev <rosenp@gmail.com> > --- > .../bindings/net/wireless/qca,ath9k.yaml | 16 ++++++++++++++++ > 1 file changed, 16 insertions(+) > > diff --git a/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml b/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml > index d16ca8e0a25d..58c7b873cecb 100644 > --- a/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml > +++ b/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml > @@ -50,6 +50,19 @@ properties: > > ieee80211-freq-limit: true > > + led: > + type: object > + $ref: /schemas/leds/common.yaml# > + additionalProperties: false You really don't want any other common properties? Like defining the function? > + properties: > + led-active-low: > + description: > + LED is enabled with ground signal. > + type: boolean > + > + led-sources: > + maxItems: 1 This property is really for cases where the LED source is configurable from the LED instance. If that's not the case here just use 'reg' for each instance (assuming there's more than 1). I shouldn't be wondering what the h/w looks like though. Please describe it in the commit msg rather than what some driver does. If you do need led-sources, you should define some constraints on the values, not just the length. Rob
On Tue, Jul 8, 2025 at 10:26 AM Rob Herring <robh@kernel.org> wrote: > > On Fri, Jul 04, 2025 at 02:42:17PM -0700, Rosen Penev wrote: > > This is used to override the various defaults the ath9k driver has for > > LED pin values. > > > > Signed-off-by: Rosen Penev <rosenp@gmail.com> > > --- > > .../bindings/net/wireless/qca,ath9k.yaml | 16 ++++++++++++++++ > > 1 file changed, 16 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml b/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml > > index d16ca8e0a25d..58c7b873cecb 100644 > > --- a/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml > > +++ b/Documentation/devicetree/bindings/net/wireless/qca,ath9k.yaml > > @@ -50,6 +50,19 @@ properties: > > > > ieee80211-freq-limit: true > > > > + led: > > + type: object > > + $ref: /schemas/leds/common.yaml# > > + additionalProperties: false > > You really don't want any other common properties? Like defining the > function? All of this was copy/paste from mediatek,mt76.yaml , where the same binding is used for mostly the same purpose. > > > + properties: > > + led-active-low: > > + description: > > + LED is enabled with ground signal. > > + type: boolean > > + > > + led-sources: > > + maxItems: 1 > > This property is really for cases where the LED source is configurable > from the LED instance. If that's not the case here just use 'reg' for > each instance (assuming there's more than 1). I shouldn't be wondering > what the h/w looks like though. Please describe it in the commit msg > rather than what some driver does. > > If you do need led-sources, you should define some constraints on the > values, not just the length. The original downstream version used a u8 for the number. But again, I'm just copy/pasting. > > Rob >
© 2016 - 2025 Red Hat, Inc.