aboutsummaryrefslogtreecommitdiff
path: root/emulators/qemu-devel/files/patch-util_cpuinfo-ppc.c
blob: ae39b6c3f4ae4b8238629ff692eca698780bb55a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
--- util/cpuinfo-ppc.c.orig	2024-01-26 18:16:35 UTC
+++ util/cpuinfo-ppc.c
@@ -6,11 +6,17 @@
 #include "qemu/osdep.h"
 #include "host/cpuinfo.h"
 
-#include <asm/cputable.h>
 #ifdef CONFIG_GETAUXVAL
 # include <sys/auxv.h>
+# ifdef __linux__
+#  include <asm/cputable.h>
+# endif
 #else
 # include "elf.h"
+#endif
+
+#ifndef PPC_FEATURE2_ARCH_3_1
+# define PPC_FEATURE2_ARCH_3_1       0x00040000
 #endif
 
 unsigned cpuinfo;