net-device: reorganize net_device fast path variables
authorCoco Li <lixiaoyan@google.com>
Mon, 4 Dec 2023 20:12:30 +0000 (20:12 +0000)
committerJakub Kicinski <kuba@kernel.org>
Wed, 6 Dec 2023 04:16:05 +0000 (20:16 -0800)
commit43a71cd66b9c0a4af3d15d8644359fde35bdbed0
treeb41dbe519b999a23ed3bd12fdc0e97d61b4ef744
parent5aa00e9e41f2742223fe4ca89d94410d2477118d
net-device: reorganize net_device fast path variables

Reorganize fast path variables on tx-txrx-rx order
Fastpath variables end after npinfo.

Below data generated with pahole on x86 architecture.

Fast path variables span cache lines before change: 12
Fast path variables span cache lines after change: 4

Suggested-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Coco Li <lixiaoyan@google.com>
Reviewed-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Link: https://lore.kernel.org/r/20231204201232.520025-2-lixiaoyan@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
include/linux/netdevice.h
net/core/dev.c