diff mbox series

[net-next,v4,3/6] dt-bindings: net: remove outdated hisilicon-femac

Message ID 20240222-net-v4-3-eea68f93f090@outlook.com (mailing list archive)
State Superseded
Delegated to: Netdev Maintainers
Headers show
Series net: hisi-femac: add support for Hi3798MV200, remove unmaintained compatibles | expand

Checks

Context Check Description
netdev/series_format success Posting correctly formatted
netdev/tree_selection success Clearly marked for net-next
netdev/ynl success Generated files up to date; no warnings/errors; no diff in generated;
netdev/fixes_present success Fixes tag not required for -next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 8 this patch: 8
netdev/build_tools success No tools touched, skip
netdev/cc_maintainers success CCed 10 of 10 maintainers
netdev/build_clang success Errors and warnings before: 8 this patch: 8
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 8 this patch: 8
netdev/checkpatch warning WARNING: DT binding docs and includes should be a separate patch. See: Documentation/devicetree/bindings/submitting-patches.rst WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
netdev/build_clang_rust success No Rust files in patch. Skipping build
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0
netdev/contest success net-next-2024-02-23--03-00 (tests: 1457)

Commit Message

Yang Xiwen via B4 Relay Feb. 22, 2024, 12:43 p.m. UTC
From: Yang Xiwen <forbidden405@outlook.com>

The user documented(Hi3516) is not found in current kernel anymore. And
it seems this SoC has been EOL for a long time. While at it, Remove this
binding entirely due to recent driver changes.

Signed-off-by: Yang Xiwen <forbidden405@outlook.com>
---
 .../devicetree/bindings/net/hisilicon-femac.txt    | 41 ----------------------
 1 file changed, 41 deletions(-)

Comments

Krzysztof Kozlowski Feb. 26, 2024, 7:50 a.m. UTC | #1
On 22/02/2024 13:43, Yang Xiwen via B4 Relay wrote:
> From: Yang Xiwen <forbidden405@outlook.com>
> 
> The user documented(Hi3516) is not found in current kernel anymore. And
> it seems this SoC has been EOL for a long time. While at it, Remove this
> binding entirely due to recent driver changes.

This removes documented compatibles, which:
1. should cause checkpatch issues,
2. is not what we want.

Driver is still there, so first the driver would have to be removed...
but then why do you add it immediately back? No, it does not work like that.

Best regards,
Krzysztof
Yang Xiwen Feb. 27, 2024, 1:43 a.m. UTC | #2
On 2/26/2024 3:50 PM, Krzysztof Kozlowski wrote:
> On 22/02/2024 13:43, Yang Xiwen via B4 Relay wrote:
>> From: Yang Xiwen <forbidden405@outlook.com>
>>
>> The user documented(Hi3516) is not found in current kernel anymore. And
>> it seems this SoC has been EOL for a long time. While at it, Remove this
>> binding entirely due to recent driver changes.
> 
> This removes documented compatibles, which:
> 1. should cause checkpatch issues,
> 2. is not what we want.
> 
> Driver is still there, so first the driver would have to be removed...
> but then why do you add it immediately back? No, it does not work like that.

I has downloaded TRM for this old Hi3519 SoC. So i think with the new
driver, it still works for Hi3519 FEMAC controller. So i'll rewrite
these 3 patches and describe the whole thing in commit logs. i.e. the
old binding is wrong, inconsistent with real hardware, etc..

So you mean conversion to YAML first, in a separate commit. And then do
necessary edition to match the real hardware? I believe Hi3519 FEMAC and
Hi3798MV200 FEMAC are compatible in hardware. So the old binding is
wrong, missing critical hardware resources.

> 
> Best regards,
> Krzysztof
>
Krzysztof Kozlowski Feb. 27, 2024, 6:51 a.m. UTC | #3
On 27/02/2024 02:43, Yang Xiwen wrote:
> On 2/26/2024 3:50 PM, Krzysztof Kozlowski wrote:
>> On 22/02/2024 13:43, Yang Xiwen via B4 Relay wrote:
>>> From: Yang Xiwen <forbidden405@outlook.com>
>>>
>>> The user documented(Hi3516) is not found in current kernel anymore. And
>>> it seems this SoC has been EOL for a long time. While at it, Remove this
>>> binding entirely due to recent driver changes.
>>
>> This removes documented compatibles, which:
>> 1. should cause checkpatch issues,
>> 2. is not what we want.
>>
>> Driver is still there, so first the driver would have to be removed...
>> but then why do you add it immediately back? No, it does not work like that.
> 
> I has downloaded TRM for this old Hi3519 SoC. So i think with the new
> driver, it still works for Hi3519 FEMAC controller. So i'll rewrite
> these 3 patches and describe the whole thing in commit logs. i.e. the
> old binding is wrong, inconsistent with real hardware, etc..
> 
> So you mean conversion to YAML first, in a separate commit. And then do
> necessary edition to match the real hardware? I believe Hi3519 FEMAC and
> Hi3798MV200 FEMAC are compatible in hardware. So the old binding is
> wrong, missing critical hardware resources.

If you remove binding, then it has to be done in reverse order than
adding it (see DT submitting patches). However removing binding and
re-adding it, is not what you think. It's a obfuscated way to make a
change, so better just make a change and explicitly say why and what is
happening

Best regards,
Krzysztof
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/net/hisilicon-femac.txt b/Documentation/devicetree/bindings/net/hisilicon-femac.txt
deleted file mode 100644
index 5f96976f3cea..000000000000
--- a/Documentation/devicetree/bindings/net/hisilicon-femac.txt
+++ /dev/null
@@ -1,41 +0,0 @@ 
-Hisilicon Fast Ethernet MAC controller
-
-Required properties:
-- compatible: should contain one of the following version strings:
-	* "hisilicon,hisi-femac-v1"
-	* "hisilicon,hisi-femac-v2"
-	and the soc string "hisilicon,hi3516cv300-femac".
-- reg: specifies base physical address(s) and size of the device registers.
-  The first region is the MAC core register base and size.
-  The second region is the global MAC control register.
-- interrupts: should contain the MAC interrupt.
-- clocks: A phandle to the MAC main clock.
-- resets: should contain the phandle to the MAC reset signal(required) and
-	the PHY reset signal(optional).
-- reset-names: should contain the reset signal name "mac"(required)
-	and "phy"(optional).
-- phy-mode: see ethernet.txt [1].
-- phy-handle: see ethernet.txt [1].
-- hisilicon,phy-reset-delays-us: triplet of delays if PHY reset signal given.
-	The 1st cell is reset pre-delay in micro seconds.
-	The 2nd cell is reset pulse in micro seconds.
-	The 3rd cell is reset post-delay in micro seconds.
-
-The MAC address will be determined using the optional properties
-defined in ethernet.txt[1].
-
-[1] Documentation/devicetree/bindings/net/ethernet.txt
-
-Example:
-	hisi_femac: ethernet@10090000 {
-		compatible = "hisilicon,hi3516cv300-femac","hisilicon,hisi-femac-v2";
-		reg = <0x10090000 0x1000>,<0x10091300 0x200>;
-		interrupts = <12>;
-		clocks = <&crg HI3518EV200_ETH_CLK>;
-		resets = <&crg 0xec 0>,<&crg 0xec 3>;
-		reset-names = "mac","phy";
-		mac-address = [00 00 00 00 00 00];
-		phy-mode = "mii";
-		phy-handle = <&phy0>;
-		hisilicon,phy-reset-delays-us = <10000 20000 20000>;
-	};