Signed-off-by: Yang Xiwen <[email protected]>
---
Changes in v10:
- binding: make hi3516cv300 the fallback compatible (Krzysztof Kozlowski)
- driver: drop mv200 match string (Krzysztof Kozlowski)
- commit msg: remove #conflicts
- Link to v9: https://lore.kernel.org/r/[email protected]
Changes in v9:
- binding: remove generic fallback compatible as it's not used in driver
- Link to v8: https://lore.kernel.org/r/[email protected]
Changes in v8:
- remove MODULE_ALIAS: rewrite commit msg (Krzysztof Kozlowski)
- driver: use only SoC compatibles (Krzysztof Kozlowski)
- Link to v7: https://lore.kernel.org/r/[email protected]
Changes in v7:
- dt-bindings: squash a bunch of patches to YAML conversion (Krzysztof Kozlowski)
- dt-bindings: drop phy-mode->phy-connection-type conversion (Andrew Lunnm, Krzysztof Kozlowski)
- driver: drop SoC compatibles
- misc: some minor clean ups
- driver: remove MODULE_ALIAS()
- Link to v6: https://lore.kernel.org/r/[email protected]
Changes in v6:
- add missing "not" in commit logs (Andrew)
- rework binding changes, split it into several commits (Krzysztof Kozlowski)
- Link to v5: https://lore.kernel.org/r/[email protected]
Changes in v5:
- hisi-femac-mdio: remove clock completely (Krzysztof Kozlowski)
- dt-bindings: mdio: apply comments from Krzysztof Kozlowski
Changes in v4:
- edit commit log to show why mdio bus clk is optional (Krzysztof Kozlowski)
- add clk_bulk_disable_unprepare() during error path (Maxime Chevallier)
- remove of_node_put() (Simon Horman)
- remove histb-clock.h header in binding example as it's goign to be deprecated.
- rearrange patches so binding comes before driver
- Link to v3: https://lore.kernel.org/r/[email protected]
Changes in v3:
- rearrange patches to fix bot error. (Rob Herring)
- rewrite commit logs (Andrew Lunn)
- use clk_bulk_ APIs (Andrew Lunn)
- fix uninitialization use of ret (assign to -ENODEV before goto) (Simon Horman)
- Link to v2: https://lore.kernel.org/r/[email protected]
Changes in v2:
- replace email.
- hisi-femac: s/BUS/MACIF (Andrew Lunn)
- hisi-femac: add "hisilicon,hisi-femac" compatible since the driver
seems generic enough for various SoCs
- hisi-femac-mdio: convert binding to YAML (Krzysztof Kozlowski)
- rewrite commit logs (Krzysztof Kozlowski)
- Link to v1: https://lore.kernel.org/r/[email protected]
---
Yang Xiwen (8):
dt-bindings: net: hisilicon-femac-mdio: convert to YAML
dt-bindings: net: hisilicon,hisi-femac-mdio: remove clocks
net: mdio: hisi-femac: remove clock
dt-bindings: net: convert hisi-femac.txt to YAML
dt-bindings: net: hisi-femac: add mandatory MDIO bus subnode
dt-bindings: net: hisi-femac: add binding for Hi3798MV200 FEMAC core
net: hisi_femac: remove unused compatible strings
net: hisi_femac: remove unneeded MODULE_ALIAS()
.../bindings/net/hisilicon,hisi-femac-mdio.yaml | 39 +++++++
.../bindings/net/hisilicon,hisi-femac.yaml | 121 +++++++++++++++++++++
.../bindings/net/hisilicon-femac-mdio.txt | 22 ----
.../devicetree/bindings/net/hisilicon-femac.txt | 41 -------
drivers/net/ethernet/hisilicon/hisi_femac.c | 3 -
drivers/net/mdio/mdio-hisi-femac.c | 18 +--
6 files changed, 161 insertions(+), 83 deletions(-)
---
base-commit: 90d35da658da8cff0d4ecbb5113f5fac9d00eb72
change-id: 20240216-net-9a208e17c40f
Best regards,
--
Yang Xiwen <[email protected]>
From: Yang Xiwen <[email protected]>
HiSilicon FEMAC core is also found on Hi3798MV200 SoC. Document it in
binding. While at it, make "hisilicon,hi3516cv200-femac" as the fallback
compatible.
Signed-off-by: Yang Xiwen <[email protected]>
---
Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml b/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
index 5cd2331668bc..cee10d263d0b 100644
--- a/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
+++ b/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
@@ -14,8 +14,12 @@ allOf:
properties:
compatible:
- enum:
- - hisilicon,hi3516cv300-femac
+ oneOf:
+ - items:
+ - enum:
+ - hisilicon,hi3798mv200-femac
+ - const: hisilicon,hi3516cv300-femac
+ - const: hisilicon,hi3516cv300-femac
reg:
items:
--
2.43.0
From: Yang Xiwen <[email protected]>
FEMAC core always has an integrated MDIO bus mapped in its address
space. Add required properties '#address-cells', 'size-cells', 'ranges'
and MDIO bus subnode.
Reviewed-by: Krzysztof Kozlowski <[email protected]>
Signed-off-by: Yang Xiwen <[email protected]>
---
.../bindings/net/hisilicon,hisi-femac.yaml | 30 ++++++++++++++++++++++
1 file changed, 30 insertions(+)
diff --git a/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml b/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
index 3344d3bfefb8..5cd2331668bc 100644
--- a/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
+++ b/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
@@ -22,6 +22,15 @@ properties:
- description: The first region is the MAC core register base and size.
- description: The second region is the global MAC control register.
+ ranges:
+ maxItems: 1
+
+ '#address-cells':
+ const: 1
+
+ '#size-cells':
+ const: 1
+
interrupts:
maxItems: 1
@@ -57,9 +66,16 @@ properties:
- description: reset pulse for PHY
- description: post-reset delay for PHY
+patternProperties:
+ 'mdio@[0-9a-f]+':
+ $ref: hisilicon,hisi-femac-mdio.yaml#
+
required:
- compatible
- reg
+ - ranges
+ - '#address-cells'
+ - '#size-cells'
- interrupts
- clocks
- resets
@@ -75,6 +91,9 @@ examples:
ethernet@10090000 {
compatible = "hisilicon,hi3516cv300-femac";
reg = <0x10090000 0x1000>, <0x10091300 0x200>;
+ ranges = <0x0 0x10090000 0x10000>;
+ #address-cells = <1>;
+ #size-cells = <1>;
interrupts = <12>;
clocks = <&clk_femac>, <&clk_femacif>, <&clk_fephy>;
clock-names = "mac", "macif", "phy";
@@ -84,4 +103,15 @@ examples:
phy-mode = "mii";
phy-handle = <&fephy>;
hisilicon,phy-reset-delays-us = <10000 20000 20000>;
+
+ mdio@1100 {
+ compatible = "hisilicon,hisi-femac-mdio";
+ reg = <0x1100 0x20>;
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ phy@1 {
+ reg = <1>;
+ };
+ };
};
--
2.43.0
On 08/03/2024 09:39, Yang Xiwen via B4 Relay wrote:
> From: Yang Xiwen <[email protected]>
>
> HiSilicon FEMAC core is also found on Hi3798MV200 SoC. Document it in
> binding. While at it, make "hisilicon,hi3516cv200-femac" as the fallback
> compatible.
>
> Signed-off-by: Yang Xiwen <[email protected]>
> ---
> Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml | 8 ++++++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml b/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
> index 5cd2331668bc..cee10d263d0b 100644
> --- a/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
> +++ b/Documentation/devicetree/bindings/net/hisilicon,hisi-femac.yaml
> @@ -14,8 +14,12 @@ allOf:
>
> properties:
> compatible:
> - enum:
> - - hisilicon,hi3516cv300-femac
If you do not intend to keep it enum, this could be const in the first
place.
Reviewed-by: Krzysztof Kozlowski <[email protected]>
Best regards,
Krzysztof
On 08/03/2024 09:39, Yang Xiwen via B4 Relay wrote:
> Signed-off-by: Yang Xiwen <[email protected]>
> ---
> Changes in v10:
> - binding: make hi3516cv300 the fallback compatible (Krzysztof Kozlowski)
> - driver: drop mv200 match string (Krzysztof Kozlowski)
> - commit msg: remove #conflicts
> - Link to v9: https://lore.kernel.org/r/[email protected]
You dropped one patch without explanation.
Best regards,
Krzysztof
On 3/8/2024 10:43 PM, Krzysztof Kozlowski wrote:
> On 08/03/2024 09:39, Yang Xiwen via B4 Relay wrote:
>> Signed-off-by: Yang Xiwen <[email protected]>
>> ---
>> Changes in v10:
>> - binding: make hi3516cv300 the fallback compatible (Krzysztof Kozlowski)
>> - driver: drop mv200 match string (Krzysztof Kozlowski)
>> - commit msg: remove #conflicts
>> - Link to v9: https://lore.kernel.org/r/[email protected]
> You dropped one patch without explanation.
You are right. It's a stupid mistake. That's the key patch in this
patchset. I think i was going to only remove the new compatible in that
commit but somehow dropped the entire commit.
>
> Best regards,
> Krzysztof
>
--
Regards,
Yang Xiwen