diff mbox series

[kvmtool,2/2] Get __WORDSIZE from <sys/reg.h> for musl compat

Message ID 20240727-musl-v1-2-35013d2f97a0@gmx.net (mailing list archive)
State New, archived
Headers show
Series Fix compilation with musl-libc based toolchains | expand

Commit Message

J. Neuschäfer July 27, 2024, 8:11 a.m. UTC
musl-libc doesn't provide <bits/wordsize.h>, but it defines __WORDSIZE
in <sys/reg.h> and <sys/user.h>.

Signed-off-by: J. Neuschäfer <j.neuschaefer@gmx.net>
---
 include/linux/bitops.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


--
2.43.0
diff mbox series

Patch

diff --git a/include/linux/bitops.h b/include/linux/bitops.h
index ae33922..4f133ba 100644
--- a/include/linux/bitops.h
+++ b/include/linux/bitops.h
@@ -1,7 +1,7 @@ 
 #ifndef _KVM_LINUX_BITOPS_H_
 #define _KVM_LINUX_BITOPS_H_

-#include <bits/wordsize.h>
+#include <sys/reg.h>

 #include <linux/kernel.h>
 #include <linux/compiler.h>