]> git.baikalelectronics.ru Git - kernel.git/commit
net: create skb_gso_validate_mac_len()
authorDaniel Axtens <dja@axtens.net>
Wed, 31 Jan 2018 03:15:33 +0000 (14:15 +1100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 1 Feb 2018 14:36:03 +0000 (09:36 -0500)
commit26134614386049ed3e87e66914d3b995b2d0f958
treefc9e536298bba6872e9f9b8f25359c7afa42c4ea
parent38675fc481f87ccd6195ad794a555778d6e5e3f8
net: create skb_gso_validate_mac_len()

If you take a GSO skb, and split it into packets, will the MAC
length (L2 + L3 + L4 headers + payload) of those packets be small
enough to fit within a given length?

Move skb_gso_mac_seglen() to skbuff.h with other related functions
like skb_gso_network_seglen() so we can use it, and then create
skb_gso_validate_mac_len to do the full calculation.

Signed-off-by: Daniel Axtens <dja@axtens.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/skbuff.h
net/core/skbuff.c
net/sched/sch_tbf.c