From: Linus Torvalds Date: Wed, 21 Aug 2013 23:38:33 +0000 (-0700) Subject: Merge tag 'stable/for-linus-3.11-rc6-tag' of git://git.kernel.org/pub/scm/linux/kerne... X-Git-Tag: upstream/snapshot3+hdmi~4526 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d936d2d452ca1848cc4b397bdfb96d4278b9f934;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git Merge tag 'stable/for-linus-3.11-rc6-tag' of git://git./linux/kernel/git/xen/tip Pull Xen bug-fixes from Konrad Rzeszutek Wilk: - On ARM did not have balanced calls to get/put_cpu. - Fix to make tboot + Xen + Linux correctly. - Fix events VCPU binding issues. - Fix a vCPU online race where IPIs are sent to not-yet-online vCPU. * tag 'stable/for-linus-3.11-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip: xen/smp: initialize IPI vectors before marking CPU online xen/events: mask events when changing their VCPU binding xen/events: initialize local per-cpu mask for all possible events x86/xen: do not identity map UNUSABLE regions in the machine E820 xen/arm: missing put_cpu in xen_percpu_init --- d936d2d452ca1848cc4b397bdfb96d4278b9f934 diff --cc arch/arm/xen/enlighten.c index c9770ba,05db95d..8a6295c --- a/arch/arm/xen/enlighten.c +++ b/arch/arm/xen/enlighten.c @@@ -170,9 -170,10 +170,10 @@@ static void __init xen_percpu_init(voi per_cpu(xen_vcpu, cpu) = vcpup; enable_percpu_irq(xen_events_irq, 0); + put_cpu(); } -static void xen_restart(char str, const char *cmd) +static void xen_restart(enum reboot_mode reboot_mode, const char *cmd) { struct sched_shutdown r = { .reason = SHUTDOWN_reboot }; int rc; diff --cc arch/x86/xen/smp.c index ca92754,34ed6ed..b81c88e --- a/arch/x86/xen/smp.c +++ b/arch/x86/xen/smp.c @@@ -691,11 -683,18 +691,18 @@@ static void __init xen_hvm_smp_prepare_ xen_init_lock_cpu(0); } -static int __cpuinit xen_hvm_cpu_up(unsigned int cpu, struct task_struct *tidle) +static int xen_hvm_cpu_up(unsigned int cpu, struct task_struct *tidle) { int rc; - rc = native_cpu_up(cpu, tidle); - WARN_ON (xen_smp_intr_init(cpu)); + /* + * xen_smp_intr_init() needs to run before native_cpu_up() + * so that IPI vectors are set up on the booting CPU before + * it is marked online in native_cpu_up(). + */ + rc = xen_smp_intr_init(cpu); + WARN_ON(rc); + if (!rc) + rc = native_cpu_up(cpu, tidle); return rc; }