linux-next: build failure after merge of the access_once tree
Subsystems (3)
Hi Christian,
After merging the access_once tree, today's linux-next build (x86_64 allmodconfig) failed like this:
In file included from include/linux/compiler.h:189:0,
from include/uapi/linux/stddef.h:1,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4, from include/linux/fdtable.h:8,
from security/apparmor/domain.c:16:include/linux/types.h:14:9: error: unknown type name '__kernel_fd_set'
typedef __kernel_fd_set fd_set;
^And many more :-(
Presumably caused by commit b06f66134856 ("kernel: Provide READ_ONCE and ASSIGN_ONCE") which added types.h into compiler.h, but I am not sure. It could be an interaction with something else in linux-next, of course.
I have dropped the access_once tree for today, sorry.
Signature · 2 lines
Cheers, Stephen Rothwell [email protected]
Am 05.12.2014 um 11:32 schrieb Stephen Rothwell:
Quoted 15 lines
Hi Christian,
After merging the
access_oncetree, today's linux-next build (x86_64allmodconfig) failed like this:In file included from
include/linux/compiler.h:189:0,
frominclude/uapi/linux/stddef.h:1,
frominclude/linux/stddef.h:4,
frominclude/uapi/linux/posix_types.h:4, frominclude/linux/fdtable.h:8,
fromsecurity/apparmor/domain.c:16:include/linux/types.h:14:9: error: unknown type name '__kernel_fd_set'typedef __kernel_fd_set fd_set; ^
Quoted 9 lines
And many more :-(
Presumably caused by commit
b06f66134856("kernel: ProvideREAD_ONCEandASSIGN_ONCE") which addedtypes.hintocompiler.h, but I am not sure. It could be an interaction with something else in linux-next, of course.I have dropped the
access_oncetree for today, sorry.
Interesting, I double checked with defconfig and cross compilation. But yes, using allmodconfig fails. I have changed that to uapi/linux/types.h and __u<xx>. This seems to fix it as it only adds a small set of types.
Can you re-add?
Christian
Am 07.12.2014 um 21:57 schrieb Christian Borntraeger:
Quoted 26 lines
Am 05.12.2014 um 11:32 schrieb Stephen Rothwell:
Quoted 15 lines
Hi Christian,
After merging the
access_oncetree, today's linux-next build (x86_64allmodconfig) failed like this:In file included from
include/linux/compiler.h:189:0,
frominclude/uapi/linux/stddef.h:1,
frominclude/linux/stddef.h:4,
frominclude/uapi/linux/posix_types.h:4, frominclude/linux/fdtable.h:8,
fromsecurity/apparmor/domain.c:16:include/linux/types.h:14:9: error: unknown type name '__kernel_fd_set'typedef __kernel_fd_set fd_set; ^Quoted 9 lines
And many more :-(
Presumably caused by commit
b06f66134856("kernel: ProvideREAD_ONCEandASSIGN_ONCE") which addedtypes.hintocompiler.h, but I am not sure. It could be an interaction with something else in linux-next, of course.I have dropped the
access_oncetree for today, sorry.
Quoted 7 lines
Interesting, I double checked with defconfig and cross compilation. But yes, using allmodconfig fails. I have changed that to
uapi/linux/types.hand __u<xx>. This seems to fix it as it only adds a small set of types.Can you re-add?
Christian
I also did an additional check and merged this tree with linux-next/master. This introduced a new problem. The fix is simple, see patch. But I am not sure how to add that to next (via my tree), since this change is only in next.
Christian
Quoted 1 line
From
ef62db716c9edb1343c00eae45ad8f6c0c1c9255Mon Sep 17 00:00:00 2001
From: Christian Borntraeger <[email protected]>
Date: Sun, 7 Dec 2014 22:01:59 +0100
Subject: [PATCH] x86/xen/p2m: Replace ACCESS_ONCE with READ_ONCE
ACCESS_ONCE does not work reliably on non-scalar types. For example gcc 4.6 and 4.7 might remove the volatile tag for such accesses during the SRA (scalar replacement of aggregates) step
(https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58145)
Change the p2m code to replace ACCESS_ONCE with READ_ONCE.
--- arch/x86/xen/p2m.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/xen/p2m.c +1 -1
@@ -554,7 +554,7 @@ static bool alloc_p2m(unsigned long pfn) mid_mfn =NULL ; } - p2m_pfn =pte_pfn (ACCESS_ONCE (*ptep)); + p2m_pfn =pte_pfn (READ_ONCE (*ptep));if (p2m_pfn ==PFN_DOWN (__pa (p2m_identity)) || p2m_pfn ==PFN_DOWN (__pa (p2m_missing))) {/* p2m leaf page is missing */
Signature · 1 line
1.8.5.5
Hi Christian,
Quoted 3 lines · On Sun, 07 Dec 2014 22:16:41 +0100 Christian Borntraeger…
I also did an additional check and merged this tree with linux-next/master. This introduced a new problem. The fix is simple, see patch. But I am not sure how to add that to next (via my tree), since this change is only in next.
OK, thanks for that. I will apply that patch as a merge fix to my tree when I merge your tree. You (or the owner of the conflicting tree) will need to let Linus know when the merge happens in his tree.
Signature · 2 lines
Cheers, Stephen Rothwell [email protected]