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

Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc

* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (28 commits)
powerpc: Fix oops when loading modules
powerpc: Wire up preadv and pwritev
powerpc/ftrace: Fix printf format warning
powerpc/ftrace: Fix #if that should be #ifdef
powerpc: Fix ptrace compat wrapper for FPU register access
powerpc: Print information about mapping hw irqs to virtual irqs
powerpc: Correct dependency of KEXEC
powerpc: Disable VSX or current process in giveup_fpu/altivec
powerpc/pseries: Enable relay in pseries_defconfig
powerpc/pseries: Fix ibm,client-architecture comment
powerpc/pseries: Scan for all events in rtasd
powerpc/pseries: Add dispatch dispersion statistics
powerpc: Clean up some prom printouts
powerpc: Print progress of ibm,client-architecture method
powerpc: Remove duplicated #include's
powerpc/pmac: Fix internal modem IRQ on Wallstreet PowerBook
powerpc/wdrtas: Update wdrtas_get_interval to use rtas_data_buf
fsl-diu-fb: Pass the proper device for dma mapping routines
powerpc/pq2fads: Update device tree for use with device-tree-aware u-boot.
cpm_uart: Disable CPM udbg when re-initing CPM uart, even if not the console.
...

+235 -123
+2 -1
arch/powerpc/Kconfig
··· 316 316 317 317 config KEXEC 318 318 bool "kexec system call (EXPERIMENTAL)" 319 - depends on BOOK3S && EXPERIMENTAL 319 + depends on PPC_BOOK3S && EXPERIMENTAL 320 320 help 321 321 kexec is a system call that implements the ability to shutdown your 322 322 current kernel, and to start another kernel. It is like a reboot ··· 775 775 Say N here unless you know what you are doing. 776 776 777 777 config LOWMEM_CAM_NUM 778 + depends on FSL_BOOKE 778 779 int "Number of CAMs to use to map low memory" if LOWMEM_CAM_NUM_BOOL 779 780 default 3 780 781
+2 -2
arch/powerpc/boot/dts/ksi8560.dts
··· 57 57 bus-frequency = <0>; /* Fixed by bootwrapper */ 58 58 59 59 memory-controller@2000 { 60 - compatible = "fsl,8540-memory-controller"; 60 + compatible = "fsl,mpc8540-memory-controller"; 61 61 reg = <0x2000 0x1000>; 62 62 interrupt-parent = <&mpic>; 63 63 interrupts = <0x12 0x2>; 64 64 }; 65 65 66 66 L2: l2-cache-controller@20000 { 67 - compatible = "fsl,8540-l2-cache-controller"; 67 + compatible = "fsl,mpc8540-l2-cache-controller"; 68 68 reg = <0x20000 0x1000>; 69 69 cache-line-size = <0x20>; /* 32 bytes */ 70 70 cache-size = <0x40000>; /* L2, 256K */
+14 -6
arch/powerpc/boot/dts/pq2fads.dts
··· 17 17 #address-cells = <1>; 18 18 #size-cells = <1>; 19 19 20 + aliases { 21 + ethernet0 = &enet0; 22 + ethernet1 = &enet1; 23 + serial0 = &serial0; 24 + serial1 = &serial1; 25 + pci0 = &pci0; 26 + }; 27 + 20 28 cpus { 21 29 #address-cells = <1>; 22 30 #size-cells = <0>; ··· 53 45 #size-cells = <1>; 54 46 reg = <0xf0010100 0x60>; 55 47 56 - ranges = <0x0 0x0 0xfe000000 0x800000 48 + ranges = <0x0 0x0 0xff800000 0x800000 57 49 0x1 0x0 0xf4500000 0x8000 58 50 0x8 0x0 0xf8200000 0x8000>; 59 51 ··· 79 71 }; 80 72 }; 81 73 82 - pci@f0010800 { 74 + pci0: pci@f0010800 { 83 75 device_type = "pci"; 84 76 reg = <0xf0010800 0x10c 0xf00101ac 0x8 0xf00101c4 0x8>; 85 77 compatible = "fsl,mpc8280-pci", "fsl,pq2-pci"; ··· 150 142 reg = <0x119f0 0x10 0x115f0 0x10>; 151 143 }; 152 144 153 - serial@11a00 { 145 + serial0: serial@11a00 { 154 146 device_type = "serial"; 155 147 compatible = "fsl,mpc8280-scc-uart", 156 148 "fsl,cpm2-scc-uart"; ··· 161 153 fsl,cpm-command = <0x800000>; 162 154 }; 163 155 164 - serial@11a20 { 156 + serial1: serial@11a20 { 165 157 device_type = "serial"; 166 158 compatible = "fsl,mpc8280-scc-uart", 167 159 "fsl,cpm2-scc-uart"; ··· 172 164 fsl,cpm-command = <0x4a00000>; 173 165 }; 174 166 175 - ethernet@11320 { 167 + enet0: ethernet@11320 { 176 168 device_type = "network"; 177 169 compatible = "fsl,mpc8280-fcc-enet", 178 170 "fsl,cpm2-fcc-enet"; ··· 184 176 fsl,cpm-command = <0x16200300>; 185 177 }; 186 178 187 - ethernet@11340 { 179 + enet1: ethernet@11340 { 188 180 device_type = "network"; 189 181 compatible = "fsl,mpc8280-fcc-enet", 190 182 "fsl,cpm2-fcc-enet";
+2 -2
arch/powerpc/boot/dts/sbc8548.dts
··· 156 156 compatible = "simple-bus"; 157 157 158 158 memory-controller@2000 { 159 - compatible = "fsl,8548-memory-controller"; 159 + compatible = "fsl,mpc8548-memory-controller"; 160 160 reg = <0x2000 0x1000>; 161 161 interrupt-parent = <&mpic>; 162 162 interrupts = <0x12 0x2>; 163 163 }; 164 164 165 165 L2: l2-cache-controller@20000 { 166 - compatible = "fsl,8548-l2-cache-controller"; 166 + compatible = "fsl,mpc8548-l2-cache-controller"; 167 167 reg = <0x20000 0x1000>; 168 168 cache-line-size = <0x20>; // 32 bytes 169 169 cache-size = <0x80000>; // L2, 512K
+2 -2
arch/powerpc/boot/dts/sbc8560.dts
··· 61 61 clock-frequency = <0>; 62 62 63 63 memory-controller@2000 { 64 - compatible = "fsl,8560-memory-controller"; 64 + compatible = "fsl,mpc8560-memory-controller"; 65 65 reg = <0x2000 0x1000>; 66 66 interrupt-parent = <&mpic>; 67 67 interrupts = <0x12 0x2>; 68 68 }; 69 69 70 70 L2: l2-cache-controller@20000 { 71 - compatible = "fsl,8560-l2-cache-controller"; 71 + compatible = "fsl,mpc8560-l2-cache-controller"; 72 72 reg = <0x20000 0x1000>; 73 73 cache-line-size = <0x20>; // 32 bytes 74 74 cache-size = <0x40000>; // L2, 256K
+1
arch/powerpc/boot/dts/socrates.dts
··· 52 52 soc8544@e0000000 { 53 53 #address-cells = <1>; 54 54 #size-cells = <1>; 55 + device_type = "soc"; 55 56 56 57 ranges = <0x00000000 0xe0000000 0x00100000>; 57 58 reg = <0xe0000000 0x00001000>; // CCSRBAR 1M
+2 -2
arch/powerpc/boot/dts/stx_gp3_8560.dts
··· 57 57 compatible = "fsl,mpc8560-immr", "simple-bus"; 58 58 59 59 memory-controller@2000 { 60 - compatible = "fsl,8540-memory-controller"; 60 + compatible = "fsl,mpc8540-memory-controller"; 61 61 reg = <0x2000 0x1000>; 62 62 interrupt-parent = <&mpic>; 63 63 interrupts = <18 2>; 64 64 }; 65 65 66 66 L2: l2-cache-controller@20000 { 67 - compatible = "fsl,8540-l2-cache-controller"; 67 + compatible = "fsl,mpc8540-l2-cache-controller"; 68 68 reg = <0x20000 0x1000>; 69 69 cache-line-size = <32>; 70 70 cache-size = <0x40000>; // L2, 256K
+2 -2
arch/powerpc/boot/dts/tqm8540.dts
··· 59 59 compatible = "fsl,mpc8540-immr", "simple-bus"; 60 60 61 61 memory-controller@2000 { 62 - compatible = "fsl,8540-memory-controller"; 62 + compatible = "fsl,mpc8540-memory-controller"; 63 63 reg = <0x2000 0x1000>; 64 64 interrupt-parent = <&mpic>; 65 65 interrupts = <18 2>; 66 66 }; 67 67 68 68 L2: l2-cache-controller@20000 { 69 - compatible = "fsl,8540-l2-cache-controller"; 69 + compatible = "fsl,mpc8540-l2-cache-controller"; 70 70 reg = <0x20000 0x1000>; 71 71 cache-line-size = <32>; 72 72 cache-size = <0x40000>; // L2, 256K
+2 -2
arch/powerpc/boot/dts/tqm8541.dts
··· 58 58 compatible = "fsl,mpc8541-immr", "simple-bus"; 59 59 60 60 memory-controller@2000 { 61 - compatible = "fsl,8540-memory-controller"; 61 + compatible = "fsl,mpc8540-memory-controller"; 62 62 reg = <0x2000 0x1000>; 63 63 interrupt-parent = <&mpic>; 64 64 interrupts = <18 2>; 65 65 }; 66 66 67 67 L2: l2-cache-controller@20000 { 68 - compatible = "fsl,8540-l2-cache-controller"; 68 + compatible = "fsl,mpc8540-l2-cache-controller"; 69 69 reg = <0x20000 0x1000>; 70 70 cache-line-size = <32>; 71 71 cache-size = <0x40000>; // L2, 256K
+2 -2
arch/powerpc/boot/dts/tqm8555.dts
··· 58 58 compatible = "fsl,mpc8555-immr", "simple-bus"; 59 59 60 60 memory-controller@2000 { 61 - compatible = "fsl,8540-memory-controller"; 61 + compatible = "fsl,mpc8540-memory-controller"; 62 62 reg = <0x2000 0x1000>; 63 63 interrupt-parent = <&mpic>; 64 64 interrupts = <18 2>; 65 65 }; 66 66 67 67 L2: l2-cache-controller@20000 { 68 - compatible = "fsl,8540-l2-cache-controller"; 68 + compatible = "fsl,mpc8540-l2-cache-controller"; 69 69 reg = <0x20000 0x1000>; 70 70 cache-line-size = <32>; 71 71 cache-size = <0x40000>; // L2, 256K
+2 -2
arch/powerpc/boot/dts/tqm8560.dts
··· 60 60 compatible = "fsl,mpc8560-immr", "simple-bus"; 61 61 62 62 memory-controller@2000 { 63 - compatible = "fsl,8540-memory-controller"; 63 + compatible = "fsl,mpc8540-memory-controller"; 64 64 reg = <0x2000 0x1000>; 65 65 interrupt-parent = <&mpic>; 66 66 interrupts = <18 2>; 67 67 }; 68 68 69 69 L2: l2-cache-controller@20000 { 70 - compatible = "fsl,8540-l2-cache-controller"; 70 + compatible = "fsl,mpc8540-l2-cache-controller"; 71 71 reg = <0x20000 0x1000>; 72 72 cache-line-size = <32>; 73 73 cache-size = <0x40000>; // L2, 256K
+1 -1
arch/powerpc/configs/pseries_defconfig
··· 95 95 CONFIG_SYSFS_DEPRECATED=y 96 96 CONFIG_SYSFS_DEPRECATED_V2=y 97 97 CONFIG_PROC_PID_CPUSET=y 98 - # CONFIG_RELAY is not set 98 + CONFIG_RELAY=y 99 99 CONFIG_NAMESPACES=y 100 100 # CONFIG_UTS_NS is not set 101 101 # CONFIG_IPC_NS is not set
+1 -1
arch/powerpc/include/asm/lppaca.h
··· 125 125 // NOTE: This value will ALWAYS be zero for dedicated processors and 126 126 // will NEVER be zero for shared processors (ie, initialized to a 1). 127 127 volatile u32 yield_count; // PLIC increments each dispatchx00-x03 128 - u32 reserved6; 128 + volatile u32 dispersion_count; // dispatch changed phys cpu x04-x07 129 129 volatile u64 cmo_faults; // CMO page fault count x08-x0F 130 130 volatile u64 cmo_fault_time; // CMO page fault time x10-x17 131 131 u8 reserved7[104]; // Reserved x18-x7F
+12
arch/powerpc/include/asm/mpic.h
··· 22 22 #define MPIC_GREG_FEATURE_1 0x00010 23 23 #define MPIC_GREG_GLOBAL_CONF_0 0x00020 24 24 #define MPIC_GREG_GCONF_RESET 0x80000000 25 + /* On the FSL mpic implementations the Mode field is expand to be 26 + * 2 bits wide: 27 + * 0b00 = pass through (interrupts routed to IRQ0) 28 + * 0b01 = Mixed mode 29 + * 0b10 = reserved 30 + * 0b11 = External proxy / coreint 31 + */ 32 + #define MPIC_GREG_GCONF_COREINT 0x60000000 25 33 #define MPIC_GREG_GCONF_8259_PTHROU_DIS 0x20000000 26 34 #define MPIC_GREG_GCONF_NO_BIAS 0x10000000 27 35 #define MPIC_GREG_GCONF_BASE_MASK 0x000fffff ··· 365 357 #define MPIC_BROKEN_FRR_NIRQS 0x00000800 366 358 /* Destination only supports a single CPU at a time */ 367 359 #define MPIC_SINGLE_DEST_CPU 0x00001000 360 + /* Enable CoreInt delivery of interrupts */ 361 + #define MPIC_ENABLE_COREINT 0x00002000 368 362 369 363 /* MPIC HW modification ID */ 370 364 #define MPIC_REGSET_MASK 0xf0000000 ··· 480 470 extern unsigned int mpic_get_one_irq(struct mpic *mpic); 481 471 /* This one gets from the primary mpic */ 482 472 extern unsigned int mpic_get_irq(void); 473 + /* This one gets from the primary mpic via CoreInt*/ 474 + extern unsigned int mpic_get_coreint_irq(void); 483 475 /* Fetch Machine Check interrupt from primary mpic */ 484 476 extern unsigned int mpic_get_mcirq(void); 485 477
-1
arch/powerpc/include/asm/ps3fb.h
··· 21 21 22 22 #include <linux/types.h> 23 23 #include <linux/ioctl.h> 24 - #include <linux/types.h> 25 24 26 25 /* ioctl */ 27 26 #define PS3FB_IOCTL_SETMODE _IOW('r', 1, int) /* set video mode */
+4 -2
arch/powerpc/include/asm/pte-common.h
··· 151 151 _PAGE_NO_CACHE) 152 152 #define PAGE_KERNEL_NCG __pgprot(_PAGE_BASE_NC | _PAGE_KERNEL_RW | \ 153 153 _PAGE_NO_CACHE | _PAGE_GUARDED) 154 - #define PAGE_KERNEL_X __pgprot(_PAGE_BASE | _PAGE_KERNEL_RW | _PAGE_EXEC) 154 + #define PAGE_KERNEL_X __pgprot(_PAGE_BASE | _PAGE_KERNEL_RW | _PAGE_EXEC | \ 155 + _PAGE_HWEXEC) 155 156 #define PAGE_KERNEL_RO __pgprot(_PAGE_BASE | _PAGE_KERNEL_RO) 156 - #define PAGE_KERNEL_ROX __pgprot(_PAGE_BASE | _PAGE_KERNEL_RO | _PAGE_EXEC) 157 + #define PAGE_KERNEL_ROX __pgprot(_PAGE_BASE | _PAGE_KERNEL_RO | _PAGE_EXEC | \ 158 + _PAGE_HWEXEC) 157 159 158 160 /* Protection used for kernel text. We want the debuggers to be able to 159 161 * set breakpoints anywhere, so don't write protect the kernel text
+30
arch/powerpc/include/asm/reg.h
··· 143 143 #define FPSCR_NI 0x00000004 /* FPU non IEEE-Mode */ 144 144 #define FPSCR_RN 0x00000003 /* FPU rounding control */ 145 145 146 + /* Bit definitions for SPEFSCR. */ 147 + #define SPEFSCR_SOVH 0x80000000 /* Summary integer overflow high */ 148 + #define SPEFSCR_OVH 0x40000000 /* Integer overflow high */ 149 + #define SPEFSCR_FGH 0x20000000 /* Embedded FP guard bit high */ 150 + #define SPEFSCR_FXH 0x10000000 /* Embedded FP sticky bit high */ 151 + #define SPEFSCR_FINVH 0x08000000 /* Embedded FP invalid operation high */ 152 + #define SPEFSCR_FDBZH 0x04000000 /* Embedded FP div by zero high */ 153 + #define SPEFSCR_FUNFH 0x02000000 /* Embedded FP underflow high */ 154 + #define SPEFSCR_FOVFH 0x01000000 /* Embedded FP overflow high */ 155 + #define SPEFSCR_FINXS 0x00200000 /* Embedded FP inexact sticky */ 156 + #define SPEFSCR_FINVS 0x00100000 /* Embedded FP invalid op. sticky */ 157 + #define SPEFSCR_FDBZS 0x00080000 /* Embedded FP div by zero sticky */ 158 + #define SPEFSCR_FUNFS 0x00040000 /* Embedded FP underflow sticky */ 159 + #define SPEFSCR_FOVFS 0x00020000 /* Embedded FP overflow sticky */ 160 + #define SPEFSCR_MODE 0x00010000 /* Embedded FP mode */ 161 + #define SPEFSCR_SOV 0x00008000 /* Integer summary overflow */ 162 + #define SPEFSCR_OV 0x00004000 /* Integer overflow */ 163 + #define SPEFSCR_FG 0x00002000 /* Embedded FP guard bit */ 164 + #define SPEFSCR_FX 0x00001000 /* Embedded FP sticky bit */ 165 + #define SPEFSCR_FINV 0x00000800 /* Embedded FP invalid operation */ 166 + #define SPEFSCR_FDBZ 0x00000400 /* Embedded FP div by zero */ 167 + #define SPEFSCR_FUNF 0x00000200 /* Embedded FP underflow */ 168 + #define SPEFSCR_FOVF 0x00000100 /* Embedded FP overflow */ 169 + #define SPEFSCR_FINXE 0x00000040 /* Embedded FP inexact enable */ 170 + #define SPEFSCR_FINVE 0x00000020 /* Embedded FP invalid op. enable */ 171 + #define SPEFSCR_FDBZE 0x00000010 /* Embedded FP div by zero enable */ 172 + #define SPEFSCR_FUNFE 0x00000008 /* Embedded FP underflow enable */ 173 + #define SPEFSCR_FOVFE 0x00000004 /* Embedded FP overflow enable */ 174 + #define SPEFSCR_FRMC 0x00000003 /* Embedded FP rounding mode control */ 175 + 146 176 /* Special Purpose Registers (SPRNs)*/ 147 177 #define SPRN_CTR 0x009 /* Count Register */ 148 178 #define SPRN_DSCR 0x11
-30
arch/powerpc/include/asm/reg_booke.h
··· 423 423 #define SGR_NORMAL 0 /* Speculative fetching allowed. */ 424 424 #define SGR_GUARDED 1 /* Speculative fetching disallowed. */ 425 425 426 - /* Bit definitions for SPEFSCR. */ 427 - #define SPEFSCR_SOVH 0x80000000 /* Summary integer overflow high */ 428 - #define SPEFSCR_OVH 0x40000000 /* Integer overflow high */ 429 - #define SPEFSCR_FGH 0x20000000 /* Embedded FP guard bit high */ 430 - #define SPEFSCR_FXH 0x10000000 /* Embedded FP sticky bit high */ 431 - #define SPEFSCR_FINVH 0x08000000 /* Embedded FP invalid operation high */ 432 - #define SPEFSCR_FDBZH 0x04000000 /* Embedded FP div by zero high */ 433 - #define SPEFSCR_FUNFH 0x02000000 /* Embedded FP underflow high */ 434 - #define SPEFSCR_FOVFH 0x01000000 /* Embedded FP overflow high */ 435 - #define SPEFSCR_FINXS 0x00200000 /* Embedded FP inexact sticky */ 436 - #define SPEFSCR_FINVS 0x00100000 /* Embedded FP invalid op. sticky */ 437 - #define SPEFSCR_FDBZS 0x00080000 /* Embedded FP div by zero sticky */ 438 - #define SPEFSCR_FUNFS 0x00040000 /* Embedded FP underflow sticky */ 439 - #define SPEFSCR_FOVFS 0x00020000 /* Embedded FP overflow sticky */ 440 - #define SPEFSCR_MODE 0x00010000 /* Embedded FP mode */ 441 - #define SPEFSCR_SOV 0x00008000 /* Integer summary overflow */ 442 - #define SPEFSCR_OV 0x00004000 /* Integer overflow */ 443 - #define SPEFSCR_FG 0x00002000 /* Embedded FP guard bit */ 444 - #define SPEFSCR_FX 0x00001000 /* Embedded FP sticky bit */ 445 - #define SPEFSCR_FINV 0x00000800 /* Embedded FP invalid operation */ 446 - #define SPEFSCR_FDBZ 0x00000400 /* Embedded FP div by zero */ 447 - #define SPEFSCR_FUNF 0x00000200 /* Embedded FP underflow */ 448 - #define SPEFSCR_FOVF 0x00000100 /* Embedded FP overflow */ 449 - #define SPEFSCR_FINXE 0x00000040 /* Embedded FP inexact enable */ 450 - #define SPEFSCR_FINVE 0x00000020 /* Embedded FP invalid op. enable */ 451 - #define SPEFSCR_FDBZE 0x00000010 /* Embedded FP div by zero enable */ 452 - #define SPEFSCR_FUNFE 0x00000008 /* Embedded FP underflow enable */ 453 - #define SPEFSCR_FOVFE 0x00000004 /* Embedded FP overflow enable */ 454 - #define SPEFSCR_FRMC 0x00000003 /* Embedded FP rounding mode control */ 455 - 456 426 /* 457 427 * The IBM-403 is an even more odd special case, as it is much 458 428 * older than the IBM-405 series. We put these down here incase someone
+2 -1
arch/powerpc/include/asm/rtas.h
··· 68 68 #define RTAS_EPOW_WARNING 0x40000000 /* set bit 1 */ 69 69 #define RTAS_POWERMGM_EVENTS 0x20000000 /* set bit 2 */ 70 70 #define RTAS_HOTPLUG_EVENTS 0x10000000 /* set bit 3 */ 71 - #define RTAS_EVENT_SCAN_ALL_EVENTS 0xf0000000 71 + #define RTAS_IO_EVENTS 0x08000000 /* set bit 4 */ 72 + #define RTAS_EVENT_SCAN_ALL_EVENTS 0xffffffff 72 73 73 74 /* RTAS event severity */ 74 75 #define RTAS_SEVERITY_FATAL 0x5
+3 -3
arch/powerpc/include/asm/sfp-machine.h
··· 29 29 30 30 /* basic word size definitions */ 31 31 #define _FP_W_TYPE_SIZE 32 32 - #define _FP_W_TYPE unsigned long 33 - #define _FP_WS_TYPE signed long 34 - #define _FP_I_TYPE long 32 + #define _FP_W_TYPE unsigned int 33 + #define _FP_WS_TYPE signed int 34 + #define _FP_I_TYPE int 35 35 36 36 #define __ll_B ((UWtype) 1 << (W_TYPE_SIZE / 2)) 37 37 #define __ll_lowpart(t) ((UWtype) (t) & (__ll_B - 1))
+3
arch/powerpc/include/asm/systbl.h
··· 322 322 SYSCALL_SPU(dup3) 323 323 SYSCALL_SPU(pipe2) 324 324 SYSCALL(inotify_init1) 325 + SYSCALL(ni_syscall) 326 + COMPAT_SYS_SPU(preadv) 327 + COMPAT_SYS_SPU(pwritev)
+3 -1
arch/powerpc/include/asm/unistd.h
··· 341 341 #define __NR_dup3 316 342 342 #define __NR_pipe2 317 343 343 #define __NR_inotify_init1 318 344 + #define __NR_preadv 320 345 + #define __NR_pwritev 321 344 346 345 347 #ifdef __KERNEL__ 346 348 347 - #define __NR_syscalls 319 349 + #define __NR_syscalls 322 348 350 349 351 #define __NR__exit __NR_exit 350 352 #define NR_syscalls __NR_syscalls
+5
arch/powerpc/kernel/fpu.S
··· 145 145 beq 1f 146 146 PPC_LL r4,_MSR-STACK_FRAME_OVERHEAD(r5) 147 147 li r3,MSR_FP|MSR_FE0|MSR_FE1 148 + #ifdef CONFIG_VSX 149 + BEGIN_FTR_SECTION 150 + oris r3,r3,MSR_VSX@h 151 + END_FTR_SECTION_IFSET(CPU_FTR_VSX) 152 + #endif 148 153 andc r4,r4,r3 /* disable FP for previous task */ 149 154 PPC_STL r4,_MSR-STACK_FRAME_OVERHEAD(r5) 150 155 1:
+2 -2
arch/powerpc/kernel/ftrace.c
··· 293 293 if (tramp & 0x8000) 294 294 tramp -= 0x10000; 295 295 296 - pr_debug(" %x ", tramp); 296 + pr_debug(" %lx ", tramp); 297 297 298 298 if (tramp != addr) { 299 299 printk(KERN_ERR ··· 564 564 if (unlikely(atomic_read(&current->tracing_graph_pause))) 565 565 return; 566 566 567 - #if CONFIG_PPC64 567 + #ifdef CONFIG_PPC64 568 568 /* non core kernel code needs to save and restore the TOC */ 569 569 if (REGION_ID(self_addr) != KERNEL_REGION_ID) 570 570 return_hooker = (unsigned long)&mod_return_to_handler;
+3 -1
arch/powerpc/kernel/irq.c
··· 672 672 return NO_IRQ; 673 673 } 674 674 } 675 - pr_debug("irq: -> obtained virq %d\n", virq); 676 675 677 676 if (irq_setup_virq(host, virq, hwirq)) 678 677 return NO_IRQ; 678 + 679 + printk(KERN_DEBUG "irq: irq %lu on host %s mapped to virtual irq %u\n", 680 + hwirq, host->of_node ? host->of_node->full_name : "null", virq); 679 681 680 682 return virq; 681 683 }
+16
arch/powerpc/kernel/lparcfg.c
··· 434 434 seq_printf(m, "cmo_page_size=%lu\n", cmo_get_page_size()); 435 435 } 436 436 437 + static void splpar_dispatch_data(struct seq_file *m) 438 + { 439 + int cpu; 440 + unsigned long dispatches = 0; 441 + unsigned long dispatch_dispersions = 0; 442 + 443 + for_each_possible_cpu(cpu) { 444 + dispatches += lppaca[cpu].yield_count; 445 + dispatch_dispersions += lppaca[cpu].dispersion_count; 446 + } 447 + 448 + seq_printf(m, "dispatches=%lu\n", dispatches); 449 + seq_printf(m, "dispatch_dispersions=%lu\n", dispatch_dispersions); 450 + } 451 + 437 452 static int pseries_lparcfg_data(struct seq_file *m, void *v) 438 453 { 439 454 int partition_potential_processors; ··· 475 460 parse_ppp_data(m); 476 461 parse_mpp_data(m); 477 462 pseries_cmo_data(m); 463 + splpar_dispatch_data(m); 478 464 479 465 seq_printf(m, "purr=%ld\n", get_purr()); 480 466 } else { /* non SPLPAR case */
+8
arch/powerpc/kernel/misc_64.S
··· 495 495 stvx vr0,r4,r3 496 496 beq 1f 497 497 ld r4,_MSR-STACK_FRAME_OVERHEAD(r5) 498 + #ifdef CONFIG_VSX 499 + BEGIN_FTR_SECTION 500 + lis r3,(MSR_VEC|MSR_VSX)@h 501 + FTR_SECTION_ELSE 498 502 lis r3,MSR_VEC@h 503 + ALT_FTR_SECTION_END_IFSET(CPU_FTR_VSX) 504 + #else 505 + lis r3,MSR_VEC@h 506 + #endif 499 507 andc r4,r4,r3 /* disable FP for previous task */ 500 508 std r4,_MSR-STACK_FRAME_OVERHEAD(r5) 501 509 1:
+10 -8
arch/powerpc/kernel/prom_init.c
··· 614 614 W(0xffffffff), /* virt_base */ 615 615 W(0xffffffff), /* virt_size */ 616 616 W(0xffffffff), /* load_base */ 617 - W(64), /* 128MB min RMA */ 617 + W(64), /* 64MB min RMA */ 618 618 W(0xffffffff), /* full client load */ 619 619 0, /* min RMA percentage of total RAM */ 620 620 48, /* max log_2(hash table size) */ ··· 732 732 root = call_prom("open", 1, 1, ADDR("/")); 733 733 if (root != 0) { 734 734 /* try calling the ibm,client-architecture-support method */ 735 + prom_printf("Calling ibm,client-architecture..."); 735 736 if (call_prom_ret("call-method", 3, 2, &ret, 736 737 ADDR("ibm,client-architecture-support"), 737 738 root, 738 739 ADDR(ibm_architecture_vec)) == 0) { 739 740 /* the call exists... */ 740 741 if (ret) 741 - prom_printf("WARNING: ibm,client-architecture" 742 + prom_printf("\nWARNING: ibm,client-architecture" 742 743 "-support call FAILED!\n"); 743 744 call_prom("close", 1, 0, root); 745 + prom_printf(" done\n"); 744 746 return; 745 747 } 746 748 call_prom("close", 1, 0, root); ··· 1085 1083 return; 1086 1084 } 1087 1085 1088 - prom_printf("instantiating rtas at 0x%x ...", base); 1086 + prom_printf("instantiating rtas at 0x%x...", base); 1089 1087 1090 1088 if (call_prom_ret("call-method", 3, 2, &entry, 1091 1089 ADDR("instantiate-rtas"), ··· 1497 1495 return PLATFORM_GENERIC; 1498 1496 x = prom_getproplen(rtas, "ibm,hypertas-functions"); 1499 1497 if (x != PROM_ERROR) { 1500 - prom_printf("Hypertas detected, assuming LPAR !\n"); 1498 + prom_debug("Hypertas detected, assuming LPAR !\n"); 1501 1499 return PLATFORM_PSERIES_LPAR; 1502 1500 } 1503 1501 return PLATFORM_PSERIES; ··· 1546 1544 }; 1547 1545 const unsigned char *clut; 1548 1546 1549 - prom_printf("Looking for displays\n"); 1547 + prom_debug("Looking for displays\n"); 1550 1548 for (node = 0; prom_next_node(&node); ) { 1551 1549 memset(type, 0, sizeof(type)); 1552 1550 prom_getprop(node, "device_type", type, sizeof(type)); ··· 1564 1562 if (call_prom("package-to-path", 3, 1, node, path, 1565 1563 PROM_SCRATCH_SIZE-10) == PROM_ERROR) 1566 1564 continue; 1567 - prom_printf("found display : %s, opening ... ", path); 1565 + prom_printf("found display : %s, opening... ", path); 1568 1566 1569 1567 ih = call_prom("open", 1, 1, path); 1570 1568 if (ih == 0) { ··· 2389 2387 /* 2390 2388 * Now finally create the flattened device-tree 2391 2389 */ 2392 - prom_printf("copying OF device tree ...\n"); 2390 + prom_printf("copying OF device tree...\n"); 2393 2391 flatten_device_tree(); 2394 2392 2395 2393 /* ··· 2404 2402 * Call OF "quiesce" method to shut down pending DMA's from 2405 2403 * devices etc... 2406 2404 */ 2407 - prom_printf("Calling quiesce ...\n"); 2405 + prom_printf("Calling quiesce...\n"); 2408 2406 call_prom("quiesce", 0, 0); 2409 2407 2410 2408 /*
+11 -4
arch/powerpc/kernel/ptrace32.c
··· 67 67 /* Macros to workout the correct index for the FPR in the thread struct */ 68 68 #define FPRNUMBER(i) (((i) - PT_FPR0) >> 1) 69 69 #define FPRHALF(i) (((i) - PT_FPR0) & 1) 70 - #define FPRINDEX(i) TS_FPRWIDTH * FPRNUMBER(i) + FPRHALF(i) 70 + #define FPRINDEX(i) TS_FPRWIDTH * FPRNUMBER(i) * 2 + FPRHALF(i) 71 + #define FPRINDEX_3264(i) (TS_FPRWIDTH * ((i) - PT_FPR0)) 71 72 72 73 long compat_arch_ptrace(struct task_struct *child, compat_long_t request, 73 74 compat_ulong_t caddr, compat_ulong_t cdata) ··· 169 168 CHECK_FULL_REGS(child->thread.regs); 170 169 if (numReg >= PT_FPR0) { 171 170 flush_fp_to_thread(child); 172 - tmp = ((unsigned long int *)child->thread.fpr) 173 - [FPRINDEX(numReg)]; 171 + /* get 64 bit FPR */ 172 + tmp = ((u64 *)child->thread.fpr) 173 + [FPRINDEX_3264(numReg)]; 174 174 } else { /* register within PT_REGS struct */ 175 175 tmp = ptrace_get_reg(child, numReg); 176 176 } ··· 264 262 freg = (freg & 0xfffffffful) | (data << 32); 265 263 ret = ptrace_put_reg(child, numReg, freg); 266 264 } else { 265 + u64 *tmp; 267 266 flush_fp_to_thread(child); 268 - ((unsigned int *)child->thread.regs)[index] = data; 267 + /* get 64 bit FPR ... */ 268 + tmp = &(((u64 *)child->thread.fpr) 269 + [FPRINDEX_3264(numReg)]); 270 + /* ... write the 32 bit part we want */ 271 + ((u32 *)tmp)[index % 2] = data; 269 272 ret = 0; 270 273 } 271 274 break;
-1
arch/powerpc/kernel/setup-common.c
··· 36 36 #include <linux/percpu.h> 37 37 #include <linux/lmb.h> 38 38 #include <linux/of_platform.h> 39 - #include <linux/platform_device.h> 40 39 #include <asm/io.h> 41 40 #include <asm/prom.h> 42 41 #include <asm/processor.h>
+34
arch/powerpc/sysdev/mpic.c
··· 1170 1170 mb(); 1171 1171 } 1172 1172 1173 + /* CoreInt */ 1174 + if (flags & MPIC_ENABLE_COREINT) 1175 + mpic_write(mpic->gregs, MPIC_INFO(GREG_GLOBAL_CONF_0), 1176 + mpic_read(mpic->gregs, MPIC_INFO(GREG_GLOBAL_CONF_0)) 1177 + | MPIC_GREG_GCONF_COREINT); 1178 + 1173 1179 if (flags & MPIC_ENABLE_MCK) 1174 1180 mpic_write(mpic->gregs, MPIC_INFO(GREG_GLOBAL_CONF_0), 1175 1181 mpic_read(mpic->gregs, MPIC_INFO(GREG_GLOBAL_CONF_0)) ··· 1529 1523 BUG_ON(mpic == NULL); 1530 1524 1531 1525 return mpic_get_one_irq(mpic); 1526 + } 1527 + 1528 + unsigned int mpic_get_coreint_irq(void) 1529 + { 1530 + #ifdef CONFIG_BOOKE 1531 + struct mpic *mpic = mpic_primary; 1532 + u32 src; 1533 + 1534 + BUG_ON(mpic == NULL); 1535 + 1536 + src = mfspr(SPRN_EPR); 1537 + 1538 + if (unlikely(src == mpic->spurious_vec)) { 1539 + if (mpic->flags & MPIC_SPV_EOI) 1540 + mpic_eoi(mpic); 1541 + return NO_IRQ; 1542 + } 1543 + if (unlikely(mpic->protected && test_bit(src, mpic->protected))) { 1544 + if (printk_ratelimit()) 1545 + printk(KERN_WARNING "%s: Got protected source %d !\n", 1546 + mpic->name, (int)src); 1547 + return NO_IRQ; 1548 + } 1549 + 1550 + return irq_linear_revmap(mpic->irqhost, src); 1551 + #else 1552 + return NO_IRQ; 1553 + #endif 1532 1554 } 1533 1555 1534 1556 unsigned int mpic_get_mcirq(void)
+7 -7
drivers/serial/cpm_uart/cpm_uart_core.c
··· 1106 1106 for (i = 0; i < NUM_GPIOS; i++) 1107 1107 pinfo->gpios[i] = of_get_gpio(np, i); 1108 1108 1109 + #ifdef CONFIG_PPC_EARLY_DEBUG_CPM 1110 + udbg_putc = NULL; 1111 + #endif 1112 + 1109 1113 return cpm_uart_request_port(&pinfo->port); 1110 1114 1111 1115 out_pram: ··· 1259 1255 baud = 9600; 1260 1256 } 1261 1257 1262 - #ifdef CONFIG_PPC_EARLY_DEBUG_CPM 1263 - udbg_putc = NULL; 1264 - #endif 1265 - 1266 1258 if (IS_SMC(pinfo)) { 1267 1259 out_be16(&pinfo->smcup->smc_brkcr, 0); 1268 1260 cpm_line_cr_cmd(pinfo, CPM_CR_STOP_TX); ··· 1339 1339 1340 1340 dev_set_drvdata(&ofdev->dev, pinfo); 1341 1341 1342 + /* initialize the device pointer for the port */ 1343 + pinfo->port.dev = &ofdev->dev; 1344 + 1342 1345 ret = cpm_uart_init_port(ofdev->node, pinfo); 1343 1346 if (ret) 1344 1347 return ret; 1345 - 1346 - /* initialize the device pointer for the port */ 1347 - pinfo->port.dev = &ofdev->dev; 1348 1348 1349 1349 return uart_add_one_port(&cpm_reg, &pinfo->port); 1350 1350 }
+15
drivers/serial/pmac_zilog.c
··· 1538 1538 uap->port.type = PORT_PMAC_ZILOG; 1539 1539 uap->port.flags = 0; 1540 1540 1541 + /* 1542 + * Fixup for the port on Gatwick for which the device-tree has 1543 + * missing interrupts. Normally, the macio_dev would contain 1544 + * fixed up interrupt info, but we use the device-tree directly 1545 + * here due to early probing so we need the fixup too. 1546 + */ 1547 + if (uap->port.irq == NO_IRQ && 1548 + np->parent && np->parent->parent && 1549 + of_device_is_compatible(np->parent->parent, "gatwick")) { 1550 + /* IRQs on gatwick are offset by 64 */ 1551 + uap->port.irq = irq_create_mapping(NULL, 64 + 15); 1552 + uap->tx_dma_irq = irq_create_mapping(NULL, 64 + 4); 1553 + uap->rx_dma_irq = irq_create_mapping(NULL, 64 + 5); 1554 + } 1555 + 1541 1556 /* Setup some valid baud rate information in the register 1542 1557 * shadows so we don't write crap there before baud rate is 1543 1558 * first initialized.
+21 -13
drivers/video/fsl-diu-fb.c
··· 1352 1352 #endif /* CONFIG_PM */ 1353 1353 1354 1354 /* Align to 64-bit(8-byte), 32-byte, etc. */ 1355 - static int allocate_buf(struct diu_addr *buf, u32 size, u32 bytes_align) 1355 + static int allocate_buf(struct device *dev, struct diu_addr *buf, u32 size, 1356 + u32 bytes_align) 1356 1357 { 1357 1358 u32 offset, ssize; 1358 1359 u32 mask; 1359 1360 dma_addr_t paddr = 0; 1360 1361 1361 1362 ssize = size + bytes_align; 1362 - buf->vaddr = dma_alloc_coherent(NULL, ssize, &paddr, GFP_DMA | 1363 + buf->vaddr = dma_alloc_coherent(dev, ssize, &paddr, GFP_DMA | 1363 1364 __GFP_ZERO); 1364 1365 if (!buf->vaddr) 1365 1366 return -ENOMEM; ··· 1377 1376 return 0; 1378 1377 } 1379 1378 1380 - static void free_buf(struct diu_addr *buf, u32 size, u32 bytes_align) 1379 + static void free_buf(struct device *dev, struct diu_addr *buf, u32 size, 1380 + u32 bytes_align) 1381 1381 { 1382 - dma_free_coherent(NULL, size + bytes_align, 1382 + dma_free_coherent(dev, size + bytes_align, 1383 1383 buf->vaddr, (buf->paddr - buf->offset)); 1384 1384 return; 1385 1385 } ··· 1478 1476 machine_data->monitor_port = monitor_port; 1479 1477 1480 1478 /* Area descriptor memory pool aligns to 64-bit boundary */ 1481 - if (allocate_buf(&pool.ad, sizeof(struct diu_ad) * FSL_AOI_NUM, 8)) 1479 + if (allocate_buf(&ofdev->dev, &pool.ad, 1480 + sizeof(struct diu_ad) * FSL_AOI_NUM, 8)) 1482 1481 return -ENOMEM; 1483 1482 1484 1483 /* Get memory for Gamma Table - 32-byte aligned memory */ 1485 - if (allocate_buf(&pool.gamma, 768, 32)) { 1484 + if (allocate_buf(&ofdev->dev, &pool.gamma, 768, 32)) { 1486 1485 ret = -ENOMEM; 1487 1486 goto error; 1488 1487 } 1489 1488 1490 1489 /* For performance, cursor bitmap buffer aligns to 32-byte boundary */ 1491 - if (allocate_buf(&pool.cursor, MAX_CURS * MAX_CURS * 2, 32)) { 1490 + if (allocate_buf(&ofdev->dev, &pool.cursor, MAX_CURS * MAX_CURS * 2, 1491 + 32)) { 1492 1492 ret = -ENOMEM; 1493 1493 goto error; 1494 1494 } ··· 1558 1554 i > 0; i--) 1559 1555 uninstall_fb(machine_data->fsl_diu_info[i - 1]); 1560 1556 if (pool.ad.vaddr) 1561 - free_buf(&pool.ad, sizeof(struct diu_ad) * FSL_AOI_NUM, 8); 1557 + free_buf(&ofdev->dev, &pool.ad, 1558 + sizeof(struct diu_ad) * FSL_AOI_NUM, 8); 1562 1559 if (pool.gamma.vaddr) 1563 - free_buf(&pool.gamma, 768, 32); 1560 + free_buf(&ofdev->dev, &pool.gamma, 768, 32); 1564 1561 if (pool.cursor.vaddr) 1565 - free_buf(&pool.cursor, MAX_CURS * MAX_CURS * 2, 32); 1562 + free_buf(&ofdev->dev, &pool.cursor, MAX_CURS * MAX_CURS * 2, 1563 + 32); 1566 1564 if (machine_data->dummy_aoi_virt) 1567 1565 fsl_diu_free(machine_data->dummy_aoi_virt, 64); 1568 1566 iounmap(dr.diu_reg); ··· 1590 1584 for (i = ARRAY_SIZE(machine_data->fsl_diu_info); i > 0; i--) 1591 1585 uninstall_fb(machine_data->fsl_diu_info[i - 1]); 1592 1586 if (pool.ad.vaddr) 1593 - free_buf(&pool.ad, sizeof(struct diu_ad) * FSL_AOI_NUM, 8); 1587 + free_buf(&ofdev->dev, &pool.ad, 1588 + sizeof(struct diu_ad) * FSL_AOI_NUM, 8); 1594 1589 if (pool.gamma.vaddr) 1595 - free_buf(&pool.gamma, 768, 32); 1590 + free_buf(&ofdev->dev, &pool.gamma, 768, 32); 1596 1591 if (pool.cursor.vaddr) 1597 - free_buf(&pool.cursor, MAX_CURS * MAX_CURS * 2, 32); 1592 + free_buf(&ofdev->dev, &pool.cursor, MAX_CURS * MAX_CURS * 2, 1593 + 32); 1598 1594 if (machine_data->dummy_aoi_virt) 1599 1595 fsl_diu_free(machine_data->dummy_aoi_virt, 64); 1600 1596 iounmap(dr.diu_reg);
+11 -2
drivers/watchdog/wdrtas.c
··· 106 106 return result; 107 107 } 108 108 109 + #define WDRTAS_SP_SPI_LEN 4 110 + 109 111 /** 110 112 * wdrtas_get_interval - returns the current watchdog interval 111 113 * @fallback_value: value (in seconds) to use, if the RTAS call fails ··· 121 119 static int wdrtas_get_interval(int fallback_value) 122 120 { 123 121 long result; 124 - char value[4]; 122 + char value[WDRTAS_SP_SPI_LEN]; 125 123 124 + spin_lock(&rtas_data_buf_lock); 125 + memset(rtas_data_buf, 0, WDRTAS_SP_SPI_LEN); 126 126 result = rtas_call(wdrtas_token_get_sp, 3, 1, NULL, 127 - WDRTAS_SP_SPI, (void *)__pa(&value), 4); 127 + WDRTAS_SP_SPI, __pa(rtas_data_buf), 128 + WDRTAS_SP_SPI_LEN); 129 + 130 + memcpy(value, rtas_data_buf, WDRTAS_SP_SPI_LEN); 131 + spin_unlock(&rtas_data_buf_lock); 132 + 128 133 if (value[0] != 0 || value[1] != 2 || value[3] != 0 || result < 0) { 129 134 printk(KERN_WARNING "wdrtas: could not get sp_spi watchdog " 130 135 "timeout (%li). Continuing\n", result);
-22
include/linux/fsl_devices.h
··· 18 18 #define _FSL_DEVICE_H_ 19 19 20 20 #include <linux/types.h> 21 - #include <linux/phy.h> 22 21 23 22 /* 24 23 * Some conventions on how we handle peripherals on Freescale chips ··· 42 43 * - platform data board flags: FSL_<driver>_BRD_<FLAG> 43 44 * 44 45 */ 45 - 46 - struct gianfar_platform_data { 47 - /* device specific information */ 48 - u32 device_flags; 49 - char bus_id[BUS_ID_SIZE]; 50 - phy_interface_t interface; 51 - }; 52 - 53 - struct gianfar_mdio_data { 54 - /* board specific information */ 55 - int irq[32]; 56 - }; 57 - 58 - /* Flags in gianfar_platform_data */ 59 - #define FSL_GIANFAR_BRD_HAS_PHY_INTR 0x00000001 /* set or use a timer */ 60 - #define FSL_GIANFAR_BRD_IS_REDUCED 0x00000002 /* Set if RGMII, RMII */ 61 - 62 - struct fsl_i2c_platform_data { 63 - /* device specific information */ 64 - u32 device_flags; 65 - }; 66 46 67 47 /* Flags related to I2C device features */ 68 48 #define FSL_I2C_DEV_SEPARATE_DFSRR 0x00000001