public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: Keshavamurthy Anil S <anil.s.keshavamurthy@intel.com>
To: linux-ia64@vger.kernel.org
Subject: [PATCH] Online CPU with maxcpus option panics
Date: Sat, 11 Sep 2004 00:14:06 +0000	[thread overview]
Message-ID: <20040910171405.A28196@unix-os.sc.intel.com> (raw)

Hi Andrew,
	I booted IA64 kernel with "maxcpus=" set to less than
the total available processors in the system. Then I tried
to online the CPU which was offline due to "maxcpus=" restirction.
i.e  when I tried to online the CPU which never was online at boot
crashed the system.

Attached patch fixes the problem.

Please apply.

Signed-off-by: Anil Keshavamurthy <anil.s.keshavamurthy@intel.com>

---

 linux-2.6.9-rc1-mm2-askeshav/arch/ia64/kernel/smpboot.c |    2 +-
 linux-2.6.9-rc1-mm2-askeshav/kernel/fork.c              |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff -puN arch/ia64/kernel/smpboot.c~maxcpufix arch/ia64/kernel/smpboot.c
--- linux-2.6.9-rc1-mm2/arch/ia64/kernel/smpboot.c~maxcpufix	2004-09-09 16:30:01.497896672 -0700
+++ linux-2.6.9-rc1-mm2-askeshav/arch/ia64/kernel/smpboot.c	2004-09-09 16:33:21.626800471 -0700
@@ -356,7 +356,7 @@ start_secondary (void *unused)
 	return cpu_idle();
 }
 
-struct pt_regs * __init idle_regs(struct pt_regs *regs)
+struct pt_regs * __devinit idle_regs(struct pt_regs *regs)
 {
 	return NULL;
 }
diff -puN kernel/fork.c~maxcpufix kernel/fork.c
--- linux-2.6.9-rc1-mm2/kernel/fork.c~maxcpufix	2004-09-09 16:30:17.358248041 -0700
+++ linux-2.6.9-rc1-mm2-askeshav/kernel/fork.c	2004-09-09 16:31:17.844575425 -0700
@@ -1069,13 +1069,13 @@ bad_fork_free:
 	goto fork_out;
 }
 
-struct pt_regs * __init __attribute__((weak)) idle_regs(struct pt_regs *regs)
+struct pt_regs * __devinit __attribute__((weak)) idle_regs(struct pt_regs *regs)
 {
 	memset(regs, 0, sizeof(struct pt_regs));
 	return regs;
 }
 
-task_t * __init fork_idle(int cpu)
+task_t * __devinit fork_idle(int cpu)
 {
 	task_t *task;
 	struct pt_regs regs;
_

                 reply	other threads:[~2004-09-11  0:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20040910171405.A28196@unix-os.sc.intel.com \
    --to=anil.s.keshavamurthy@intel.com \
    --cc=linux-ia64@vger.kernel.org \
    /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