]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: factor skb freeing on xmit
authorVivien Didelot <vivien.didelot@savoirfairelinux.com>
Thu, 1 Jun 2017 20:07:15 +0000 (16:07 -0400)
committerDavid S. Miller <davem@davemloft.net>
Thu, 1 Jun 2017 21:34:56 +0000 (17:34 -0400)
commit1355fdfed396366120a5017d9f11f50c06d92d14
treea45ba1a54b080a3a71e4650f03d57ac3de3767e8
parentc5a14946b27b8274c1a12037b0087a1eaf201d3e
net: dsa: factor skb freeing on xmit

As of a225a7749824 ("net: dsa: Factor bottom tag receive functions"),
the rcv caller frees the original SKB in case or error.

Be symmetric with that and make the xmit caller do the same.

At the same time, fix the checkpatch NULL comparison check:

        CHECK: Comparison to NULL could be written "!nskb"
    #208: FILE: net/dsa/tag_trailer.c:35:
    + if (nskb == NULL)

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/dsa/slave.c
net/dsa/tag_brcm.c
net/dsa/tag_dsa.c
net/dsa/tag_edsa.c
net/dsa/tag_ksz.c
net/dsa/tag_lan9303.c
net/dsa/tag_mtk.c
net/dsa/tag_qca.c
net/dsa/tag_trailer.c