Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
[SPARC64]: make IOMMU code respect the segment boundary limits
[SPARC64]: Fix cpu trampoline et al. mismatch warnings.
[SPARC64]: More sparse warning fixes in process.c
[SPARC64]: Fix sparse warning wrt. fault_in_user_windows.
[SPARC64]: Kill show_regs32().
[SPARC64]: Fix sparse warnings wrt. __show_regs().
[SPARC64]: Kill show_stackframe{,32}().
[SPARC64]: Fix sparse warnings wrt. machine_alt_power_off().

+34 -84
+3 -1
arch/sparc64/kernel/hvtramp.S
··· 3 3 * Copyright (C) 2007 David S. Miller <davem@davemloft.net> 4 4 */ 5 5 6 + #include <linux/init.h> 7 + 6 8 #include <asm/thread_info.h> 7 9 #include <asm/hypervisor.h> 8 10 #include <asm/scratchpad.h> ··· 15 13 #include <asm/head.h> 16 14 #include <asm/asi.h> 17 15 18 - .text 16 + __CPUINIT 19 17 .align 8 20 18 .globl hv_cpu_startup, hv_cpu_startup_end 21 19
+2 -1
arch/sparc64/kernel/iommu.c
··· 134 134 else 135 135 boundary_size = ALIGN(1UL << 32, 1 << IO_PAGE_SHIFT); 136 136 137 - n = iommu_area_alloc(arena->map, limit, start, npages, 0, 137 + n = iommu_area_alloc(arena->map, limit, start, npages, 138 + iommu->page_table_map_base >> IO_PAGE_SHIFT, 138 139 boundary_size >> IO_PAGE_SHIFT, 0); 139 140 if (n == -1) { 140 141 if (likely(pass < 1)) {
-2
arch/sparc64/kernel/kprobes.c
··· 465 465 466 466 extern void jprobe_return_trap_instruction(void); 467 467 468 - extern void __show_regs(struct pt_regs * regs); 469 - 470 468 int __kprobes longjmp_break_handler(struct kprobe *p, struct pt_regs *regs) 471 469 { 472 470 u32 *addr = (u32 *) regs->tpc;
+1 -2
arch/sparc64/kernel/power.c
··· 20 20 #include <asm/of_device.h> 21 21 #include <asm/io.h> 22 22 #include <asm/sstate.h> 23 + #include <asm/reboot.h> 23 24 24 25 #include <linux/unistd.h> 25 26 ··· 40 39 return IRQ_HANDLED; 41 40 } 42 41 43 - extern void machine_halt(void); 44 - extern void machine_alt_power_off(void); 45 42 static void (*poweroff_method)(void) = machine_alt_power_off; 46 43 47 44 void machine_power_off(void)
+3 -74
arch/sparc64/kernel/process.c
··· 30 30 #include <linux/tick.h> 31 31 #include <linux/init.h> 32 32 #include <linux/cpu.h> 33 + #include <linux/elfcore.h> 33 34 34 35 #include <asm/oplib.h> 35 36 #include <asm/uaccess.h> ··· 48 47 #include <asm/unistd.h> 49 48 #include <asm/hypervisor.h> 50 49 #include <asm/sstate.h> 50 + #include <asm/reboot.h> 51 + #include <asm/syscalls.h> 51 52 52 53 /* #define VERBOSE_SHOWREGS */ 53 54 ··· 214 211 print_symbol("I7: <%s>\n", rwk->ins[7]); 215 212 } 216 213 217 - void show_stackframe(struct sparc_stackf *sf) 218 - { 219 - unsigned long size; 220 - unsigned long *stk; 221 - int i; 222 - 223 - printk("l0: %016lx l1: %016lx l2: %016lx l3: %016lx\n" 224 - "l4: %016lx l5: %016lx l6: %016lx l7: %016lx\n", 225 - sf->locals[0], sf->locals[1], sf->locals[2], sf->locals[3], 226 - sf->locals[4], sf->locals[5], sf->locals[6], sf->locals[7]); 227 - printk("i0: %016lx i1: %016lx i2: %016lx i3: %016lx\n" 228 - "i4: %016lx i5: %016lx fp: %016lx ret_pc: %016lx\n", 229 - sf->ins[0], sf->ins[1], sf->ins[2], sf->ins[3], 230 - sf->ins[4], sf->ins[5], (unsigned long)sf->fp, sf->callers_pc); 231 - printk("sp: %016lx x0: %016lx x1: %016lx x2: %016lx\n" 232 - "x3: %016lx x4: %016lx x5: %016lx xx: %016lx\n", 233 - (unsigned long)sf->structptr, sf->xargs[0], sf->xargs[1], 234 - sf->xargs[2], sf->xargs[3], sf->xargs[4], sf->xargs[5], 235 - sf->xxargs[0]); 236 - size = ((unsigned long)sf->fp) - ((unsigned long)sf); 237 - size -= STACKFRAME_SZ; 238 - stk = (unsigned long *)((unsigned long)sf + STACKFRAME_SZ); 239 - i = 0; 240 - do { 241 - printk("s%d: %016lx\n", i++, *stk++); 242 - } while ((size -= sizeof(unsigned long))); 243 - } 244 - 245 - void show_stackframe32(struct sparc_stackf32 *sf) 246 - { 247 - unsigned long size; 248 - unsigned *stk; 249 - int i; 250 - 251 - printk("l0: %08x l1: %08x l2: %08x l3: %08x\n", 252 - sf->locals[0], sf->locals[1], sf->locals[2], sf->locals[3]); 253 - printk("l4: %08x l5: %08x l6: %08x l7: %08x\n", 254 - sf->locals[4], sf->locals[5], sf->locals[6], sf->locals[7]); 255 - printk("i0: %08x i1: %08x i2: %08x i3: %08x\n", 256 - sf->ins[0], sf->ins[1], sf->ins[2], sf->ins[3]); 257 - printk("i4: %08x i5: %08x fp: %08x ret_pc: %08x\n", 258 - sf->ins[4], sf->ins[5], sf->fp, sf->callers_pc); 259 - printk("sp: %08x x0: %08x x1: %08x x2: %08x\n" 260 - "x3: %08x x4: %08x x5: %08x xx: %08x\n", 261 - sf->structptr, sf->xargs[0], sf->xargs[1], 262 - sf->xargs[2], sf->xargs[3], sf->xargs[4], sf->xargs[5], 263 - sf->xxargs[0]); 264 - size = ((unsigned long)sf->fp) - ((unsigned long)sf); 265 - size -= STACKFRAME32_SZ; 266 - stk = (unsigned *)((unsigned long)sf + STACKFRAME32_SZ); 267 - i = 0; 268 - do { 269 - printk("s%d: %08x\n", i++, *stk++); 270 - } while ((size -= sizeof(unsigned))); 271 - } 272 - 273 214 #ifdef CONFIG_SMP 274 215 static DEFINE_SPINLOCK(regdump_lock); 275 216 #endif ··· 299 352 printk ("*********endpar**********\n"); 300 353 } 301 354 #endif 302 - } 303 - 304 - void show_regs32(struct pt_regs32 *regs) 305 - { 306 - printk("PSR: %08x PC: %08x NPC: %08x Y: %08x %s\n", regs->psr, 307 - regs->pc, regs->npc, regs->y, print_tainted()); 308 - printk("g0: %08x g1: %08x g2: %08x g3: %08x ", 309 - regs->u_regs[0], regs->u_regs[1], regs->u_regs[2], 310 - regs->u_regs[3]); 311 - printk("g4: %08x g5: %08x g6: %08x g7: %08x\n", 312 - regs->u_regs[4], regs->u_regs[5], regs->u_regs[6], 313 - regs->u_regs[7]); 314 - printk("o0: %08x o1: %08x o2: %08x o3: %08x ", 315 - regs->u_regs[8], regs->u_regs[9], regs->u_regs[10], 316 - regs->u_regs[11]); 317 - printk("o4: %08x o5: %08x sp: %08x ret_pc: %08x\n", 318 - regs->u_regs[12], regs->u_regs[13], regs->u_regs[14], 319 - regs->u_regs[15]); 320 355 } 321 356 322 357 unsigned long thread_saved_pc(struct task_struct *tsk)
+1 -1
arch/sparc64/kernel/smp.c
··· 86 86 87 87 static volatile unsigned long callin_flag = 0; 88 88 89 - void __devinit smp_callin(void) 89 + void __cpuinit smp_callin(void) 90 90 { 91 91 int cpuid = hard_smp_processor_id(); 92 92
+3 -1
arch/sparc64/kernel/trampoline.S
··· 4 4 * Copyright (C) 1997 David S. Miller (davem@caip.rutgers.edu) 5 5 */ 6 6 7 + #include <linux/init.h> 8 + 7 9 #include <asm/head.h> 8 10 #include <asm/asi.h> 9 11 #include <asm/lsu.h> ··· 38 36 tramp_stack: 39 37 .skip TRAMP_STACK_SIZE 40 38 41 - .text 39 + __CPUINIT 42 40 .align 8 43 41 .globl sparc64_cpu_startup, sparc64_cpu_startup_end 44 42 sparc64_cpu_startup:
-2
arch/sparc64/kernel/traps.c
··· 1791 1791 }; 1792 1792 } 1793 1793 1794 - extern void __show_regs(struct pt_regs * regs); 1795 - 1796 1794 static void sun4v_log_error(struct pt_regs *regs, struct sun4v_error_entry *ent, int cpu, const char *pfx, atomic_t *ocnt) 1797 1795 { 1798 1796 int cnt;
+1
include/asm-sparc64/ptrace.h
··· 109 109 #define profile_pc(regs) instruction_pointer(regs) 110 110 #endif 111 111 extern void show_regs(struct pt_regs *); 112 + extern void __show_regs(struct pt_regs *); 112 113 #endif 113 114 114 115 #else /* __ASSEMBLY__ */
+6
include/asm-sparc64/reboot.h
··· 1 + #ifndef _SPARC64_REBOOT_H 2 + #define _SPARC64_REBOOT_H 3 + 4 + extern void machine_alt_power_off(void); 5 + 6 + #endif /* _SPARC64_REBOOT_H */
+13
include/asm-sparc64/syscalls.h
··· 1 + #ifndef _SPARC64_SYSCALLS_H 2 + #define _SPARC64_SYSCALLS_H 3 + 4 + struct pt_regs; 5 + 6 + extern asmlinkage long sparc_do_fork(unsigned long clone_flags, 7 + unsigned long stack_start, 8 + struct pt_regs *regs, 9 + unsigned long stack_size); 10 + 11 + extern asmlinkage int sparc_execve(struct pt_regs *regs); 12 + 13 + #endif /* _SPARC64_SYSCALLS_H */
+1
include/asm-sparc64/system.h
··· 117 117 extern void sun_do_break(void); 118 118 extern int stop_a_enabled; 119 119 120 + extern void fault_in_user_windows(void); 120 121 extern void synchronize_user_stack(void); 121 122 122 123 extern void __flushw_user(void);