Document IPQ6018 compatible that is already being used in the DTS along
with the fallback IPQ4019 compatible as driver itself only gets probed
on IPQ4019 and IPQ5018 compatibles.
This is also required in order to specify which platform require clock to
be defined and validate it in schema.
Signed-off-by: Robert Marko <[email protected]>
---
Changes in v2:
* Drop items from IPQ4019 and IPQ5018 compatible enum
---
.../devicetree/bindings/net/qcom,ipq4019-mdio.yaml | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml b/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
index ad8b2b41c140..1ba8de982bd1 100644
--- a/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
+++ b/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
@@ -14,9 +14,15 @@ allOf:
properties:
compatible:
- enum:
- - qcom,ipq4019-mdio
- - qcom,ipq5018-mdio
+ oneOf:
+ - enum:
+ - qcom,ipq4019-mdio
+ - qcom,ipq5018-mdio
+
+ - items:
+ - enum:
+ - qcom,ipq6018-mdio
+ - const: qcom,ipq4019-mdio
"#address-cells":
const: 1
--
2.38.1
IPQ5018, IPQ6018 and IPQ8074 require clock-names to be set as driver is
requesting the clock based on it and not index, so document that and make
it required for the listed SoC-s.
Signed-off-by: Robert Marko <[email protected]>
---
Changes in v2:
* Define clock-names under properties and disallow it per compatible
like clocks
---
.../devicetree/bindings/net/qcom,ipq4019-mdio.yaml | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml b/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
index 72561e3aeee3..7631ecc8fd01 100644
--- a/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
+++ b/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
@@ -40,6 +40,10 @@ properties:
items:
- description: MDIO clock source frequency fixed to 100MHZ
+ clock-names:
+ items:
+ - const: gcc_mdio_ahb_clk
+
required:
- compatible
- reg
@@ -60,9 +64,11 @@ allOf:
then:
required:
- clocks
+ - clock-names
else:
properties:
clocks: false
+ clock-names: false
unevaluatedProperties: false
--
2.38.1
Add the newly documented SoC compatible to MDIO in order to be able to
validate clocks for it.
Signed-off-by: Robert Marko <[email protected]>
Acked-by: Krzysztof Kozlowski <[email protected]>
---
arch/arm64/boot/dts/qcom/ipq8074.dtsi | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm64/boot/dts/qcom/ipq8074.dtsi b/arch/arm64/boot/dts/qcom/ipq8074.dtsi
index a0481c671faf..583871c29586 100644
--- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi
@@ -331,7 +331,7 @@ pcie_phy1: phy@8e200 {
};
mdio: mdio@90000 {
- compatible = "qcom,ipq4019-mdio";
+ compatible = "qcom,ipq8074-mdio", "qcom,ipq4019-mdio";
reg = <0x00090000 0x64>;
#address-cells = <1>;
#size-cells = <0>;
--
2.38.1
Now that we can match the platforms requiring clocks by compatible start
using those to allow clocks per compatible and make them required.
Signed-off-by: Robert Marko <[email protected]>
---
Changes in v2:
* Keep clocks under properties and disallow per compatible
---
.../bindings/net/qcom,ipq4019-mdio.yaml | 27 ++++++++++++++-----
1 file changed, 20 insertions(+), 7 deletions(-)
diff --git a/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml b/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
index f4918c9e6fd2..72561e3aeee3 100644
--- a/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
+++ b/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
@@ -9,9 +9,6 @@ title: Qualcomm IPQ40xx MDIO Controller
maintainers:
- Robert Marko <[email protected]>
-allOf:
- - $ref: "mdio.yaml#"
-
properties:
compatible:
oneOf:
@@ -40,10 +37,8 @@ properties:
address range is only required by the platform IPQ50xx.
clocks:
- maxItems: 1
- description: |
- MDIO clock source frequency fixed to 100MHZ, this clock should be specified
- by the platform IPQ807x, IPQ60xx and IPQ50xx.
+ items:
+ - description: MDIO clock source frequency fixed to 100MHZ
required:
- compatible
@@ -51,6 +46,24 @@ required:
- "#address-cells"
- "#size-cells"
+allOf:
+ - $ref: "mdio.yaml#"
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,ipq5018-mdio
+ - qcom,ipq6018-mdio
+ - qcom,ipq8074-mdio
+ then:
+ required:
+ - clocks
+ else:
+ properties:
+ clocks: false
+
unevaluatedProperties: false
examples:
--
2.38.1
On 14/11/2022 20:47, Robert Marko wrote:
> Now that we can match the platforms requiring clocks by compatible start
> using those to allow clocks per compatible and make them required.
>
> Signed-off-by: Robert Marko <[email protected]>
> ---
> Changes in v2:
> * Keep clocks under properties and disallow per compatible
> ---
> .../bindings/net/qcom,ipq4019-mdio.yaml | 27 ++++++++++++++-----
> 1 file changed, 20 insertions(+), 7 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml b/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
> index f4918c9e6fd2..72561e3aeee3 100644
> --- a/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
> +++ b/Documentation/devicetree/bindings/net/qcom,ipq4019-mdio.yaml
> @@ -9,9 +9,6 @@ title: Qualcomm IPQ40xx MDIO Controller
> maintainers:
> - Robert Marko <[email protected]>
>
> -allOf:
> - - $ref: "mdio.yaml#"
> -
> properties:
> compatible:
> oneOf:
> @@ -40,10 +37,8 @@ properties:
> address range is only required by the platform IPQ50xx.
>
> clocks:
> - maxItems: 1
> - description: |
> - MDIO clock source frequency fixed to 100MHZ, this clock should be specified
> - by the platform IPQ807x, IPQ60xx and IPQ50xx.
> + items:
> + - description: MDIO clock source frequency fixed to 100MHZ
>
> required:
> - compatible
> @@ -51,6 +46,24 @@ required:
> - "#address-cells"
> - "#size-cells"
>
> +allOf:
> + - $ref: "mdio.yaml#"
If there is going to be resend, drop the quotes from above during the move.
Anyway:
Reviewed-by: Krzysztof Kozlowski <[email protected]>
Best regards,
Krzysztof
On 14/11/2022 20:47, Robert Marko wrote:
> IPQ5018, IPQ6018 and IPQ8074 require clock-names to be set as driver is
> requesting the clock based on it and not index, so document that and make
> it required for the listed SoC-s.
>
> Signed-off-by: Robert Marko <[email protected]>
> ---
> Changes in v2:
> * Define clock-names under properties and disallow it per compatible
> like clocks
> ---
Reviewed-by: Krzysztof Kozlowski <[email protected]>
Best regards,
Krzysztof
On 14/11/2022 20:47, Robert Marko wrote:
> Document IPQ6018 compatible that is already being used in the DTS along
> with the fallback IPQ4019 compatible as driver itself only gets probed
> on IPQ4019 and IPQ5018 compatibles.
>
> This is also required in order to specify which platform require clock to
> be defined and validate it in schema.
>
> Signed-off-by: Robert Marko <[email protected]>
Reviewed-by: Krzysztof Kozlowski <[email protected]>
Best regards,
Krzysztof
Hello:
This series was applied to netdev/net-next.git (master)
by Jakub Kicinski <[email protected]>:
On Mon, 14 Nov 2022 20:47:30 +0100 you wrote:
> Document IPQ6018 compatible that is already being used in the DTS along
> with the fallback IPQ4019 compatible as driver itself only gets probed
> on IPQ4019 and IPQ5018 compatibles.
>
> This is also required in order to specify which platform require clock to
> be defined and validate it in schema.
>
> [...]
Here is the summary with links:
- [v2,1/5] dt-bindings: net: ipq4019-mdio: document IPQ6018 compatible
https://git.kernel.org/netdev/net-next/c/cbe5f7c0fbcd
- [v2,2/5] dt-bindings: net: ipq4019-mdio: add IPQ8074 compatible
https://git.kernel.org/netdev/net-next/c/05c1cbb96f3d
- [v2,3/5] dt-bindings: net: ipq4019-mdio: require and validate clocks
https://git.kernel.org/netdev/net-next/c/e50c50367d98
- [v2,4/5] dt-bindings: net: ipq4019-mdio: document required clock-names
https://git.kernel.org/netdev/net-next/c/4a8c14384fa9
- [v2,5/5] arm64: dts: qcom: ipq8074: add SoC specific compatible to MDIO
(no matching commit)
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
On Mon, 14 Nov 2022 20:47:30 +0100, Robert Marko wrote:
> Document IPQ6018 compatible that is already being used in the DTS along
> with the fallback IPQ4019 compatible as driver itself only gets probed
> on IPQ4019 and IPQ5018 compatibles.
>
> This is also required in order to specify which platform require clock to
> be defined and validate it in schema.
>
> [...]
Applied, thanks!
[5/5] arm64: dts: qcom: ipq8074: add SoC specific compatible to MDIO
commit: 36e830a5656d6c22110c5dcffb611fc69a57a269
Best regards,
--
Bjorn Andersson <[email protected]>