2023-06-16 11:29:54

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [RFT PATCH 1/2] stmmac: dwmac-loongson: drop useless check for compatible fallback

Device binds to proper PCI ID (LOONGSON, 0x7a03), already listed in DTS,
so checking for some other compatible does not make sense. It cannot be
bound to unsupported platform.

Drop useless, incorrect (space in between) and undocumented compatible.

Signed-off-by: Krzysztof Kozlowski <[email protected]>
---
drivers/net/ethernet/stmicro/stmmac/dwmac-loongson.c | 5 -----
1 file changed, 5 deletions(-)

diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-loongson.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-loongson.c
index a25c187d3185..900972521b59 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac-loongson.c
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-loongson.c
@@ -59,11 +59,6 @@ static int loongson_dwmac_probe(struct pci_dev *pdev, const struct pci_device_id
return -ENODEV;
}

- if (!of_device_is_compatible(np, "loongson, pci-gmac")) {
- pr_info("dwmac_loongson_pci: Incompatible OF node\n");
- return -ENODEV;
- }
-
plat = devm_kzalloc(&pdev->dev, sizeof(*plat), GFP_KERNEL);
if (!plat)
return -ENOMEM;
--
2.34.1



2023-06-16 19:03:55

by Conor Dooley

[permalink] [raw]
Subject: Re: [RFT PATCH 1/2] stmmac: dwmac-loongson: drop useless check for compatible fallback

On Fri, Jun 16, 2023 at 12:31:26PM +0200, Krzysztof Kozlowski wrote:
> Device binds to proper PCI ID (LOONGSON, 0x7a03), already listed in DTS,
> so checking for some other compatible does not make sense. It cannot be
> bound to unsupported platform.
>
> Drop useless, incorrect (space in between) and undocumented compatible.
>
> Signed-off-by: Krzysztof Kozlowski <[email protected]>

Might be worth noting that dropping it is required to allow the
new loongarch dts stuff to be functional with a sane set of compatibles.

Reviewed-by: Conor Dooley <[email protected]>

Cheers,
Conor.


Attachments:
(No filename) (628.00 B)
signature.asc (235.00 B)
Download all attachments

2023-12-10 06:49:13

by Yanteng Si

[permalink] [raw]
Subject: Re: [RFT PATCH 1/2] stmmac: dwmac-loongson: drop useless check for compatible fallback


在 2023/6/17 02:52, Conor Dooley 写道:
> On Fri, Jun 16, 2023 at 12:31:26PM +0200, Krzysztof Kozlowski wrote:
>> Device binds to proper PCI ID (LOONGSON, 0x7a03), already listed in DTS,
>> so checking for some other compatible does not make sense. It cannot be
>> bound to unsupported platform.
>>
>> Drop useless, incorrect (space in between) and undocumented compatible.
>>
>> Signed-off-by: Krzysztof Kozlowski <[email protected]>
> Might be worth noting that dropping it is required to allow the
> new loongarch dts stuff to be functional with a sane set of compatibles.
>
> Reviewed-by: Conor Dooley <[email protected]>
Thank you Krzysztof for your work. when I am
adding more devices support to stmmac, I found that your
two patches seemed to be forgotten.
Thomas, Jiaxun. Can the two patches get an Acked-by?
My stmmac patch thread:
<https://lore.kernel.org/loongarch/cover.1699533745.git
[email protected]/T/#md3108d29a5efe71b27f4c5ccf5d0217571bf6586>
Thanks,
Yanteng

>
> Cheers,
> Conor.

2023-12-11 09:26:22

by Jiaxun Yang

[permalink] [raw]
Subject: Re: [RFT PATCH 1/2] stmmac: dwmac-loongson: drop useless check for compatible fallback



在2023年12月10日十二月 上午6:48,Yanteng Si写道:
> 在 2023/6/17 02:52, Conor Dooley 写道:
>> On Fri, Jun 16, 2023 at 12:31:26PM +0200, Krzysztof Kozlowski wrote:
>>> Device binds to proper PCI ID (LOONGSON, 0x7a03), already listed in DTS,
>>> so checking for some other compatible does not make sense. It cannot be
>>> bound to unsupported platform.
>>>
>>> Drop useless, incorrect (space in between) and undocumented compatible.
>>>
>>> Signed-off-by: Krzysztof Kozlowski <[email protected]>
>> Might be worth noting that dropping it is required to allow the
>> new loongarch dts stuff to be functional with a sane set of compatibles.
>>
>> Reviewed-by: Conor Dooley <[email protected]>
> Thank you Krzysztof for your work. when I am
> adding more devices support to stmmac, I found that your
> two patches seemed to be forgotten.
> Thomas, Jiaxun. Can the two patches get an Acked-by?
> My stmmac patch thread:
> <https://lore.kernel.org/loongarch/cover.1699533745.git
> [email protected]/T/#md3108d29a5efe71b27f4c5ccf5d0217571bf6586>

Acked-by: Jiaxun Yang <[email protected]>

Better to resend without RFC :-)

Thanks

> Thanks,
> Yanteng
>
>>
>> Cheers,
>> Conor.

--
- Jiaxun