starfive: add new target for StarFive JH7100/7110 SoC
[openwrt/staging/981213.git] / target / linux / starfive / patches-6.1 / 0041-net-stmmac-platform-Add-snps-dwmac-5.20-IP-compatibl.patch
1 From cb00f835fc9f3ece473e7081f17c8613bf08a8ef Mon Sep 17 00:00:00 2001
2 From: Emil Renner Berthing <kernel@esmil.dk>
3 Date: Sun, 7 Aug 2022 22:26:00 +0200
4 Subject: [PATCH 041/122] net: stmmac: platform: Add snps,dwmac-5.20 IP
5 compatible string
6
7 Add "snps,dwmac-5.20" compatible string for 5.20 version that can avoid
8 to define some platform data in the glue layer.
9
10 Tested-by: Tommaso Merciai <tomm.merciai@gmail.com>
11 Signed-off-by: Emil Renner Berthing <kernel@esmil.dk>
12 Signed-off-by: Paolo Abeni <pabeni@redhat.com>
13 Signed-off-by: Samin Guo <samin.guo@starfivetech.com>
14 ---
15 drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 3 ++-
16 1 file changed, 2 insertions(+), 1 deletion(-)
17
18 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
19 +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
20 @@ -519,7 +519,8 @@ stmmac_probe_config_dt(struct platform_d
21 if (of_device_is_compatible(np, "snps,dwmac-4.00") ||
22 of_device_is_compatible(np, "snps,dwmac-4.10a") ||
23 of_device_is_compatible(np, "snps,dwmac-4.20a") ||
24 - of_device_is_compatible(np, "snps,dwmac-5.10a")) {
25 + of_device_is_compatible(np, "snps,dwmac-5.10a") ||
26 + of_device_is_compatible(np, "snps,dwmac-5.20")) {
27 plat->has_gmac4 = 1;
28 plat->has_gmac = 0;
29 plat->pmt = 1;