From: Jeremy Fitzhardinge <jeremy@goop.org>
To: Andrew Morton <akpm@osdl.org>
Cc: Andi Kleen <ak@suse.de>, Ingo Molnar <mingo@elte.hu>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] i386-pda: Initialize the PDA early, before any C code runs.
Date: Mon, 11 Sep 2006 16:37:34 -0700 [thread overview]
Message-ID: <4505F33E.3020009@goop.org> (raw)
In-Reply-To: <4505F212.4040307@goop.org>
Jeremy Fitzhardinge wrote:
> Not sure, but I think this replicates the behaviour of the original
> code (ie, INIT_THREAD_INFO initializes cpu to 0, so smp_processor_id
> will return 0). Hm, Voyager will probably need a little patch to
> update the the PDA cpu_number properly in smp_setup_processor_id().
Something like this, perhaps:
Subject: set the boot CPU number in the boot_pda
Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com>
diff -r 97aa2356d521 arch/i386/mach-voyager/voyager_smp.c
--- a/arch/i386/mach-voyager/voyager_smp.c Mon Sep 11 14:52:11 2006 -0700
+++ b/arch/i386/mach-voyager/voyager_smp.c Mon Sep 11 16:34:09 2006 -0700
@@ -28,6 +28,7 @@
#include <asm/pgalloc.h>
#include <asm/tlbflush.h>
#include <asm/arch_hooks.h>
+#include <asm/pda.h>
/* TLB state -- visible externally, indexed physically */
DEFINE_PER_CPU(struct tlb_state, cpu_tlbstate) ____cacheline_aligned = { &init_mm, 0 };
@@ -1949,4 +1950,5 @@ smp_setup_processor_id(void)
smp_setup_processor_id(void)
{
current_thread_info()->cpu = hard_smp_processor_id();
-}
+ write_pda(cpu_number, hard_smp_processor_id());
+}
next prev parent reply other threads:[~2006-09-11 23:37 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-09-11 22:52 [PATCH] i386-pda: Initialize the PDA early, before any C code runs Jeremy Fitzhardinge
2006-09-11 23:03 ` Andrew Morton
2006-09-11 23:32 ` Jeremy Fitzhardinge
2006-09-11 23:37 ` Jeremy Fitzhardinge [this message]
2006-09-12 5:57 ` Ingo Molnar
2006-09-12 5:51 ` Ingo Molnar
2006-09-12 6:44 ` Andi Kleen
2006-09-12 8:32 ` Jeremy Fitzhardinge
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=4505F33E.3020009@goop.org \
--to=jeremy@goop.org \
--cc=ak@suse.de \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
/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