Files
linux/net/sctp
Xin Long 605c0ac182 sctp: count both sk and asoc sndbuf with skb truesize and sctp_chunk size
Now it's confusing that asoc sndbuf_used is doing memory accounting with
SCTP_DATA_SNDSIZE(chunk) + sizeof(sk_buff) + sizeof(sctp_chunk) while sk
sk_wmem_alloc is doing that with skb->truesize + sizeof(sctp_chunk).

It also causes sctp_prsctp_prune to count with a wrong freed memory when
sndbuf_policy is not set.

To make this right and also keep consistent between asoc sndbuf_used, sk
sk_wmem_alloc and sk_wmem_queued, use skb->truesize + sizeof(sctp_chunk)
for them.

Signed-off-by: Xin Long <lucien.xin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-10-18 11:23:47 -07:00
..
2018-06-12 16:19:22 -07:00
2018-02-13 13:56:31 -05:00
2018-06-22 13:43:27 +09:00
2018-07-24 14:10:42 -07:00
2018-02-13 13:56:31 -05:00
2018-07-24 14:10:42 -07:00
2018-09-10 10:06:53 -07:00