Hide Forgot
Description of problem: Including linux/swab.h as follows: #include <linux/swab.h> void main(){ } results in build failure: In file included from test.c:2:0: /usr/include/linux/swab.h:154:8: error: unknown type name ‘__always_inline’ static __always_inline __u16 __swab16p(const __u16 *p) ^~~~~~~~~~~~~~~ /usr/include/linux/swab.h:154:30: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘__swab16p’ static __always_inline __u16 __swab16p(const __u16 *p) ^~~~~~~~~ /usr/include/linux/swab.h:167:8: error: unknown type name ‘__always_inline’ static __always_inline __u32 __swab32p(const __u32 *p) ^~~~~~~~~~~~~~~ /usr/include/linux/swab.h:167:30: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘__swab32p’ static __always_inline __u32 __swab32p(const __u32 *p) ^~~~~~~~~ /usr/include/linux/swab.h:180:8: error: unknown type name ‘__always_inline’ static __always_inline __u64 __swab64p(const __u64 *p) ^~~~~~~~~~~~~~~ /usr/include/linux/swab.h:180:30: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘__swab64p’ static __always_inline __u64 __swab64p(const __u64 *p) ^~~~~~~~~ /usr/include/linux/swab.h:235:24: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ static __always_inline void __swab32s(__u32 *p) ^~~~ /usr/include/linux/swab.h:248:24: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ static __always_inline void __swab64s(__u64 *p) ^~~~ Version-Release number of selected component (if applicable): kernel-headers-4.6.0-0.rc0.git20.1.fc25.x86_64 How reproducible: Always Note that this prevents qemu from building.
I've reported this upstream. It's likely because of commit bc27fb68aaad44dd8f5c34924f05721f0abaeec1. We'll see what they suggest.
Do you happen to have the upstream bug so I may follow along?
(In reply to John Dulaney from comment #2) > Do you happen to have the upstream bug so I may follow along? No. It wasn't an upstream bugzilla. I sent an email to the upstream maintainers. Unfortunately, I also forgot to CC any relevant mailing lists so it isn't archived anywhere. I've yet to get a reply but I'll be sure to CC lkml if/when I do.
I've included the upstream patch for this in Fedora git now. It will be fixed in the next build.
Fixed in 4.6.0-0.rc1.git0.3.fc25. Will be in tomorrow's compose.