mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Suresh Siddha <suresh.b.siddha@intel.com>
To: "H. Peter Anvin" <hpa@zytor.com>, Ingo Molnar <mingo@elte.hu>,
	Thomas Gleixner <tglx@linutronix.de>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Suresh Siddha <suresh.b.siddha@intel.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Zhang Rui <rui.zhang@intel.com>
Subject: [patch 2/2] x86, smp: use workqueues unconditionally during do_boot_cpu()
Date: Fri, 30 Jul 2010 14:57:38 -0700	[thread overview]
Message-ID: <20100730215751.783526464@sbsiddha-MOBL3.sc.intel.com> (raw)
In-Reply-To: <20100730215751.690706748@sbsiddha-MOBL3.sc.intel.com>

[-- Attachment #1: x86_smpboot_cleanup.patch --]
[-- Type: text/plain, Size: 1083 bytes --]

Workqueues are now initialized as part of the early_initcall(). So
they are available for use during cold boot process aswell.

And also ACPI hotplug notifier no longer calls do_boot_cpu() in the keventd_wq
context.  So we can unconditionally use workqueues in do_boot_cpu()

Signed-off-by: Suresh Siddha <suresh.b.siddha@intel.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Zhang Rui <rui.zhang@intel.com>
---
 arch/x86/kernel/smpboot.c |    8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

Index: tip/arch/x86/kernel/smpboot.c
===================================================================
--- tip.orig/arch/x86/kernel/smpboot.c
+++ tip/arch/x86/kernel/smpboot.c
@@ -735,12 +735,8 @@ static int __cpuinit do_boot_cpu(int api
 		goto do_rest;
 	}
 
-	if (!keventd_up() || current_is_keventd())
-		c_idle.work.func(&c_idle.work);
-	else {
-		schedule_work(&c_idle.work);
-		wait_for_completion(&c_idle.done);
-	}
+	schedule_work(&c_idle.work);
+	wait_for_completion(&c_idle.done);
 
 	if (IS_ERR(c_idle.idle)) {
 		printk("failed fork for CPU %d\n", cpu);



  reply	other threads:[~2010-07-30 22:00 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-30 21:57 [patch 1/2] workqueue: mark init_workqueues() as early_initcall() Suresh Siddha
2010-07-30 21:57 ` Suresh Siddha [this message]
2010-07-30 23:55 ` Andrew Morton
2010-07-31  0:48   ` Suresh Siddha
2010-07-31 10:29     ` Tejun Heo
2010-07-31 10:27   ` Tejun Heo
2010-08-01  9:54   ` [PATCH wq#for-next] workqueue: explain for_each_*cwq_cpu() iterators Tejun Heo
2010-08-01 11:07 ` [PATCH] workqueue: mark init_workqueues() as early_initcall() Tejun Heo
2010-08-02 18:41   ` Suresh Siddha
2010-08-04 13:43     ` Tejun Heo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100730215751.783526464@sbsiddha-MOBL3.sc.intel.com \
    --to=suresh.b.siddha@intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=rui.zhang@intel.com \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®