From: Vivek Goyal <vgoyal@in.ibm.com>
To: Andi Kleen <ak@suse.de>
Cc: vgoyal@in.ibm.com, Stephen Hemminger <shemminger@osdl.org>,
linux-kernel@vger.kernel.org
Subject: Re: Crash with SMP on post 2.6.15 -git kernel
Date: Wed, 11 Jan 2006 19:12:30 +0530 [thread overview]
Message-ID: <20060111134230.GE4990@in.ibm.com> (raw)
In-Reply-To: <200601111212.40989.ak@suse.de>
On Wed, Jan 11, 2006 at 12:12:40PM +0100, Andi Kleen wrote:
> On Wednesday 11 January 2006 10:32, Vivek Goyal wrote:
>
> > Few x86_64 APIC related kexec changes are still in Andi's tree and have not
> > been pushed to Linus tree. So there are no new x86_64 kexec patches in latest
> > git repository.
> >
> > Andrew has pushed x86_64 kdump related patches to Linus tree. And these become
> > effective only under CONFIG_CRASH_DUMP. These patches are very less likely
> > to botch with this stuff.
>
> Yes, it was only a very quick look through the change log. Sorry for
> hitting on you. I have no clue what could have broken. And my machines boot
> too with -git7 and his config.
>
> Stephen, can you please do a binary search?
>
Andi,
While testing this I ran into another problem with same symtoms. If
I compile my kernel for physical location greater than or equal to
16MB then only BP boots and applicatoin processors don't come up. I had
noticed this problem in i386 and posted a patch. Here is the similar patch
for x86_64.
Though the symtoms are same but this does not seem to be related to the
problem which Stephen is facing as he seems to be compiling the kernel
for 1MB location only.
Thanks
Vivek
o This fix was posted for i386 long back. Posting it for x86_64.
http://marc.theaimsgroup.com/?l=linux-kernel&m=110380103229830&w=2
o This patch fixes the problem of secondary cpus boot up. This situation
is faced when kernel is built for non default locations like 16MB and
onwards. In this configuration, only primary cpu (BP) comes and
secondary cpus don't boot.
o Problem occurs because in trampoline code, lgdt is not able to load the
GDT as it happens to be situated beyond 16MB. This is due to the fact
that cpu is still in real mode and default operand size is 16bit.
o This patch uses lgdtl instead of lgdt to force operand size to 32
instead of 16.
Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com>
---
diff -puN arch/x86_64/kernel/trampoline.S~x86_64-non-default-location-smp-kernel-boot-fix arch/x86_64/kernel/trampoline.S
--- linux-2.6.15-git7/arch/x86_64/kernel/trampoline.S~x86_64-non-default-location-smp-kernel-boot-fix 2006-01-11 10:32:30.000000000 -0800
+++ linux-2.6.15-git7-root/arch/x86_64/kernel/trampoline.S 2006-01-11 10:34:42.000000000 -0800
@@ -42,8 +42,15 @@ r_base = .
movl $0xA5A5A5A5, trampoline_data - r_base
# write marker for master knows we're running
- lidt idt_48 - r_base # load idt with 0, 0
- lgdt gdt_48 - r_base # load gdt with whatever is appropriate
+ /*
+ * GDT tables in non default location kernel can be beyond 16MB and
+ * lgdt will not be able to load the address as in real mode default
+ * operand size is 16bit. Use lgdtl instead to force operand size
+ * to 32 bit.
+ */
+
+ lidtl idt_48 - r_base # load idt with 0, 0
+ lgdtl gdt_48 - r_base # load gdt with whatever is appropriate
xor %ax, %ax
inc %ax # protected mode (PE) bit
_
next prev parent reply other threads:[~2006-01-11 13:42 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-11 0:54 Crash with SMP on post 2.6.15 -git kernel Stephen Hemminger
2006-01-11 1:27 ` Andi Kleen
2006-01-11 2:49 ` Stephen Hemminger
2006-01-11 9:32 ` Vivek Goyal
2006-01-11 11:12 ` Andi Kleen
2006-01-11 13:42 ` Vivek Goyal [this message]
2006-01-11 13:50 ` Andi Kleen
2006-01-11 14:03 ` Vivek Goyal
2006-01-12 0:05 ` Stephen Hemminger
2006-01-12 0:12 ` Andi Kleen
2006-01-11 22:57 ` Stephen Hemminger
2006-01-11 23:36 ` Andi Kleen
2006-01-11 23:44 ` Stephen Hemminger
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=20060111134230.GE4990@in.ibm.com \
--to=vgoyal@in.ibm.com \
--cc=ak@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=shemminger@osdl.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