s390 patches for 2.6.40
Subsystems (5)
Hi Linus,
please pull from 'for-linus' branch of
git://git390.marist.edu/pub/scm/linux-2.6.git for-linus
to receive the following updates:
Heiko Carstens (9):
[S390] pfault: always enable service signal interrupt [S390] irq: fix service signal external interrupt handling [S390] irq: merge irq.c and s390_ext.c
[S390] uaccess: turn __access_ok() into a define
[S390] topology,sched: fix cpu_coregroup_mask/cpu_book_mask definitions [S390] delay: implement ndelay
[S390] mm: handle kernel caused page fault oom situations [S390] mm: add page fault retry handling
[S390] mm: add ZONE_DMA to 31-bit config again
Martin Schwidefsky (1):
[S390] hwsampler: allow cpu hotplug
arch/s390/Kconfig | 2 +- arch/s390/appldata/appldata_mem.c | 2 - arch/s390/include/asm/delay.h | 8 ++- arch/s390/include/asm/irq.h | 8 ++ arch/s390/include/asm/s390_ext.h | 17 ----- arch/s390/include/asm/topology.h | 4 +- arch/s390/include/asm/uaccess.h | 11 ++-- arch/s390/kernel/Makefile | 8 +- arch/s390/kernel/dis.c | 2 +- arch/s390/kernel/irq.c | 137 ++++++++++++++++++++++++++++++++++-- arch/s390/kernel/s390_ext.c | 108 ----------------------------- arch/s390/kernel/smp.c | 1 - arch/s390/kernel/time.c | 1 - arch/s390/kernel/topology.c | 1 - arch/s390/kernel/traps.c | 1 - arch/s390/kernel/vtime.c | 2 +- arch/s390/lib/delay.c | 15 ++++ arch/s390/mm/fault.c | 62 +++++++++++------ arch/s390/mm/init.c | 2 - arch/s390/oprofile/hwsampler.c | 4 +- drivers/s390/block/dasd_diag.c | 6 +- drivers/s390/char/sclp.c | 7 +- drivers/s390/kvm/kvm_virtio.c | 3 +- net/iucv/iucv.c | 2 +- 24 files changed, 221 insertions(+), 193 deletions(-) delete mode 100644 arch/s390/include/asm/s390_ext.h delete mode 100644 arch/s390/kernel/s390_ext.c
arch/s390/Kconfig +1 -1
@@ -2,7 +2,7 @@ config MMU def_bool y config ZONE_DMA - def_bool y if 64BIT + def_bool y config LOCKDEP_SUPPORT def_bool y
arch/s390/appldata/appldata_mem.c +0 -2
@@ -92,9 +92,7 @@ static void appldata_get_mem_data(void *data) mem_data->pswpin = ev[PSWPIN ]; mem_data->pswpout = ev[PSWPOUT ]; mem_data->pgalloc = ev[PGALLOC_NORMAL ]; -#ifdef CONFIG_ZONE_DMA mem_data->pgalloc += ev[PGALLOC_DMA ]; -#endif mem_data->pgfault = ev[PGFAULT ]; mem_data->pgmajfault = ev[PGMAJFAULT ];
arch/s390/include/asm/delay.h +5 -3
@@ -14,10 +14,12 @@#ifndef _S390_DELAY_H#define _S390_DELAY_H -extern void __udelay (unsigned long long usecs); -extern void udelay_simple (unsigned long long usecs); -extern void __delay (unsigned long loops); +void __ndelay (unsigned long long nsecs); +void __udelay (unsigned long long usecs); +void udelay_simple (unsigned long long usecs); +void __delay (unsigned long loops); +#define ndelay (n) __ndelay((unsigned long long) (n))#define udelay (n) __udelay((unsigned long long) (n))#define mdelay (n) __udelay((unsigned long long) (n) * 1000)
arch/s390/include/asm/irq.h +8 -0
@@ -2,6 +2,7 @@#define _ASM_IRQ_H#include <linux/hardirq.h> +#include <linux/types.h> enum interruption_class {EXTERNAL_INTERRUPT ,
@@ -31,4 +32,11 @@ enum interruption_class { NR_IRQS, }; +typedef void (*ext_int_handler_t )(unsigned int ,unsigned int ,unsigned long ); + +int register_external_interrupt (u16 code,ext_int_handler_t handler); +int unregister_external_interrupt (u16 code,ext_int_handler_t handler); +void service_subclass_irq_register (void ); +void service_subclass_irq_unregister (void ); +#endif /* _ASM_IRQ_H */
arch/s390/include/asm/s390_ext.h deleted +0 -17
@@ -1,17 +0,0 @@ -/* -* Copyright IBM Corp. 1999,2010 -* Author(s): Holger Smolinski <[email protected]>, -* Martin Schwidefsky <[email protected]>, -*/ - -#ifndef _S390_EXTINT_H -#define _S390_EXTINT_H - -#include <linux/types.h> - -typedef void (*ext_int_handler_t )(unsigned int ,unsigned int ,unsigned long ); - -int register_external_interrupt (__u16 code,ext_int_handler_t handler); -int unregister_external_interrupt (__u16 code,ext_int_handler_t handler); - -#endif /* _S390_EXTINT_H */
arch/s390/include/asm/topology.h +2 -2
@@ -7,7 +7,7 @@extern unsigned char cpu_core_id[NR_CPUS ];extern cpumask_t cpu_core_map[NR_CPUS ]; -static inline const struct cpumask *cpu_coregroup_mask (unsigned int cpu) +static inline const struct cpumask *cpu_coregroup_mask (int cpu) {return &cpu_core_map[cpu]; }
@@ -21,7 +21,7 @@ static inline const struct cpumask *cpu_coregroup_mask(unsigned int cpu)extern unsigned char cpu_book_id[NR_CPUS ];extern cpumask_t cpu_book_map[NR_CPUS ]; -static inline const struct cpumask *cpu_book_mask (unsigned int cpu) +static inline const struct cpumask *cpu_book_mask (int cpu) {return &cpu_book_map[cpu]; }
arch/s390/include/asm/uaccess.h +6 -5
@@ -49,12 +49,13 @@#define segment_eq (a,b) ((a).ar4 == (b).ar4) +#define __access_ok (addr, size) \ +({ \ + __chk_user_ptr(addr); \ + 1; \ +}) -static inline int __access_ok (const void __user *addr,unsigned long size) -{ -return 1 ; -} -#define access_ok (type,addr,size) __access_ok(addr,size) +#define access_ok (type, addr, size) __access_ok(addr, size)/* * The exception table consists of pairs of addresses: the first is the
arch/s390/kernel/Makefile +4 -4
@@ -20,10 +20,10 @@ CFLAGS_ptrace.o += -DUTS_MACHINE='"$(UTS_MACHINE)"' CFLAGS_sysinfo.o += -Iinclude/math-emu -Iarch/s390/math-emu -w -obj-y := bitmap.o traps.o time.o process.o base.o early.o setup.o \ - processor.o sys_s390.o ptrace.o signal.o cpcmd.o ebcdic.o \ - s390_ext.o debug.o irq.o ipl.o dis.o diag.o mem_detect.o \ - vdso.o vtime.o sysinfo.o nmi.o sclp.o jump_label.o +obj-y := bitmap.o traps.o time.o process.o base.o early.o setup.o vtime.o \ + processor.o sys_s390.o ptrace.o signal.o cpcmd.o ebcdic.o nmi.o \ + debug.o irq.o ipl.o dis.o diag.o mem_detect.o sclp.o vdso.o \ + sysinfo.o jump_label.o obj-y += $(if $(CONFIG_64BIT),entry64.o,entry.o) obj-y += $(if $(CONFIG_64BIT),reipl64.o,reipl.o)
arch/s390/kernel/dis.c +1 -1
@@ -30,9 +30,9 @@#include <asm/atomic.h> #include <asm/mathemu.h> #include <asm/cpcmd.h> -#include <asm/s390_ext.h> #include <asm/lowcore.h> #include <asm/debug.h> +#include <asm/irq.h> #ifndef CONFIG_64BIT #define ONELONG "%08lx: "
arch/s390/kernel/irq.c +129 -8
159 lines not on this page · raw message
arch/s390/kernel/s390_ext.c deleted +0 -108
108 lines not on this page · raw message
arch/s390/kernel/smp.c +0 -1
@@ -44,7 +44,6 @@#include <asm/sigp.h> #include <asm/pgalloc.h> #include <asm/irq.h> -#include <asm/s390_ext.h> #include <asm/cpcmd.h> #include <asm/tlbflush.h> #include <asm/timer.h>
arch/s390/kernel/time.c +0 -1
@@ -41,7 +41,6 @@#include <linux/kprobes.h> #include <asm/uaccess.h> #include <asm/delay.h> -#include <asm/s390_ext.h> #include <asm/div64.h> #include <asm/vdso.h> #include <asm/irq.h>
arch/s390/kernel/topology.c +0 -1
@@ -17,7 +17,6 @@#include <linux/smp.h> #include <linux/cpuset.h> #include <asm/delay.h> -#include <asm/s390_ext.h> #define PTF_HORIZONTAL (0UL)#define PTF_VERTICAL (1UL)
arch/s390/kernel/traps.c +0 -1
@@ -39,7 +39,6 @@#include <asm/atomic.h> #include <asm/mathemu.h> #include <asm/cpcmd.h> -#include <asm/s390_ext.h> #include <asm/lowcore.h> #include <asm/debug.h> #include "entry.h"
arch/s390/kernel/vtime.c +1 -1
@@ -22,10 +22,10 @@#include <linux/cpu.h> #include <linux/kprobes.h> -#include <asm/s390_ext.h> #include <asm/timer.h> #include <asm/irq_regs.h> #include <asm/cputime.h> +#include <asm/irq.h> static DEFINE_PER_CPU(struct vtimer_queue, virt_cpu_timer);
arch/s390/lib/delay.c +15 -0
@@ -12,6 +12,7 @@#include <linux/module.h> #include <linux/irqflags.h> #include <linux/interrupt.h> +#include <asm/div64.h> void __delay (unsigned long loops) {
@@ -116,3 +117,17 @@ void udelay_simple(unsigned long long usecs)while (get_clock () < end)cpu_relax (); } + +void __ndelay (unsigned long long nsecs) +{ +u64 end; + + nsecs <<=9 ; +do_div (nsecs,125 ); + end =get_clock () + nsecs; +if (nsecs & ~0xfffUL ) +__udelay (nsecs >>12 ); +while (get_clock () < end) +barrier (); +} +EXPORT_SYMBOL (__ndelay);
arch/s390/mm/fault.c +39 -23
119 lines not on this page · raw message
arch/s390/mm/init.c +0 -2
@@ -119,9 +119,7 @@ void __init paging_init(void)sparse_memory_present_with_active_regions (MAX_NUMNODES );sparse_init ();memset (max_zone_pfns,0 ,sizeof (max_zone_pfns)); -#ifdef CONFIG_ZONE_DMA max_zone_pfns[ZONE_DMA ] =PFN_DOWN (MAX_DMA_ADDRESS ); -#endif max_zone_pfns[ZONE_NORMAL ] = max_low_pfn;free_area_init_nodes (max_zone_pfns);fault_init ();
arch/s390/oprofile/hwsampler.c +2 -2
@@ -19,7 +19,7 @@#include <linux/oprofile.h> #include <asm/lowcore.h> -#include <asm/s390_ext.h> +#include <asm/irq.h> #include "hwsampler.h"
@@ -580,7 +580,7 @@ static int hws_cpu_callback(struct notifier_block *nfb, {/* We do not have sampler space available for all possible CPUs. All CPUs should be online when hw sampling is activated. */ -return NOTIFY_BAD ; +return (hws_state <=HWS_DEALLOCATED ) ?NOTIFY_OK :NOTIFY_BAD ; }static struct notifier_block hws_cpu_notifier = {
drivers/s390/block/dasd_diag.c +3 -3
@@ -24,7 +24,7 @@#include <asm/debug.h> #include <asm/ebcdic.h> #include <asm/io.h> -#include <asm/s390_ext.h> +#include <asm/irq.h> #include <asm/vtoc.h> #include <asm/diag.h>
@@ -642,7 +642,7 @@ dasd_diag_init(void) }ASCEBC (dasd_diag_discipline.ebcname,4 ); -ctl_set_bit (0 ,9 ); +service_subclass_irq_register ();register_external_interrupt (0x2603 , dasd_ext_handler); dasd_diag_discipline_pointer = &dasd_diag_discipline;return 0 ;
@@ -652,7 +652,7 @@ static void __exitdasd_diag_cleanup (void) {unregister_external_interrupt (0x2603 , dasd_ext_handler); -ctl_clear_bit (0 ,9 ); +service_subclass_irq_unregister (); dasd_diag_discipline_pointer =NULL ; }
drivers/s390/char/sclp.c +3 -4
@@ -19,7 +19,6 @@#include <linux/suspend.h> #include <linux/completion.h> #include <linux/platform_device.h> -#include <asm/s390_ext.h> #include <asm/types.h> #include <asm/irq.h>
@@ -885,12 +884,12 @@ sclp_check_interface(void)spin_unlock_irqrestore (&sclp_lock, flags);/* Enable service-signal interruption - needs to happen * with IRQs enabled. */ -ctl_set_bit (0 ,9 ); +service_subclass_irq_register ();/* Wait for signal from interrupt or timeout */ sclp_sync_wait ();/* Disable service-signal interruption - needs to happen * with IRQs enabled. */ -ctl_clear_bit (0 ,9 ); +service_subclass_irq_unregister ();spin_lock_irqsave (&sclp_lock, flags);del_timer (&sclp_request_timer); if (sclp_init_req.status == SCLP_REQ_DONE &&
@@ -1070,7 +1069,7 @@ sclp_init(void)spin_unlock_irqrestore (&sclp_lock, flags);/* Enable service-signal external interruption - needs to happen with * IRQs enabled. */ -ctl_set_bit (0 ,9 ); +service_subclass_irq_register ();sclp_init_mask (1 );return 0 ;
drivers/s390/kvm/kvm_virtio.c +1 -2
@@ -25,7 +25,6 @@#include <asm/kvm_para.h> #include <asm/kvm_virtio.h> #include <asm/setup.h> -#include <asm/s390_ext.h> #include <asm/irq.h> #define VIRTIO_SUBCODE_64 0x0D00
@@ -441,7 +440,7 @@ static int __init kvm_devices_init(void)INIT_WORK (&hotplug_work, hotplug_devices); -ctl_set_bit (0 ,9 ); +service_subclass_irq_register ();register_external_interrupt (0x2603 , kvm_extint_handler);scan_devices ();
net/iucv/iucv.c +1 -1
@@ -54,7 +54,7 @@#include <asm/atomic.h> #include <asm/ebcdic.h> #include <asm/io.h> -#include <asm/s390_ext.h> +#include <asm/irq.h> #include <asm/smp.h> /*