diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-05-21 22:43:57 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-05-21 22:43:57 -0400 |
| commit | bf67f3a5c456a18f2e8d062f7e88506ef2cd9837 (patch) | |
| tree | 2a2324b2572162059307db82f9238eeb25673a77 /arch/alpha/kernel | |
| parent | 226da0dbc84ed97f448523e2a4cb91c27fa68ed9 (diff) | |
| parent | 203dacbdca977bedaba61ad2fca75d934060a5d5 (diff) | |
Merge branch 'smp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull smp hotplug cleanups from Thomas Gleixner:
"This series is merily a cleanup of code copied around in arch/* and
not changing any of the real cpu hotplug horrors yet. I wish I'd had
something more substantial for 3.5, but I underestimated the lurking
horror..."
Fix up trivial conflicts in arch/{arm,sparc,x86}/Kconfig and
arch/sparc/include/asm/thread_info_32.h
* 'smp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (79 commits)
um: Remove leftover declaration of alloc_task_struct_node()
task_allocator: Use config switches instead of magic defines
sparc: Use common threadinfo allocator
score: Use common threadinfo allocator
sh-use-common-threadinfo-allocator
mn10300: Use common threadinfo allocator
powerpc: Use common threadinfo allocator
mips: Use common threadinfo allocator
hexagon: Use common threadinfo allocator
m32r: Use common threadinfo allocator
frv: Use common threadinfo allocator
cris: Use common threadinfo allocator
x86: Use common threadinfo allocator
c6x: Use common threadinfo allocator
fork: Provide kmemcache based thread_info allocator
tile: Use common threadinfo allocator
fork: Provide weak arch_release_[task_struct|thread_info] functions
fork: Move thread info gfp flags to header
fork: Remove the weak insanity
sh: Remove cpu_idle_wait()
...
Diffstat (limited to 'arch/alpha/kernel')
| -rw-r--r-- | arch/alpha/kernel/Makefile | 2 | ||||
| -rw-r--r-- | arch/alpha/kernel/init_task.c | 17 | ||||
| -rw-r--r-- | arch/alpha/kernel/smp.c | 20 |
3 files changed, 4 insertions, 35 deletions
diff --git a/arch/alpha/kernel/Makefile b/arch/alpha/kernel/Makefile index 7a6d908bb86..84ec46b38f7 100644 --- a/arch/alpha/kernel/Makefile +++ b/arch/alpha/kernel/Makefile | |||
| @@ -6,7 +6,7 @@ extra-y := head.o vmlinux.lds | |||
| 6 | asflags-y := $(KBUILD_CFLAGS) | 6 | asflags-y := $(KBUILD_CFLAGS) |
| 7 | ccflags-y := -Wno-sign-compare | 7 | ccflags-y := -Wno-sign-compare |
| 8 | 8 | ||
| 9 | obj-y := entry.o traps.o process.o init_task.o osf_sys.o irq.o \ | 9 | obj-y := entry.o traps.o process.o osf_sys.o irq.o \ |
| 10 | irq_alpha.o signal.o setup.o ptrace.o time.o \ | 10 | irq_alpha.o signal.o setup.o ptrace.o time.o \ |
| 11 | alpha_ksyms.o systbls.o err_common.o io.o | 11 | alpha_ksyms.o systbls.o err_common.o io.o |
| 12 | 12 | ||
diff --git a/arch/alpha/kernel/init_task.c b/arch/alpha/kernel/init_task.c deleted file mode 100644 index 6f80ca4f976..00000000000 --- a/arch/alpha/kernel/init_task.c +++ /dev/null | |||
| @@ -1,17 +0,0 @@ | |||
| 1 | #include <linux/mm.h> | ||
| 2 | #include <linux/module.h> | ||
| 3 | #include <linux/sched.h> | ||
| 4 | #include <linux/init.h> | ||
| 5 | #include <linux/init_task.h> | ||
| 6 | #include <linux/fs.h> | ||
| 7 | #include <linux/mqueue.h> | ||
| 8 | #include <asm/uaccess.h> | ||
| 9 | |||
| 10 | |||
| 11 | static struct signal_struct init_signals = INIT_SIGNALS(init_signals); | ||
| 12 | static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand); | ||
| 13 | struct task_struct init_task = INIT_TASK(init_task); | ||
| 14 | EXPORT_SYMBOL(init_task); | ||
| 15 | |||
| 16 | union thread_union init_thread_union __init_task_data = | ||
| 17 | { INIT_THREAD_INFO(init_task) }; | ||
diff --git a/arch/alpha/kernel/smp.c b/arch/alpha/kernel/smp.c index 50d438db1f6..35ddc02bfa4 100644 --- a/arch/alpha/kernel/smp.c +++ b/arch/alpha/kernel/smp.c | |||
| @@ -357,24 +357,10 @@ secondary_cpu_start(int cpuid, struct task_struct *idle) | |||
| 357 | * Bring one cpu online. | 357 | * Bring one cpu online. |
| 358 | */ | 358 | */ |
| 359 | static int __cpuinit | 359 | static int __cpuinit |
| 360 | smp_boot_one_cpu(int cpuid) | 360 | smp_boot_one_cpu(int cpuid, struct task_struct *idle) |
| 361 | { | 361 | { |
| 362 | struct task_struct *idle; | ||
| 363 | unsigned long timeout; | 362 | unsigned long timeout; |
| 364 | 363 | ||
| 365 | /* Cook up an idler for this guy. Note that the address we | ||
| 366 | give to kernel_thread is irrelevant -- it's going to start | ||
| 367 | where HWRPB.CPU_restart says to start. But this gets all | ||
| 368 | the other task-y sort of data structures set up like we | ||
| 369 | wish. We can't use kernel_thread since we must avoid | ||
| 370 | rescheduling the child. */ | ||
| 371 | idle = fork_idle(cpuid); | ||
| 372 | if (IS_ERR(idle)) | ||
| 373 | panic("failed fork for CPU %d", cpuid); | ||
| 374 | |||
| 375 | DBGS(("smp_boot_one_cpu: CPU %d state 0x%lx flags 0x%lx\n", | ||
| 376 | cpuid, idle->state, idle->flags)); | ||
| 377 | |||
| 378 | /* Signal the secondary to wait a moment. */ | 364 | /* Signal the secondary to wait a moment. */ |
| 379 | smp_secondary_alive = -1; | 365 | smp_secondary_alive = -1; |
| 380 | 366 | ||
| @@ -487,9 +473,9 @@ smp_prepare_boot_cpu(void) | |||
| 487 | } | 473 | } |
| 488 | 474 | ||
| 489 | int __cpuinit | 475 | int __cpuinit |
| 490 | __cpu_up(unsigned int cpu) | 476 | __cpu_up(unsigned int cpu, struct task_struct *tidle) |
| 491 | { | 477 | { |
| 492 | smp_boot_one_cpu(cpu); | 478 | smp_boot_one_cpu(cpu, tidle); |
| 493 | 479 | ||
| 494 | return cpu_online(cpu) ? 0 : -ENOSYS; | 480 | return cpu_online(cpu) ? 0 : -ENOSYS; |
| 495 | } | 481 | } |
