diff options
Diffstat (limited to 'arch/sparc')
| -rw-r--r-- | arch/sparc/kernel/pcic.c | 4 | ||||
| -rw-r--r-- | arch/sparc/kernel/process.c | 16 | ||||
| -rw-r--r-- | arch/sparc/kernel/sys_sunos.c | 4 | ||||
| -rw-r--r-- | arch/sparc/kernel/systbls.S | 6 | ||||
| -rw-r--r-- | arch/sparc/kernel/traps.c | 6 | ||||
| -rw-r--r-- | arch/sparc/lib/atomic32.c | 2 | ||||
| -rw-r--r-- | arch/sparc/mm/init.c | 2 |
7 files changed, 23 insertions, 17 deletions
diff --git a/arch/sparc/kernel/pcic.c b/arch/sparc/kernel/pcic.c index 3fa5f95c4614..1c927c538b8b 100644 --- a/arch/sparc/kernel/pcic.c +++ b/arch/sparc/kernel/pcic.c | |||
| @@ -601,7 +601,7 @@ pcic_fill_irq(struct linux_pcic *pcic, struct pci_dev *dev, int node) | |||
| 601 | /* | 601 | /* |
| 602 | * Normally called from {do_}pci_scan_bus... | 602 | * Normally called from {do_}pci_scan_bus... |
| 603 | */ | 603 | */ |
| 604 | void __init pcibios_fixup_bus(struct pci_bus *bus) | 604 | void __devinit pcibios_fixup_bus(struct pci_bus *bus) |
| 605 | { | 605 | { |
| 606 | struct pci_dev *dev; | 606 | struct pci_dev *dev; |
| 607 | int i, has_io, has_mem; | 607 | int i, has_io, has_mem; |
| @@ -842,7 +842,7 @@ static void watchdog_reset() { | |||
| 842 | /* | 842 | /* |
| 843 | * Other archs parse arguments here. | 843 | * Other archs parse arguments here. |
| 844 | */ | 844 | */ |
| 845 | char * __init pcibios_setup(char *str) | 845 | char * __devinit pcibios_setup(char *str) |
| 846 | { | 846 | { |
| 847 | return str; | 847 | return str; |
| 848 | } | 848 | } |
diff --git a/arch/sparc/kernel/process.c b/arch/sparc/kernel/process.c index 113bd48a89bd..fc874e63a499 100644 --- a/arch/sparc/kernel/process.c +++ b/arch/sparc/kernel/process.c | |||
| @@ -348,7 +348,7 @@ void exit_thread(void) | |||
| 348 | #ifndef CONFIG_SMP | 348 | #ifndef CONFIG_SMP |
| 349 | if(last_task_used_math == current) { | 349 | if(last_task_used_math == current) { |
| 350 | #else | 350 | #else |
| 351 | if(current_thread_info()->flags & _TIF_USEDFPU) { | 351 | if (test_thread_flag(TIF_USEDFPU)) { |
| 352 | #endif | 352 | #endif |
| 353 | /* Keep process from leaving FPU in a bogon state. */ | 353 | /* Keep process from leaving FPU in a bogon state. */ |
| 354 | put_psr(get_psr() | PSR_EF); | 354 | put_psr(get_psr() | PSR_EF); |
| @@ -357,7 +357,7 @@ void exit_thread(void) | |||
| 357 | #ifndef CONFIG_SMP | 357 | #ifndef CONFIG_SMP |
| 358 | last_task_used_math = NULL; | 358 | last_task_used_math = NULL; |
| 359 | #else | 359 | #else |
| 360 | current_thread_info()->flags &= ~_TIF_USEDFPU; | 360 | clear_thread_flag(TIF_USEDFPU); |
| 361 | #endif | 361 | #endif |
| 362 | } | 362 | } |
| 363 | } | 363 | } |
| @@ -371,7 +371,7 @@ void flush_thread(void) | |||
| 371 | #ifndef CONFIG_SMP | 371 | #ifndef CONFIG_SMP |
| 372 | if(last_task_used_math == current) { | 372 | if(last_task_used_math == current) { |
| 373 | #else | 373 | #else |
| 374 | if(current_thread_info()->flags & _TIF_USEDFPU) { | 374 | if (test_thread_flag(TIF_USEDFPU)) { |
| 375 | #endif | 375 | #endif |
| 376 | /* Clean the fpu. */ | 376 | /* Clean the fpu. */ |
| 377 | put_psr(get_psr() | PSR_EF); | 377 | put_psr(get_psr() | PSR_EF); |
| @@ -380,7 +380,7 @@ void flush_thread(void) | |||
| 380 | #ifndef CONFIG_SMP | 380 | #ifndef CONFIG_SMP |
| 381 | last_task_used_math = NULL; | 381 | last_task_used_math = NULL; |
| 382 | #else | 382 | #else |
| 383 | current_thread_info()->flags &= ~_TIF_USEDFPU; | 383 | clear_thread_flag(TIF_USEDFPU); |
| 384 | #endif | 384 | #endif |
| 385 | } | 385 | } |
| 386 | 386 | ||
| @@ -466,13 +466,13 @@ int copy_thread(int nr, unsigned long clone_flags, unsigned long sp, | |||
| 466 | #ifndef CONFIG_SMP | 466 | #ifndef CONFIG_SMP |
| 467 | if(last_task_used_math == current) { | 467 | if(last_task_used_math == current) { |
| 468 | #else | 468 | #else |
| 469 | if(current_thread_info()->flags & _TIF_USEDFPU) { | 469 | if (test_thread_flag(TIF_USEDFPU)) { |
| 470 | #endif | 470 | #endif |
| 471 | put_psr(get_psr() | PSR_EF); | 471 | put_psr(get_psr() | PSR_EF); |
| 472 | fpsave(&p->thread.float_regs[0], &p->thread.fsr, | 472 | fpsave(&p->thread.float_regs[0], &p->thread.fsr, |
| 473 | &p->thread.fpqueue[0], &p->thread.fpqdepth); | 473 | &p->thread.fpqueue[0], &p->thread.fpqdepth); |
| 474 | #ifdef CONFIG_SMP | 474 | #ifdef CONFIG_SMP |
| 475 | current_thread_info()->flags &= ~_TIF_USEDFPU; | 475 | clear_thread_flag(TIF_USEDFPU); |
| 476 | #endif | 476 | #endif |
| 477 | } | 477 | } |
| 478 | 478 | ||
| @@ -609,13 +609,13 @@ int dump_fpu (struct pt_regs * regs, elf_fpregset_t * fpregs) | |||
| 609 | return 1; | 609 | return 1; |
| 610 | } | 610 | } |
| 611 | #ifdef CONFIG_SMP | 611 | #ifdef CONFIG_SMP |
| 612 | if (current_thread_info()->flags & _TIF_USEDFPU) { | 612 | if (test_thread_flag(TIF_USEDFPU)) { |
| 613 | put_psr(get_psr() | PSR_EF); | 613 | put_psr(get_psr() | PSR_EF); |
| 614 | fpsave(¤t->thread.float_regs[0], ¤t->thread.fsr, | 614 | fpsave(¤t->thread.float_regs[0], ¤t->thread.fsr, |
| 615 | ¤t->thread.fpqueue[0], ¤t->thread.fpqdepth); | 615 | ¤t->thread.fpqueue[0], ¤t->thread.fpqdepth); |
| 616 | if (regs != NULL) { | 616 | if (regs != NULL) { |
| 617 | regs->psr &= ~(PSR_EF); | 617 | regs->psr &= ~(PSR_EF); |
| 618 | current_thread_info()->flags &= ~(_TIF_USEDFPU); | 618 | clear_thread_flag(TIF_USEDFPU); |
| 619 | } | 619 | } |
| 620 | } | 620 | } |
| 621 | #else | 621 | #else |
diff --git a/arch/sparc/kernel/sys_sunos.c b/arch/sparc/kernel/sys_sunos.c index da6606f0cffc..f807172cab0e 100644 --- a/arch/sparc/kernel/sys_sunos.c +++ b/arch/sparc/kernel/sys_sunos.c | |||
| @@ -910,7 +910,7 @@ asmlinkage long sunos_sysconf (int name) | |||
| 910 | ret = ARG_MAX; | 910 | ret = ARG_MAX; |
| 911 | break; | 911 | break; |
| 912 | case _SC_CHILD_MAX: | 912 | case _SC_CHILD_MAX: |
| 913 | ret = -1; /* no limit */ | 913 | ret = current->signal->rlim[RLIMIT_NPROC].rlim_cur; |
| 914 | break; | 914 | break; |
| 915 | case _SC_CLK_TCK: | 915 | case _SC_CLK_TCK: |
| 916 | ret = HZ; | 916 | ret = HZ; |
| @@ -919,7 +919,7 @@ asmlinkage long sunos_sysconf (int name) | |||
| 919 | ret = NGROUPS_MAX; | 919 | ret = NGROUPS_MAX; |
| 920 | break; | 920 | break; |
| 921 | case _SC_OPEN_MAX: | 921 | case _SC_OPEN_MAX: |
| 922 | ret = OPEN_MAX; | 922 | ret = current->signal->rlim[RLIMIT_NOFILE].rlim_cur; |
| 923 | break; | 923 | break; |
| 924 | case _SC_JOB_CONTROL: | 924 | case _SC_JOB_CONTROL: |
| 925 | ret = 1; /* yes, we do support job control */ | 925 | ret = 1; /* yes, we do support job control */ |
diff --git a/arch/sparc/kernel/systbls.S b/arch/sparc/kernel/systbls.S index ea75ca569052..3a69778c8366 100644 --- a/arch/sparc/kernel/systbls.S +++ b/arch/sparc/kernel/systbls.S | |||
| @@ -78,7 +78,8 @@ sys_call_table: | |||
| 78 | /*285*/ .long sys_mkdirat, sys_mknodat, sys_fchownat, sys_futimesat, sys_fstatat64 | 78 | /*285*/ .long sys_mkdirat, sys_mknodat, sys_fchownat, sys_futimesat, sys_fstatat64 |
| 79 | /*290*/ .long sys_unlinkat, sys_renameat, sys_linkat, sys_symlinkat, sys_readlinkat | 79 | /*290*/ .long sys_unlinkat, sys_renameat, sys_linkat, sys_symlinkat, sys_readlinkat |
| 80 | /*295*/ .long sys_fchmodat, sys_faccessat, sys_pselect6, sys_ppoll, sys_unshare | 80 | /*295*/ .long sys_fchmodat, sys_faccessat, sys_pselect6, sys_ppoll, sys_unshare |
| 81 | /*300*/ .long sys_set_robust_list, sys_get_robust_list, sys_migrate_pages | 81 | /*300*/ .long sys_set_robust_list, sys_get_robust_list, sys_migrate_pages, sys_mbind, sys_get_mempolicy |
| 82 | /*305*/ .long sys_set_mempolicy, sys_kexec_load, sys_move_pages, sys_getcpu, sys_epoll_pwait | ||
| 82 | 83 | ||
| 83 | #ifdef CONFIG_SUNOS_EMUL | 84 | #ifdef CONFIG_SUNOS_EMUL |
| 84 | /* Now the SunOS syscall table. */ | 85 | /* Now the SunOS syscall table. */ |
| @@ -192,5 +193,8 @@ sunos_sys_table: | |||
| 192 | .long sunos_nosys, sunos_nosys, sunos_nosys | 193 | .long sunos_nosys, sunos_nosys, sunos_nosys |
| 193 | .long sunos_nosys | 194 | .long sunos_nosys |
| 194 | /*300*/ .long sunos_nosys, sunos_nosys, sunos_nosys | 195 | /*300*/ .long sunos_nosys, sunos_nosys, sunos_nosys |
| 196 | .long sunos_nosys, sunos_nosys, sunos_nosys | ||
| 197 | .long sunos_nosys, sunos_nosys, sunos_nosys | ||
| 198 | .long sunos_nosys | ||
| 195 | 199 | ||
| 196 | #endif | 200 | #endif |
diff --git a/arch/sparc/kernel/traps.c b/arch/sparc/kernel/traps.c index 6a70d215fd04..527687afc1c4 100644 --- a/arch/sparc/kernel/traps.c +++ b/arch/sparc/kernel/traps.c | |||
| @@ -259,7 +259,7 @@ void do_fpd_trap(struct pt_regs *regs, unsigned long pc, unsigned long npc, | |||
| 259 | } else { | 259 | } else { |
| 260 | fpload(¤t->thread.float_regs[0], ¤t->thread.fsr); | 260 | fpload(¤t->thread.float_regs[0], ¤t->thread.fsr); |
| 261 | } | 261 | } |
| 262 | current_thread_info()->flags |= _TIF_USEDFPU; | 262 | set_thread_flag(TIF_USEDFPU); |
| 263 | #endif | 263 | #endif |
| 264 | } | 264 | } |
| 265 | 265 | ||
| @@ -290,7 +290,7 @@ void do_fpe_trap(struct pt_regs *regs, unsigned long pc, unsigned long npc, | |||
| 290 | #ifndef CONFIG_SMP | 290 | #ifndef CONFIG_SMP |
| 291 | if(!fpt) { | 291 | if(!fpt) { |
| 292 | #else | 292 | #else |
| 293 | if(!(task_thread_info(fpt)->flags & _TIF_USEDFPU)) { | 293 | if (!test_tsk_thread_flag(fpt, TIF_USEDFPU)) { |
| 294 | #endif | 294 | #endif |
| 295 | fpsave(&fake_regs[0], &fake_fsr, &fake_queue[0], &fake_depth); | 295 | fpsave(&fake_regs[0], &fake_fsr, &fake_queue[0], &fake_depth); |
| 296 | regs->psr &= ~PSR_EF; | 296 | regs->psr &= ~PSR_EF; |
| @@ -333,7 +333,7 @@ void do_fpe_trap(struct pt_regs *regs, unsigned long pc, unsigned long npc, | |||
| 333 | /* nope, better SIGFPE the offending process... */ | 333 | /* nope, better SIGFPE the offending process... */ |
| 334 | 334 | ||
| 335 | #ifdef CONFIG_SMP | 335 | #ifdef CONFIG_SMP |
| 336 | task_thread_info(fpt)->flags &= ~_TIF_USEDFPU; | 336 | clear_tsk_thread_flag(fpt, TIF_USEDFPU); |
| 337 | #endif | 337 | #endif |
| 338 | if(psr & PSR_PS) { | 338 | if(psr & PSR_PS) { |
| 339 | /* The first fsr store/load we tried trapped, | 339 | /* The first fsr store/load we tried trapped, |
diff --git a/arch/sparc/lib/atomic32.c b/arch/sparc/lib/atomic32.c index 53ddcd9d1e60..559335f4917d 100644 --- a/arch/sparc/lib/atomic32.c +++ b/arch/sparc/lib/atomic32.c | |||
| @@ -52,6 +52,7 @@ int atomic_cmpxchg(atomic_t *v, int old, int new) | |||
| 52 | spin_unlock_irqrestore(ATOMIC_HASH(v), flags); | 52 | spin_unlock_irqrestore(ATOMIC_HASH(v), flags); |
| 53 | return ret; | 53 | return ret; |
| 54 | } | 54 | } |
| 55 | EXPORT_SYMBOL(atomic_cmpxchg); | ||
| 55 | 56 | ||
| 56 | int atomic_add_unless(atomic_t *v, int a, int u) | 57 | int atomic_add_unless(atomic_t *v, int a, int u) |
| 57 | { | 58 | { |
| @@ -65,6 +66,7 @@ int atomic_add_unless(atomic_t *v, int a, int u) | |||
| 65 | spin_unlock_irqrestore(ATOMIC_HASH(v), flags); | 66 | spin_unlock_irqrestore(ATOMIC_HASH(v), flags); |
| 66 | return ret != u; | 67 | return ret != u; |
| 67 | } | 68 | } |
| 69 | EXPORT_SYMBOL(atomic_add_unless); | ||
| 68 | 70 | ||
| 69 | /* Atomic operations are already serializing */ | 71 | /* Atomic operations are already serializing */ |
| 70 | void atomic_set(atomic_t *v, int i) | 72 | void atomic_set(atomic_t *v, int i) |
diff --git a/arch/sparc/mm/init.c b/arch/sparc/mm/init.c index c85ddf312747..a532922e2e35 100644 --- a/arch/sparc/mm/init.c +++ b/arch/sparc/mm/init.c | |||
| @@ -75,7 +75,7 @@ void show_mem(void) | |||
| 75 | printk("Free swap: %6ldkB\n", | 75 | printk("Free swap: %6ldkB\n", |
| 76 | nr_swap_pages << (PAGE_SHIFT-10)); | 76 | nr_swap_pages << (PAGE_SHIFT-10)); |
| 77 | printk("%ld pages of RAM\n", totalram_pages); | 77 | printk("%ld pages of RAM\n", totalram_pages); |
| 78 | printk("%d free pages\n", nr_free_pages()); | 78 | printk("%ld free pages\n", nr_free_pages()); |
| 79 | #if 0 /* undefined pgtable_cache_size, pgd_cache_size */ | 79 | #if 0 /* undefined pgtable_cache_size, pgd_cache_size */ |
| 80 | printk("%ld pages in page table cache\n",pgtable_cache_size); | 80 | printk("%ld pages in page table cache\n",pgtable_cache_size); |
| 81 | #ifndef CONFIG_SMP | 81 | #ifndef CONFIG_SMP |
