Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: net: phy: add MaxLinear GPY2xx bindings

Add the device tree bindings for the MaxLinear GPY2xx PHYs, which
essentially adds just one flag: maxlinear,use-broken-interrupts.

One might argue, that if interrupts are broken, just don't use
the interrupt property in the first place. But it needs to be more
nuanced. First, this interrupt line is also used to wake up systems by
WoL, which has nothing to do with the (broken) PHY interrupt handling.

Second and more importantly, there are devicetrees which have this
property set. Thus, within the driver we have to switch off interrupt
handling by default as a workaround. But OTOH, a systems designer who
knows the hardware and knows there are no shared interrupts for example,
can use this new property as a hint to the driver that it can enable the
interrupt nonetheless.

Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>

authored by

Michael Walle and committed by
Paolo Abeni
90c47eb1 dd1a98a3

+47
+47
Documentation/devicetree/bindings/net/maxlinear,gpy2xx.yaml
··· 1 + # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/net/maxlinear,gpy2xx.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: MaxLinear GPY2xx PHY 8 + 9 + maintainers: 10 + - Andrew Lunn <andrew@lunn.ch> 11 + - Michael Walle <michael@walle.cc> 12 + 13 + allOf: 14 + - $ref: ethernet-phy.yaml# 15 + 16 + properties: 17 + maxlinear,use-broken-interrupts: 18 + description: | 19 + Interrupts are broken on some GPY2xx PHYs in that they keep the 20 + interrupt line asserted even after the interrupt status register is 21 + cleared. Thus it is blocking the interrupt line which is usually bad 22 + for shared lines. By default interrupts are disabled for this PHY and 23 + polling mode is used. If one can live with the consequences, this 24 + property can be used to enable interrupt handling. 25 + 26 + Affected PHYs (as far as known) are GPY215B and GPY215C. 27 + type: boolean 28 + 29 + dependencies: 30 + maxlinear,use-broken-interrupts: [ interrupts ] 31 + 32 + unevaluatedProperties: false 33 + 34 + examples: 35 + - | 36 + ethernet { 37 + #address-cells = <1>; 38 + #size-cells = <0>; 39 + 40 + ethernet-phy@0 { 41 + reg = <0>; 42 + interrupts-extended = <&intc 0>; 43 + maxlinear,use-broken-interrupts; 44 + }; 45 + }; 46 + 47 + ...