Skip to contentSkip to conversation

drivers: net: dwmac: Add use_hw_vlan setting

PATCH In review Boon Khai Ng 1 participant 2 messages Mar 30, 2023

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 4/8 drivers: net: dwmac: Add use_hw_vlan setting

This is to handle the use_hw_vlan setting at dwmac-socfpga level.

---
 drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 6 ++++++
 1 file changed, 6 insertions(+)
drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c +6 -0
index 067a40fe0a23..26da3a9da345 100644
@@ -537,6 +537,12 @@ stmmac_probe_config_dt(struct platform_device *pdev, u8 *mac)
 		plat->has_xgmac = 1;
 		plat->pmt = 1;
 		plat->tso_en = of_property_read_bool(np, "snps,tso");
+
+		/* Rx VLAN HW Stripping */
+		if (of_property_read_bool(np, "snps,rx-vlan-offload")) {
+			dev_info(&pdev->dev, "RX VLAN HW Stripping\n");
+			plat->use_hw_vlan = true;
+		}
 	}
 
 	dma_cfg = devm_kzalloc(&pdev->dev, sizeof(*dma_cfg),
Signature · 1 line
2.25.1
#1 lore raw

Please ignore this review, send out by accident.

My appologies for sending out this review by accident, this is meant for internal reivew, kindly ignore and close this thread. Thanks.