Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[S390] Get rid of cpuid.h header file.

Merge cpuid.h header file into cpu.h.
While at it convert from typedef to struct declaration and also
convert cio code to use proper lowcore structure instead of casts.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>

authored by

Heiko Carstens and committed by
Martin Schwidefsky
e86a6ed6 4bb5e07b

+31 -36
+20
arch/s390/include/asm/cpu.h
··· 1 + /* 2 + * Copyright IBM Corp. 2000,2009 3 + * Author(s): Hartmut Penner <hp@de.ibm.com>, 4 + * Martin Schwidefsky <schwidefsky@de.ibm.com>, 5 + * Christian Ehrhardt <ehrhardt@de.ibm.com>, 6 + */ 7 + 1 8 #ifndef _ASM_S390_CPU_H 2 9 #define _ASM_S390_CPU_H 3 10 4 11 #define MAX_CPU_ADDRESS 255 5 12 13 + #ifndef __ASSEMBLY__ 14 + 15 + #include <linux/types.h> 16 + 17 + struct cpuid 18 + { 19 + unsigned int version : 8; 20 + unsigned int ident : 24; 21 + unsigned int machine : 16; 22 + unsigned int unused : 16; 23 + } __packed; 24 + 25 + #endif /* __ASSEMBLY__ */ 6 26 #endif /* _ASM_S390_CPU_H */
-25
arch/s390/include/asm/cpuid.h
··· 1 - /* 2 - * Copyright IBM Corp. 2000,2009 3 - * Author(s): Hartmut Penner <hp@de.ibm.com>, 4 - * Martin Schwidefsky <schwidefsky@de.ibm.com> 5 - * Christian Ehrhardt <ehrhardt@de.ibm.com> 6 - */ 7 - 8 - #ifndef _ASM_S390_CPUID_H_ 9 - #define _ASM_S390_CPUID_H_ 10 - 11 - /* 12 - * CPU type and hardware bug flags. Kept separately for each CPU. 13 - * Members of this structure are referenced in head.S, so think twice 14 - * before touching them. [mj] 15 - */ 16 - 17 - typedef struct 18 - { 19 - unsigned int version : 8; 20 - unsigned int ident : 24; 21 - unsigned int machine : 16; 22 - unsigned int unused : 16; 23 - } __attribute__ ((packed)) cpuid_t; 24 - 25 - #endif /* _ASM_S390_CPUID_H_ */
+3 -3
arch/s390/include/asm/kvm_host.h
··· 17 17 #include <linux/interrupt.h> 18 18 #include <linux/kvm_host.h> 19 19 #include <asm/debug.h> 20 - #include <asm/cpuid.h> 20 + #include <asm/cpu.h> 21 21 22 22 #define KVM_MAX_VCPUS 64 23 23 #define KVM_MEMORY_SLOTS 32 ··· 217 217 struct hrtimer ckc_timer; 218 218 struct tasklet_struct tasklet; 219 219 union { 220 - cpuid_t cpu_id; 221 - u64 stidp_data; 220 + struct cpuid cpu_id; 221 + u64 stidp_data; 222 222 }; 223 223 }; 224 224
+3 -3
arch/s390/include/asm/lowcore.h
··· 132 132 133 133 #ifndef __ASSEMBLY__ 134 134 135 - #include <asm/cpuid.h> 135 + #include <asm/cpu.h> 136 136 #include <asm/ptrace.h> 137 137 #include <linux/types.h> 138 138 ··· 275 275 __u32 user_exec_asce; /* 0x02ac */ 276 276 277 277 /* SMP info area */ 278 - cpuid_t cpu_id; /* 0x02b0 */ 278 + struct cpuid cpu_id; /* 0x02b0 */ 279 279 __u32 cpu_nr; /* 0x02b8 */ 280 280 __u32 softirq_pending; /* 0x02bc */ 281 281 __u32 percpu_offset; /* 0x02c0 */ ··· 380 380 __u64 user_exec_asce; /* 0x0318 */ 381 381 382 382 /* SMP info area */ 383 - cpuid_t cpu_id; /* 0x0320 */ 383 + struct cpuid cpu_id; /* 0x0320 */ 384 384 __u32 cpu_nr; /* 0x0328 */ 385 385 __u32 softirq_pending; /* 0x032c */ 386 386 __u64 percpu_offset; /* 0x0330 */
+2 -2
arch/s390/include/asm/processor.h
··· 14 14 #define __ASM_S390_PROCESSOR_H 15 15 16 16 #include <linux/linkage.h> 17 - #include <asm/cpuid.h> 17 + #include <asm/cpu.h> 18 18 #include <asm/page.h> 19 19 #include <asm/ptrace.h> 20 20 #include <asm/setup.h> ··· 26 26 */ 27 27 #define current_text_addr() ({ void *pc; asm("basr %0,0" : "=a" (pc)); pc; }) 28 28 29 - static inline void get_cpu_id(cpuid_t *ptr) 29 + static inline void get_cpu_id(struct cpuid *ptr) 30 30 { 31 31 asm volatile("stidp 0(%1)" : "=m" (*ptr) : "a" (ptr)); 32 32 }
+1 -1
drivers/s390/char/zcore.c
··· 275 275 u32 num_pages; 276 276 u32 pad1; 277 277 u64 tod; 278 - cpuid_t cpu_id; 278 + struct cpuid cpu_id; 279 279 u32 arch_id; 280 280 u32 volnr; 281 281 u32 build_arch;
+2 -2
drivers/s390/cio/css.c
··· 657 657 css->global_pgid.pgid_high.cpu_addr = 0; 658 658 #endif 659 659 } 660 - css->global_pgid.cpu_id = ((cpuid_t *) __LC_CPUID)->ident; 661 - css->global_pgid.cpu_model = ((cpuid_t *) __LC_CPUID)->machine; 660 + css->global_pgid.cpu_id = S390_lowcore.cpu_id.ident; 661 + css->global_pgid.cpu_model = S390_lowcore.cpu_id.machine; 662 662 css->global_pgid.tod_high = tod_high; 663 663 664 664 }