diff mbox series

[net,2/3] net: dsa: rtl4_a: Drop skb_cow_head()

Message ID 20210301133241.1277164-2-linus.walleij@linaro.org
State New
Headers show
Series [net,1/3] net: dsa: rtl4_a: Pad using __skb_put_padto() | expand

Commit Message

Linus Walleij March 1, 2021, 1:32 p.m. UTC
The DSA core already provides the tag headroom, drop this.

Fixes: 86dd9868b878 ("net: dsa: tag_rtl4_a: Support also egress tags")
Reported-by: Andrew Lunn <andrew@lunn.ch>
Reported-by: DENG Qingfang <dqfext@gmail.com>
Cc: Mauri Sandberg <sandberg@mailfence.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>

---
 net/dsa/tag_rtl4_a.c | 2 --
 1 file changed, 2 deletions(-)

-- 
2.29.2

Comments

Florian Fainelli March 2, 2021, 1:41 a.m. UTC | #1
On 3/1/2021 5:32 AM, Linus Walleij wrote:
> The DSA core already provides the tag headroom, drop this.

> 

> Fixes: 86dd9868b878 ("net: dsa: tag_rtl4_a: Support also egress tags")

> Reported-by: Andrew Lunn <andrew@lunn.ch>

> Reported-by: DENG Qingfang <dqfext@gmail.com>

> Cc: Mauri Sandberg <sandberg@mailfence.com>

> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>


Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>

-- 
Florian
diff mbox series

Patch

diff --git a/net/dsa/tag_rtl4_a.c b/net/dsa/tag_rtl4_a.c
index 804d756dd80a..8098d81f660b 100644
--- a/net/dsa/tag_rtl4_a.c
+++ b/net/dsa/tag_rtl4_a.c
@@ -42,8 +42,6 @@  static struct sk_buff *rtl4a_tag_xmit(struct sk_buff *skb,
 	/* Pad out to at least 60 bytes */
 	if (__skb_put_padto(skb, ETH_ZLEN, false))
 		return NULL;
-	if (skb_cow_head(skb, RTL4_A_HDR_LEN) < 0)
-		return NULL;
 
 	netdev_dbg(dev, "add realtek tag to package to port %d\n",
 		   dp->index);