diff --git a/target/linux/rockchip/files/arch/arm64/boot/dts/rockchip/rk3588s-nanopi-r6s.dts b/target/linux/rockchip/files/arch/arm64/boot/dts/rockchip/rk3588s-nanopi-r6s.dts index e72ada221e..1be0329925 100644 --- a/target/linux/rockchip/files/arch/arm64/boot/dts/rockchip/rk3588s-nanopi-r6s.dts +++ b/target/linux/rockchip/files/arch/arm64/boot/dts/rockchip/rk3588s-nanopi-r6s.dts @@ -189,6 +189,7 @@ &gmac1_rx_bus2 &gmac1_rgmii_clk &gmac1_rgmii_bus>; + snps,no-vlhash; snps,reset-gpio = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>; snps,reset-active-low; /* Reset time is 20ms, 100ms for rtl8211f */ diff --git a/target/linux/rockchip/patches-6.6/600-ethernet-stmmac-Add-property-to-disable-VLAN-hw-filter.patch b/target/linux/rockchip/patches-6.6/600-ethernet-stmmac-Add-property-to-disable-VLAN-hw-filter.patch new file mode 100644 index 0000000000..d0f73e2657 --- /dev/null +++ b/target/linux/rockchip/patches-6.6/600-ethernet-stmmac-Add-property-to-disable-VLAN-hw-filter.patch @@ -0,0 +1,48 @@ +From 32230f9e59438899c949a4bab178a8f10f17b903 Mon Sep 17 00:00:00 2001 +From: jensen +Date: Thu, 17 Nov 2022 18:35:43 +0800 +Subject: [PATCH] ethernet: stmmac: Add property to disable VLAN hw filter + +Since adding VLAN in promisc mode not supported, which makes unable to +setup bridge, add a configurable option to disable it. + +Signed-off-by: jensen +--- + drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 2 +- + drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 3 +++ + include/linux/stmmac.h | 1 + + 3 files changed, 5 insertions(+), 1 deletion(-) + +--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c ++++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +@@ -7528,7 +7528,7 @@ int stmmac_dvr_probe(struct device *devi + #ifdef STMMAC_VLAN_TAG_USED + /* Both mac100 and gmac support receive VLAN tag detection */ + ndev->features |= NETIF_F_HW_VLAN_CTAG_RX | NETIF_F_HW_VLAN_STAG_RX; +- if (priv->dma_cap.vlhash) { ++ if (priv->plat->vlhash_en && priv->dma_cap.vlhash) { + ndev->features |= NETIF_F_HW_VLAN_CTAG_FILTER; + ndev->features |= NETIF_F_HW_VLAN_STAG_FILTER; + } +--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c ++++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c +@@ -570,6 +570,9 @@ stmmac_probe_config_dt(struct platform_d + "force_sf_dma_mode is ignored if force_thresh_dma_mode is set.\n"); + } + ++ /* To disable VLAN tag filter */ ++ plat->vlhash_en = !of_property_read_bool(np, "snps,no-vlhash"); ++ + of_property_read_u32(np, "snps,ps-speed", &plat->mac_port_sel_speed); + + plat->axi = stmmac_axi_setup(pdev); +--- a/include/linux/stmmac.h ++++ b/include/linux/stmmac.h +@@ -300,6 +300,7 @@ struct plat_stmmacenet_data { + int rss_en; + int mac_port_sel_speed; + int has_xgmac; ++ bool vlhash_en; + u8 vlan_fail_q; + unsigned int eee_usecs_rate; + struct pci_dev *pdev; diff --git a/target/linux/rockchip/patches-6.6/602-net-ethernet-r8169-add-devname-configuration-from-OF.patch b/target/linux/rockchip/patches-6.6/602-net-ethernet-r8169-add-devname-configuration-from-OF.patch index 668254f9fc..8deb922ba1 100644 --- a/target/linux/rockchip/patches-6.6/602-net-ethernet-r8169-add-devname-configuration-from-OF.patch +++ b/target/linux/rockchip/patches-6.6/602-net-ethernet-r8169-add-devname-configuration-from-OF.patch @@ -8,7 +8,7 @@ #include #include #include -@@ -5413,6 +5414,7 @@ static int rtl_init_one(struct pci_dev * +@@ -5409,6 +5410,7 @@ static int rtl_init_one(struct pci_dev * int jumbo_max, region, rc; enum mac_version chipset; struct net_device *dev; @@ -16,7 +16,7 @@ u32 txconfig; u16 xid; -@@ -5420,6 +5422,9 @@ static int rtl_init_one(struct pci_dev * +@@ -5416,6 +5418,9 @@ static int rtl_init_one(struct pci_dev * if (!dev) return -ENOMEM;