diff options
Diffstat (limited to 'arch/s390/include')
-rw-r--r-- | arch/s390/include/asm/barrier.h | 37 | ||||
-rw-r--r-- | arch/s390/include/asm/ccwgroup.h | 14 | ||||
-rw-r--r-- | arch/s390/include/asm/io.h | 7 | ||||
-rw-r--r-- | arch/s390/include/asm/processor.h | 3 | ||||
-rw-r--r-- | arch/s390/include/asm/qdio.h | 19 | ||||
-rw-r--r-- | arch/s390/include/asm/setup.h | 3 | ||||
-rw-r--r-- | arch/s390/include/asm/smp.h | 2 | ||||
-rw-r--r-- | arch/s390/include/asm/thread_info.h | 2 | ||||
-rw-r--r-- | arch/s390/include/asm/timex.h | 17 |
9 files changed, 41 insertions, 63 deletions
diff --git a/arch/s390/include/asm/barrier.h b/arch/s390/include/asm/barrier.h index 451273ad4d34..10a508802940 100644 --- a/arch/s390/include/asm/barrier.h +++ b/arch/s390/include/asm/barrier.h | |||
@@ -11,25 +11,28 @@ | |||
11 | * Force strict CPU ordering. | 11 | * Force strict CPU ordering. |
12 | * And yes, this is required on UP too when we're talking | 12 | * And yes, this is required on UP too when we're talking |
13 | * to devices. | 13 | * to devices. |
14 | * | ||
15 | * This is very similar to the ppc eieio/sync instruction in that is | ||
16 | * does a checkpoint syncronisation & makes sure that | ||
17 | * all memory ops have completed wrt other CPU's ( see 7-15 POP DJB ). | ||
18 | */ | 14 | */ |
19 | 15 | ||
20 | #define eieio() asm volatile("bcr 15,0" : : : "memory") | 16 | static inline void mb(void) |
21 | #define SYNC_OTHER_CORES(x) eieio() | 17 | { |
22 | #define mb() eieio() | 18 | #ifdef CONFIG_HAVE_MARCH_Z196_FEATURES |
23 | #define rmb() eieio() | 19 | /* Fast-BCR without checkpoint synchronization */ |
24 | #define wmb() eieio() | 20 | asm volatile("bcr 14,0" : : : "memory"); |
25 | #define read_barrier_depends() do { } while(0) | 21 | #else |
26 | #define smp_mb() mb() | 22 | asm volatile("bcr 15,0" : : : "memory"); |
27 | #define smp_rmb() rmb() | 23 | #endif |
28 | #define smp_wmb() wmb() | 24 | } |
29 | #define smp_read_barrier_depends() read_barrier_depends() | 25 | |
30 | #define smp_mb__before_clear_bit() smp_mb() | 26 | #define rmb() mb() |
31 | #define smp_mb__after_clear_bit() smp_mb() | 27 | #define wmb() mb() |
28 | #define read_barrier_depends() do { } while(0) | ||
29 | #define smp_mb() mb() | ||
30 | #define smp_rmb() rmb() | ||
31 | #define smp_wmb() wmb() | ||
32 | #define smp_read_barrier_depends() read_barrier_depends() | ||
33 | #define smp_mb__before_clear_bit() smp_mb() | ||
34 | #define smp_mb__after_clear_bit() smp_mb() | ||
32 | 35 | ||
33 | #define set_mb(var, value) do { var = value; mb(); } while (0) | 36 | #define set_mb(var, value) do { var = value; mb(); } while (0) |
34 | 37 | ||
35 | #endif /* __ASM_BARRIER_H */ | 38 | #endif /* __ASM_BARRIER_H */ |
diff --git a/arch/s390/include/asm/ccwgroup.h b/arch/s390/include/asm/ccwgroup.h index f2ea2c56a7e1..f2ef34f6d6e5 100644 --- a/arch/s390/include/asm/ccwgroup.h +++ b/arch/s390/include/asm/ccwgroup.h | |||
@@ -29,9 +29,7 @@ struct ccwgroup_device { | |||
29 | 29 | ||
30 | /** | 30 | /** |
31 | * struct ccwgroup_driver - driver for ccw group devices | 31 | * struct ccwgroup_driver - driver for ccw group devices |
32 | * @max_slaves: maximum number of slave devices | 32 | * @setup: function called during device creation to setup the device |
33 | * @driver_id: unique id | ||
34 | * @probe: function called on probe | ||
35 | * @remove: function called on remove | 33 | * @remove: function called on remove |
36 | * @set_online: function called when device is set online | 34 | * @set_online: function called when device is set online |
37 | * @set_offline: function called when device is set offline | 35 | * @set_offline: function called when device is set offline |
@@ -44,10 +42,7 @@ struct ccwgroup_device { | |||
44 | * @driver: embedded driver structure | 42 | * @driver: embedded driver structure |
45 | */ | 43 | */ |
46 | struct ccwgroup_driver { | 44 | struct ccwgroup_driver { |
47 | int max_slaves; | 45 | int (*setup) (struct ccwgroup_device *); |
48 | unsigned long driver_id; | ||
49 | |||
50 | int (*probe) (struct ccwgroup_device *); | ||
51 | void (*remove) (struct ccwgroup_device *); | 46 | void (*remove) (struct ccwgroup_device *); |
52 | int (*set_online) (struct ccwgroup_device *); | 47 | int (*set_online) (struct ccwgroup_device *); |
53 | int (*set_offline) (struct ccwgroup_device *); | 48 | int (*set_offline) (struct ccwgroup_device *); |
@@ -63,9 +58,8 @@ struct ccwgroup_driver { | |||
63 | 58 | ||
64 | extern int ccwgroup_driver_register (struct ccwgroup_driver *cdriver); | 59 | extern int ccwgroup_driver_register (struct ccwgroup_driver *cdriver); |
65 | extern void ccwgroup_driver_unregister (struct ccwgroup_driver *cdriver); | 60 | extern void ccwgroup_driver_unregister (struct ccwgroup_driver *cdriver); |
66 | int ccwgroup_create_from_string(struct device *root, unsigned int creator_id, | 61 | int ccwgroup_create_dev(struct device *root, struct ccwgroup_driver *gdrv, |
67 | struct ccw_driver *cdrv, int num_devices, | 62 | int num_devices, const char *buf); |
68 | const char *buf); | ||
69 | 63 | ||
70 | extern int ccwgroup_probe_ccwdev(struct ccw_device *cdev); | 64 | extern int ccwgroup_probe_ccwdev(struct ccw_device *cdev); |
71 | extern void ccwgroup_remove_ccwdev(struct ccw_device *cdev); | 65 | extern void ccwgroup_remove_ccwdev(struct ccw_device *cdev); |
diff --git a/arch/s390/include/asm/io.h b/arch/s390/include/asm/io.h index b7ff6afc3caa..27216d317991 100644 --- a/arch/s390/include/asm/io.h +++ b/arch/s390/include/asm/io.h | |||
@@ -38,11 +38,8 @@ static inline void * phys_to_virt(unsigned long address) | |||
38 | return (void *) address; | 38 | return (void *) address; |
39 | } | 39 | } |
40 | 40 | ||
41 | /* | 41 | void *xlate_dev_mem_ptr(unsigned long phys); |
42 | * Convert a physical pointer to a virtual kernel pointer for /dev/mem | 42 | void unxlate_dev_mem_ptr(unsigned long phys, void *addr); |
43 | * access | ||
44 | */ | ||
45 | #define xlate_dev_mem_ptr(p) __va(p) | ||
46 | 43 | ||
47 | /* | 44 | /* |
48 | * Convert a virtual cached pointer to an uncached pointer | 45 | * Convert a virtual cached pointer to an uncached pointer |
diff --git a/arch/s390/include/asm/processor.h b/arch/s390/include/asm/processor.h index d499b30ea487..6cbf31311673 100644 --- a/arch/s390/include/asm/processor.h +++ b/arch/s390/include/asm/processor.h | |||
@@ -141,9 +141,6 @@ struct seq_file; | |||
141 | extern void release_thread(struct task_struct *); | 141 | extern void release_thread(struct task_struct *); |
142 | extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags); | 142 | extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags); |
143 | 143 | ||
144 | /* Prepare to copy thread state - unlazy all lazy status */ | ||
145 | #define prepare_to_copy(tsk) do { } while (0) | ||
146 | |||
147 | /* | 144 | /* |
148 | * Return saved PC of a blocked thread. | 145 | * Return saved PC of a blocked thread. |
149 | */ | 146 | */ |
diff --git a/arch/s390/include/asm/qdio.h b/arch/s390/include/asm/qdio.h index d75c8e78f7e3..f039d86adf67 100644 --- a/arch/s390/include/asm/qdio.h +++ b/arch/s390/include/asm/qdio.h | |||
@@ -258,11 +258,6 @@ struct slsb { | |||
258 | u8 val[QDIO_MAX_BUFFERS_PER_Q]; | 258 | u8 val[QDIO_MAX_BUFFERS_PER_Q]; |
259 | } __attribute__ ((packed, aligned(256))); | 259 | } __attribute__ ((packed, aligned(256))); |
260 | 260 | ||
261 | #define CHSC_AC2_MULTI_BUFFER_AVAILABLE 0x0080 | ||
262 | #define CHSC_AC2_MULTI_BUFFER_ENABLED 0x0040 | ||
263 | #define CHSC_AC2_DATA_DIV_AVAILABLE 0x0010 | ||
264 | #define CHSC_AC2_DATA_DIV_ENABLED 0x0002 | ||
265 | |||
266 | /** | 261 | /** |
267 | * struct qdio_outbuf_state - SBAL related asynchronous operation information | 262 | * struct qdio_outbuf_state - SBAL related asynchronous operation information |
268 | * (for communication with upper layer programs) | 263 | * (for communication with upper layer programs) |
@@ -293,6 +288,8 @@ struct qdio_outbuf_state { | |||
293 | #define AC1_SC_QEBSM_AVAILABLE 0x02 /* available for subchannel */ | 288 | #define AC1_SC_QEBSM_AVAILABLE 0x02 /* available for subchannel */ |
294 | #define AC1_SC_QEBSM_ENABLED 0x01 /* enabled for subchannel */ | 289 | #define AC1_SC_QEBSM_ENABLED 0x01 /* enabled for subchannel */ |
295 | 290 | ||
291 | #define CHSC_AC2_MULTI_BUFFER_AVAILABLE 0x0080 | ||
292 | #define CHSC_AC2_MULTI_BUFFER_ENABLED 0x0040 | ||
296 | #define CHSC_AC2_DATA_DIV_AVAILABLE 0x0010 | 293 | #define CHSC_AC2_DATA_DIV_AVAILABLE 0x0010 |
297 | #define CHSC_AC2_DATA_DIV_ENABLED 0x0002 | 294 | #define CHSC_AC2_DATA_DIV_ENABLED 0x0002 |
298 | 295 | ||
@@ -328,11 +325,13 @@ typedef void qdio_handler_t(struct ccw_device *, unsigned int, int, | |||
328 | int, int, unsigned long); | 325 | int, int, unsigned long); |
329 | 326 | ||
330 | /* qdio errors reported to the upper-layer program */ | 327 | /* qdio errors reported to the upper-layer program */ |
331 | #define QDIO_ERROR_SIGA_TARGET 0x02 | 328 | #define QDIO_ERROR_ACTIVATE 0x0001 |
332 | #define QDIO_ERROR_SIGA_ACCESS_EXCEPTION 0x10 | 329 | #define QDIO_ERROR_GET_BUF_STATE 0x0002 |
333 | #define QDIO_ERROR_SIGA_BUSY 0x20 | 330 | #define QDIO_ERROR_SET_BUF_STATE 0x0004 |
334 | #define QDIO_ERROR_ACTIVATE_CHECK_CONDITION 0x40 | 331 | #define QDIO_ERROR_SLSB_STATE 0x0100 |
335 | #define QDIO_ERROR_SLSB_STATE 0x80 | 332 | |
333 | #define QDIO_ERROR_FATAL 0x00ff | ||
334 | #define QDIO_ERROR_TEMPORARY 0xff00 | ||
336 | 335 | ||
337 | /* for qdio_cleanup */ | 336 | /* for qdio_cleanup */ |
338 | #define QDIO_FLAG_CLEANUP_USING_CLEAR 0x01 | 337 | #define QDIO_FLAG_CLEANUP_USING_CLEAR 0x01 |
diff --git a/arch/s390/include/asm/setup.h b/arch/s390/include/asm/setup.h index b21e46e5d4b8..7244e1f64126 100644 --- a/arch/s390/include/asm/setup.h +++ b/arch/s390/include/asm/setup.h | |||
@@ -82,7 +82,6 @@ extern unsigned int user_mode; | |||
82 | #define MACHINE_FLAG_LPAR (1UL << 12) | 82 | #define MACHINE_FLAG_LPAR (1UL << 12) |
83 | #define MACHINE_FLAG_SPP (1UL << 13) | 83 | #define MACHINE_FLAG_SPP (1UL << 13) |
84 | #define MACHINE_FLAG_TOPOLOGY (1UL << 14) | 84 | #define MACHINE_FLAG_TOPOLOGY (1UL << 14) |
85 | #define MACHINE_FLAG_STCKF (1UL << 15) | ||
86 | 85 | ||
87 | #define MACHINE_IS_VM (S390_lowcore.machine_flags & MACHINE_FLAG_VM) | 86 | #define MACHINE_IS_VM (S390_lowcore.machine_flags & MACHINE_FLAG_VM) |
88 | #define MACHINE_IS_KVM (S390_lowcore.machine_flags & MACHINE_FLAG_KVM) | 87 | #define MACHINE_IS_KVM (S390_lowcore.machine_flags & MACHINE_FLAG_KVM) |
@@ -101,7 +100,6 @@ extern unsigned int user_mode; | |||
101 | #define MACHINE_HAS_PFMF (0) | 100 | #define MACHINE_HAS_PFMF (0) |
102 | #define MACHINE_HAS_SPP (0) | 101 | #define MACHINE_HAS_SPP (0) |
103 | #define MACHINE_HAS_TOPOLOGY (0) | 102 | #define MACHINE_HAS_TOPOLOGY (0) |
104 | #define MACHINE_HAS_STCKF (0) | ||
105 | #else /* __s390x__ */ | 103 | #else /* __s390x__ */ |
106 | #define MACHINE_HAS_IEEE (1) | 104 | #define MACHINE_HAS_IEEE (1) |
107 | #define MACHINE_HAS_CSP (1) | 105 | #define MACHINE_HAS_CSP (1) |
@@ -113,7 +111,6 @@ extern unsigned int user_mode; | |||
113 | #define MACHINE_HAS_PFMF (S390_lowcore.machine_flags & MACHINE_FLAG_PFMF) | 111 | #define MACHINE_HAS_PFMF (S390_lowcore.machine_flags & MACHINE_FLAG_PFMF) |
114 | #define MACHINE_HAS_SPP (S390_lowcore.machine_flags & MACHINE_FLAG_SPP) | 112 | #define MACHINE_HAS_SPP (S390_lowcore.machine_flags & MACHINE_FLAG_SPP) |
115 | #define MACHINE_HAS_TOPOLOGY (S390_lowcore.machine_flags & MACHINE_FLAG_TOPOLOGY) | 113 | #define MACHINE_HAS_TOPOLOGY (S390_lowcore.machine_flags & MACHINE_FLAG_TOPOLOGY) |
116 | #define MACHINE_HAS_STCKF (S390_lowcore.machine_flags & MACHINE_FLAG_STCKF) | ||
117 | #endif /* __s390x__ */ | 114 | #endif /* __s390x__ */ |
118 | 115 | ||
119 | #define ZFCPDUMP_HSA_SIZE (32UL<<20) | 116 | #define ZFCPDUMP_HSA_SIZE (32UL<<20) |
diff --git a/arch/s390/include/asm/smp.h b/arch/s390/include/asm/smp.h index c77c6de6f6c0..0b6f586c1383 100644 --- a/arch/s390/include/asm/smp.h +++ b/arch/s390/include/asm/smp.h | |||
@@ -16,7 +16,7 @@ | |||
16 | extern struct mutex smp_cpu_state_mutex; | 16 | extern struct mutex smp_cpu_state_mutex; |
17 | extern struct save_area *zfcpdump_save_areas[NR_CPUS + 1]; | 17 | extern struct save_area *zfcpdump_save_areas[NR_CPUS + 1]; |
18 | 18 | ||
19 | extern int __cpu_up(unsigned int cpu); | 19 | extern int __cpu_up(unsigned int cpu, struct task_struct *tidle); |
20 | 20 | ||
21 | extern void arch_send_call_function_single_ipi(int cpu); | 21 | extern void arch_send_call_function_single_ipi(int cpu); |
22 | extern void arch_send_call_function_ipi_mask(const struct cpumask *mask); | 22 | extern void arch_send_call_function_ipi_mask(const struct cpumask *mask); |
diff --git a/arch/s390/include/asm/thread_info.h b/arch/s390/include/asm/thread_info.h index a73038155e0d..003b04edcff6 100644 --- a/arch/s390/include/asm/thread_info.h +++ b/arch/s390/include/asm/thread_info.h | |||
@@ -95,7 +95,6 @@ static inline struct thread_info *current_thread_info(void) | |||
95 | #define TIF_SYSCALL_AUDIT 9 /* syscall auditing active */ | 95 | #define TIF_SYSCALL_AUDIT 9 /* syscall auditing active */ |
96 | #define TIF_SECCOMP 10 /* secure computing */ | 96 | #define TIF_SECCOMP 10 /* secure computing */ |
97 | #define TIF_SYSCALL_TRACEPOINT 11 /* syscall tracepoint instrumentation */ | 97 | #define TIF_SYSCALL_TRACEPOINT 11 /* syscall tracepoint instrumentation */ |
98 | #define TIF_SIE 12 /* guest execution active */ | ||
99 | #define TIF_POLLING_NRFLAG 16 /* true if poll_idle() is polling | 98 | #define TIF_POLLING_NRFLAG 16 /* true if poll_idle() is polling |
100 | TIF_NEED_RESCHED */ | 99 | TIF_NEED_RESCHED */ |
101 | #define TIF_31BIT 17 /* 32bit process */ | 100 | #define TIF_31BIT 17 /* 32bit process */ |
@@ -114,7 +113,6 @@ static inline struct thread_info *current_thread_info(void) | |||
114 | #define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT) | 113 | #define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT) |
115 | #define _TIF_SECCOMP (1<<TIF_SECCOMP) | 114 | #define _TIF_SECCOMP (1<<TIF_SECCOMP) |
116 | #define _TIF_SYSCALL_TRACEPOINT (1<<TIF_SYSCALL_TRACEPOINT) | 115 | #define _TIF_SYSCALL_TRACEPOINT (1<<TIF_SYSCALL_TRACEPOINT) |
117 | #define _TIF_SIE (1<<TIF_SIE) | ||
118 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) | 116 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) |
119 | #define _TIF_31BIT (1<<TIF_31BIT) | 117 | #define _TIF_31BIT (1<<TIF_31BIT) |
120 | #define _TIF_SINGLE_STEP (1<<TIF_SINGLE_STEP) | 118 | #define _TIF_SINGLE_STEP (1<<TIF_SINGLE_STEP) |
diff --git a/arch/s390/include/asm/timex.h b/arch/s390/include/asm/timex.h index c447a27a7fdb..239ece9e53c1 100644 --- a/arch/s390/include/asm/timex.h +++ b/arch/s390/include/asm/timex.h | |||
@@ -73,11 +73,15 @@ static inline void local_tick_enable(unsigned long long comp) | |||
73 | 73 | ||
74 | typedef unsigned long long cycles_t; | 74 | typedef unsigned long long cycles_t; |
75 | 75 | ||
76 | static inline unsigned long long get_clock (void) | 76 | static inline unsigned long long get_clock(void) |
77 | { | 77 | { |
78 | unsigned long long clk; | 78 | unsigned long long clk; |
79 | 79 | ||
80 | #ifdef CONFIG_HAVE_MARCH_Z9_109_FEATURES | ||
81 | asm volatile(".insn s,0xb27c0000,%0" : "=Q" (clk) : : "cc"); | ||
82 | #else | ||
80 | asm volatile("stck %0" : "=Q" (clk) : : "cc"); | 83 | asm volatile("stck %0" : "=Q" (clk) : : "cc"); |
84 | #endif | ||
81 | return clk; | 85 | return clk; |
82 | } | 86 | } |
83 | 87 | ||
@@ -86,17 +90,6 @@ static inline void get_clock_ext(char *clk) | |||
86 | asm volatile("stcke %0" : "=Q" (*clk) : : "cc"); | 90 | asm volatile("stcke %0" : "=Q" (*clk) : : "cc"); |
87 | } | 91 | } |
88 | 92 | ||
89 | static inline unsigned long long get_clock_fast(void) | ||
90 | { | ||
91 | unsigned long long clk; | ||
92 | |||
93 | if (MACHINE_HAS_STCKF) | ||
94 | asm volatile(".insn s,0xb27c0000,%0" : "=Q" (clk) : : "cc"); | ||
95 | else | ||
96 | clk = get_clock(); | ||
97 | return clk; | ||
98 | } | ||
99 | |||
100 | static inline unsigned long long get_clock_xt(void) | 93 | static inline unsigned long long get_clock_xt(void) |
101 | { | 94 | { |
102 | unsigned char clk[16]; | 95 | unsigned char clk[16]; |