]> git.baikalelectronics.ru Git - kernel.git/commit
sctp: move sent_count to the memory hole in sctp_chunk
authorXin Long <lucien.xin@gmail.com>
Wed, 28 Sep 2016 18:37:26 +0000 (02:37 +0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 30 Sep 2016 06:07:05 +0000 (02:07 -0400)
commit33721aca1c8ff5efe4b7a6a35324873efa84ce7b
tree3c25a84f0e3d4e9446f644d4a4e0311a6cf0aeb4
parentc587c4ac4d00a0d23a6ca88c3e1defbc42f957fd
sctp: move sent_count to the memory hole in sctp_chunk

Now pahole sctp_chunk, it has 2 memory holes:
   struct sctp_chunk {
struct list_head           list;
atomic_t                   refcnt;
/* XXX 4 bytes hole, try to pack */
...
long unsigned int          prsctp_param;
int                        sent_count;
/* XXX 4 bytes hole, try to pack */

This patch is to move up sent_count to fill the 1st one and eliminate
the 2nd one.

It's not just another struct compaction, it also fixes the "netperf-
Throughput_Mbps -37.2% regression" issue when overloading the CPU.

Fixes: 0114c198730e ("sctp: implement prsctp TTL policy")
Signed-off-by: Xin Long <lucien.xin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/sctp/structs.h