Tomoyo build warnings
Tetsuo Handa
penguin-kernel at i-love.sakura.ne.jp
Thu May 9 03:56:27 UTC 2019
On 2019/05/09 7:54, James Morris wrote:
> I'm seeing these during a kernel build in my tree:
Well, it seems that clang-4 and gcc-9 got this new warning, and
Linus Torvalds recently silenced this warning...
commit 6f303d60534c46aa1a239f29c321f95c83dda748
Author: Linus Torvalds <torvalds at linux-foundation.org>
Date: Wed May 1 11:05:41 2019 -0700
gcc-9: silence 'address-of-packed-member' warning
We already did this for clang, but now gcc has that warning too. Yes,
yes, the address may be unaligned. And that's kind of the point.
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Since "struct list_head" consists of aligned two pointers, I wonder
how a member next to "struct list_head" can fail to be aligned...
struct tomoyo_shared_acl_head {
struct list_head list;
atomic_t users;
} __packed;
But since this structure is not visible from userspace, I can accept
dropping __packed and wasting a few bytes if that commit doesn't go upstream.
More information about the Linux-security-module-archive
mailing list