From: Eric Dumazet Date: Fri, 11 Oct 2019 18:11:40 +0000 (-0700) Subject: bpf: Align struct bpf_prog_stats X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=84a081f60db63aaae3665118203506aa09a7f94f;p=linux.git bpf: Align struct bpf_prog_stats Do not risk spanning these small structures on two cache lines. Signed-off-by: Eric Dumazet Signed-off-by: Daniel Borkmann Link: https://lore.kernel.org/bpf/20191011181140.2898-1-edumazet@google.com --- diff --git a/include/linux/bpf.h b/include/linux/bpf.h index 5b9d223386065..282e28bf41ec6 100644 --- a/include/linux/bpf.h +++ b/include/linux/bpf.h @@ -363,7 +363,7 @@ struct bpf_prog_stats { u64 cnt; u64 nsecs; struct u64_stats_sync syncp; -}; +} __aligned(2 * sizeof(u64)); struct bpf_prog_aux { atomic_t refcnt;