@@ -22,8 +22,8 @@ static inline bool have_cpuid_p(void)
22
22
}
23
23
#endif
24
24
25
- static inline void native_cpuid (unsigned int * eax , unsigned int * ebx ,
26
- unsigned int * ecx , unsigned int * edx )
25
+ static inline void native_cpuid (u32 * eax , u32 * ebx ,
26
+ u32 * ecx , u32 * edx )
27
27
{
28
28
/* ecx is often an input as well as an output. */
29
29
asm volatile ("cpuid"
@@ -36,9 +36,9 @@ static inline void native_cpuid(unsigned int *eax, unsigned int *ebx,
36
36
}
37
37
38
38
#define NATIVE_CPUID_REG (reg ) \
39
- static inline unsigned int native_cpuid_##reg(unsigned int op) \
39
+ static inline u32 native_cpuid_##reg(u32 op) \
40
40
{ \
41
- unsigned int eax = op, ebx, ecx = 0, edx; \
41
+ u32 eax = op, ebx, ecx = 0, edx; \
42
42
\
43
43
native_cpuid(&eax, &ebx, &ecx, &edx); \
44
44
\
@@ -65,19 +65,19 @@ NATIVE_CPUID_REG(edx)
65
65
* Clear ECX since some CPUs (Cyrix MII) do not set or clear ECX
66
66
* resulting in stale register contents being returned.
67
67
*/
68
- static inline void cpuid (unsigned int op ,
69
- unsigned int * eax , unsigned int * ebx ,
70
- unsigned int * ecx , unsigned int * edx )
68
+ static inline void cpuid (u32 op ,
69
+ u32 * eax , u32 * ebx ,
70
+ u32 * ecx , u32 * edx )
71
71
{
72
72
* eax = op ;
73
73
* ecx = 0 ;
74
74
__cpuid (eax , ebx , ecx , edx );
75
75
}
76
76
77
77
/* Some CPUID calls want 'count' to be placed in ECX */
78
- static inline void cpuid_count (unsigned int op , int count ,
79
- unsigned int * eax , unsigned int * ebx ,
80
- unsigned int * ecx , unsigned int * edx )
78
+ static inline void cpuid_count (u32 op , int count ,
79
+ u32 * eax , u32 * ebx ,
80
+ u32 * ecx , u32 * edx )
81
81
{
82
82
* eax = op ;
83
83
* ecx = count ;
@@ -88,43 +88,43 @@ static inline void cpuid_count(unsigned int op, int count,
88
88
* CPUID functions returning a single datum:
89
89
*/
90
90
91
- static inline unsigned int cpuid_eax (unsigned int op )
91
+ static inline u32 cpuid_eax (u32 op )
92
92
{
93
- unsigned int eax , ebx , ecx , edx ;
93
+ u32 eax , ebx , ecx , edx ;
94
94
95
95
cpuid (op , & eax , & ebx , & ecx , & edx );
96
96
97
97
return eax ;
98
98
}
99
99
100
- static inline unsigned int cpuid_ebx (unsigned int op )
100
+ static inline u32 cpuid_ebx (u32 op )
101
101
{
102
- unsigned int eax , ebx , ecx , edx ;
102
+ u32 eax , ebx , ecx , edx ;
103
103
104
104
cpuid (op , & eax , & ebx , & ecx , & edx );
105
105
106
106
return ebx ;
107
107
}
108
108
109
- static inline unsigned int cpuid_ecx (unsigned int op )
109
+ static inline u32 cpuid_ecx (u32 op )
110
110
{
111
- unsigned int eax , ebx , ecx , edx ;
111
+ u32 eax , ebx , ecx , edx ;
112
112
113
113
cpuid (op , & eax , & ebx , & ecx , & edx );
114
114
115
115
return ecx ;
116
116
}
117
117
118
- static inline unsigned int cpuid_edx (unsigned int op )
118
+ static inline u32 cpuid_edx (u32 op )
119
119
{
120
- unsigned int eax , ebx , ecx , edx ;
120
+ u32 eax , ebx , ecx , edx ;
121
121
122
122
cpuid (op , & eax , & ebx , & ecx , & edx );
123
123
124
124
return edx ;
125
125
}
126
126
127
- static inline void __cpuid_read (unsigned int leaf , unsigned int subleaf , u32 * regs )
127
+ static inline void __cpuid_read (u32 leaf , u32 subleaf , u32 * regs )
128
128
{
129
129
regs [CPUID_EAX ] = leaf ;
130
130
regs [CPUID_ECX ] = subleaf ;
@@ -141,7 +141,7 @@ static inline void __cpuid_read(unsigned int leaf, unsigned int subleaf, u32 *re
141
141
__cpuid_read(leaf, 0, (u32 *)(regs)); \
142
142
}
143
143
144
- static inline void __cpuid_read_reg (unsigned int leaf , unsigned int subleaf ,
144
+ static inline void __cpuid_read_reg (u32 leaf , u32 subleaf ,
145
145
enum cpuid_regs_idx regidx , u32 * reg )
146
146
{
147
147
u32 regs [4 ];
0 commit comments