mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-23 15:27:29 +00:00
net: Kill skb_truesize_check(), it only catches false-positives.
A long time ago we had bugs, primarily in TCP, where we would modify skb->truesize (for TSO queue collapsing) in ways which would corrupt the socket memory accounting. skb_truesize_check() was added in order to try and catch this error more systematically. However this debugging check has morphed into a Frankenstein of sorts and these days it does nothing other than catch false-positives. Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
34edaa8832
commit
92a0acce18
4 changed files with 0 additions and 19 deletions
|
@ -416,15 +416,6 @@ extern void skb_over_panic(struct sk_buff *skb, int len,
|
|||
void *here);
|
||||
extern void skb_under_panic(struct sk_buff *skb, int len,
|
||||
void *here);
|
||||
extern void skb_truesize_bug(struct sk_buff *skb);
|
||||
|
||||
static inline void skb_truesize_check(struct sk_buff *skb)
|
||||
{
|
||||
int len = sizeof(struct sk_buff) + skb->len;
|
||||
|
||||
if (unlikely((int)skb->truesize < len))
|
||||
skb_truesize_bug(skb);
|
||||
}
|
||||
|
||||
extern int skb_append_datato_frags(struct sock *sk, struct sk_buff *skb,
|
||||
int getfrag(void *from, char *to, int offset,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue