From: Yinghai Lu <yinghai@kernel.org>
To: Ingo Molnar <mingo@elte.hu>
Cc: mingo@redhat.com, hpa@zytor.com, linux-kernel@vger.kernel.org,
gorcunov@openvz.org, tglx@linutronix.de,
eswierk@aristanetworks.com, linux-tip-commits@vger.kernel.org
Subject: Re: [tip:x86/apic] x86: read apic ID in the !acpi_lapic case
Date: Mon, 11 May 2009 09:11:36 -0700 [thread overview]
Message-ID: <4A084E38.2050107@kernel.org> (raw)
In-Reply-To: <20090511110234.GH4648@elte.hu>
Ingo Molnar wrote:
> * tip-bot for Yinghai Lu <yinghai@kernel.org> wrote:
>
>> Commit-ID: 4401da6111ac58f94234417427d06a72c4048c74
>> Gitweb: http://git.kernel.org/tip/4401da6111ac58f94234417427d06a72c4048c74
>> Author: Yinghai Lu <yinghai@kernel.org>
>> AuthorDate: Sat, 2 May 2009 10:40:57 -0700
>> Committer: Ingo Molnar <mingo@elte.hu>
>> CommitDate: Mon, 11 May 2009 11:29:23 +0200
>>
>> x86: read apic ID in the !acpi_lapic case
>>
>> Ed found that on 32-bit, boot_cpu_physical_apicid is not read right,
>> when the mptable is broken.
>
> -tip testing found that this patch causes a kernel crash:
>
> [ 1.208000] initcall pci_iommu_init+0x0/0x11 returned 0 after 0 usecs
> [ 1.212000] calling print_all_ICs+0x0/0x62a @ 1
> [ 1.216000]
> [ 1.216000] printing PIC contents
> [ 1.220000] ... PIC IMR: fffa
> [ 1.220000] ... PIC IRR: 0000
> [ 1.224000] ... PIC ISR: 0000
> [ 1.228000] ... PIC ELCR: 0828
> [ 1.232000] BUG: unable to handle kernel paging request at ffffb020
> [ 1.232000] IP: [<78417d5c>] native_apic_mem_read+0x15/0x19
> [ 1.232000] *pde = 010ef067 *pte = 00000000
> [ 1.232000] Oops: 0000 [#1] PREEMPT
> [ 1.232000] last sysfs file:
> [ 1.232000] Modules linked in:
> [ 1.232000]
> [ 1.232000] Pid: 1, comm: swapper Not tainted (2.6.30-rc5-tip #40847) System Product Name
> [ 1.232000] EIP: 0060:[<78417d5c>] EFLAGS: 00010046 CPU: 0
> [ 1.232000] EIP is at native_apic_mem_read+0x15/0x19
> [ 1.232000] EAX: ffffb020 EBX: 00000000 ECX: 00000000 EDX: fffff000
> [ 1.232000] ESI: 00000000 EDI: 7908c52e EBP: 9786fd38 ESP: 9786fd38
> [ 1.232000] DS: 007b ES: 007b FS: 0000 GS: 00e0 SS: 0068
> [ 1.232000] Process swapper (pid: 1, ti=9786e000 task=97870000 task.ti=9786e000)
> [ 1.232000] Stack:
> [ 1.232000] 9786fd40 78416e0d 9786fd48 78416fad 9786fd64 7908c55f 00000001 00000000
> [ 1.232000] 00000000 00000000 7908c52e 9786fd78 784671bf 00000001 00000000 00000000
> [ 1.232000] 9786fdac 7908ca42 00000001 9786fda0 784551ad 00000001 00000000 487ab0fc
> [ 1.232000] Call Trace:
> [ 1.232000] [<78416e0d>] ? read_apic_id+0x19/0x24
> [ 1.232000] [<78416fad>] ? hard_smp_processor_id+0xd/0xf
> [ 1.232000] [<7908c55f>] ? print_local_APIC+0x31/0x3c7
> [ 1.232000] [<7908c52e>] ? print_local_APIC+0x0/0x3c7
> [ 1.232000] [<784671bf>] ? smp_call_function_single+0x5b/0x64
> [ 1.232000] [<7908ca42>] ? print_all_ICs+0x14d/0x62a
> [ 1.232000] [<784551ad>] ? ktime_get+0x16/0x34
> [ 1.232000] [<7908c8f5>] ? print_all_ICs+0x0/0x62a
> [ 1.232000] [<7908c8f5>] ? print_all_ICs+0x0/0x62a
> [ 1.232000] [<7840107f>] ? _stext+0x7f/0x1f2
> [ 1.232000] [<786c2658>] ? put_dec+0x44/0x137
> [ 1.232000] [<784afae4>] ? page_count+0x22/0x3f
> [ 1.232000] [<784b1c0a>] ? get_page_from_freelist+0x51f/0x6b0
> [ 1.232000] [<786c2658>] ? put_dec+0x44/0x137
> [ 1.232000] [<784dcbee>] ? check_object+0x207/0x252
> [ 1.232000] [<786bb54f>] ? ida_get_new_above+0x2b0/0x2ca
> [ 1.232000] [<784dd5c5>] ? __slab_free+0x11a/0x4af
> [ 1.232000] [<784df012>] ? kmem_cache_free+0xce/0x163
> [ 1.232000] [<786bb54f>] ? ida_get_new_above+0x2b0/0x2ca
> [ 1.232000] [<786bb54f>] ? ida_get_new_above+0x2b0/0x2ca
> [ 1.232000] [<786bb75f>] ? ida_pre_get+0x13/0x18b
> [ 1.232000] [<7853f384>] ? proc_register+0x32a/0x34e
> [ 1.232000] [<7853f5bd>] ? create_proc_entry+0xf0/0x119
> [ 1.232000] [<7847e0bc>] ? register_irq_proc+0x87/0xbb
> [ 1.232000] [<7908251b>] ? kernel_init+0x8d/0x10a
> [ 1.232000] [<7908248e>] ? kernel_init+0x0/0x10a
> [ 1.232000] [<78403ee7>] ? kernel_thread_helper+0x7/0x10
> [ 1.232000] Code: 44 00 00 89 d1 8b 15 08 8b de 78 8d 84 10 00 c0 ff ff 89 08 5d c3 55 89 e5 0f 1f 44 00 00 8b 15 08 8b de 78 8d 84 10 00 c0 ff ff <8b> 00 5d c3 55 89 e5 0f 1f 44 00 00 89 c2 eb 02 f3 90 8b 02 85
> [ 1.232000] EIP: [<78417d5c>] native_apic_mem_read+0x15/0x19 SS:ESP 0068:9786fd38
> [ 1.232000] CR2: 00000000ffffb020
> [ 1.232000] ---[ end trace a7919e7f17c0a725 ]---
> [ 1.232000] Kernel panic - not syncing: Fatal exception
>
> Ingo
>
> [ 0.000000] Linux version 2.6.30-rc5-tip (mingo@sirius) (gcc version 4.3.2 20081105 (Red Hat 4.3.2-7) (GCC) ) #40847 PREEMPT Mon May 11 12:34:41 CEST 2009
> [ 0.000000] KERNEL supported cpus:
> [ 0.000000] Intel GenuineIntel
> [ 0.000000] NSC Geode by NSC
> [ 0.000000] Cyrix CyrixInstead
> [ 0.000000] Centaur CentaurHauls
> [ 0.000000] Transmeta GenuineTMx86
> [ 0.000000] Transmeta TransmetaCPU
> [ 0.000000] UMC UMC UMC UMC
> [ 0.000000] CPU: vendor_id 'AuthenticAMD' unknown, using generic init.
> [ 0.000000] CPU: Your system may be unstable.
> [ 0.000000] BIOS-provided physical RAM map:
> [ 0.000000] BIOS-e820: 0000000000000000 - 000000000009f800 (usable)
> [ 0.000000] BIOS-e820: 000000000009f800 - 00000000000a0000 (reserved)
> [ 0.000000] BIOS-e820: 00000000000f0000 - 0000000000100000 (reserved)
> [ 0.000000] BIOS-e820: 0000000000100000 - 000000003fff0000 (usable)
> [ 0.000000] BIOS-e820: 000000003fff0000 - 000000003fff3000 (ACPI NVS)
> [ 0.000000] BIOS-e820: 000000003fff3000 - 0000000040000000 (ACPI data)
> [ 0.000000] BIOS-e820: 00000000e0000000 - 00000000f0000000 (reserved)
> [ 0.000000] BIOS-e820: 00000000fec00000 - 0000000100000000 (reserved)
> [ 0.000000] console [earlyser0] enabled
> [ 0.000000] debug: ignoring loglevel setting.
> [ 0.000000] MPS support code is not built-in.
> [ 0.000000] Using acpi=off or acpi=noirq or pci=noacpi may have problem
...
> [ 0.000000] Using APIC driver default
> [ 0.000000] Nvidia board detected. Ignoring ACPI timer override.
> [ 0.000000] If you got timer trouble try acpi_use_timer_override
> [ 0.000000] APIC: disable apic facility
> [ 0.000000] nr_irqs_gsi: 16
> [ 0.000000] Allocating PCI resources starting at 40000000 (gap: 40000000:a0000000)
> [ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 259967
> [ 0.000000] Kernel command line: root=/dev/sda1 earlyprintk=serial,ttyS0,115200,keep console=tty debug initcall_debug enforcing=0 apic=verbose ignore_loglevel sysrq_always_enabled selinux=0 nmi_watchdog=0 3 panic=1 maxcpus=1 nosmp noapic idle=mwait highmem=512m notsc acpi=off
...
> [ 1.212000] calling print_all_ICs+0x0/0x62a @ 1
> [ 1.216000]
> [ 1.216000] printing PIC contents
> [ 1.220000] ... PIC IMR: fffa
> [ 1.220000] ... PIC IRR: 0000
> [ 1.224000] ... PIC ISR: 0000
> [ 1.228000] ... PIC ELCR: 0828
> [ 1.232000] BUG: unable to handle kernel paging request at ffffb020
> [ 1.232000] IP: [<78417d5c>] native_apic_mem_read+0x15/0x19
> [ 1.232000] *pde = 010ef067 *pte = 00000000
> [ 1.232000] Oops: 0000 [#1] PREEMPT
> [ 1.232000] last sysfs file:
> [ 1.232000] Modules linked in:
> [ 1.232000]
> [ 1.232000] Pid: 1, comm: swapper Not tainted (2.6.30-rc5-tip #40847) System Product Name
> [ 1.232000] EIP: 0060:[<78417d5c>] EFLAGS: 00010046 CPU: 0
> [ 1.232000] EIP is at native_apic_mem_read+0x15/0x19
> [ 1.232000] EAX: ffffb020 EBX: 00000000 ECX: 00000000 EDX: fffff000
> [ 1.232000] ESI: 00000000 EDI: 7908c52e EBP: 9786fd38 ESP: 9786fd38
> [ 1.232000] DS: 007b ES: 007b FS: 0000 GS: 00e0 SS: 0068
> [ 1.232000] Process swapper (pid: 1, ti=9786e000 task=97870000 task.ti=9786e000)
> [ 1.232000] Stack:
> [ 1.232000] 9786fd40 78416e0d 9786fd48 78416fad 9786fd64 7908c55f 00000001 00000000
> [ 1.232000] 00000000 00000000 7908c52e 9786fd78 784671bf 00000001 00000000 00000000
> [ 1.232000] 9786fdac 7908ca42 00000001 9786fda0 784551ad 00000001 00000000 487ab0fc
> [ 1.232000] Call Trace:
> [ 1.232000] [<78416e0d>] ? read_apic_id+0x19/0x24
> [ 1.232000] [<78416fad>] ? hard_smp_processor_id+0xd/0xf
> [ 1.232000] [<7908c55f>] ? print_local_APIC+0x31/0x3c7
> [ 1.232000] [<7908c52e>] ? print_local_APIC+0x0/0x3c7
> [ 1.232000] [<784671bf>] ? smp_call_function_single+0x5b/0x64
> [ 1.232000] [<7908ca42>] ? print_all_ICs+0x14d/0x62a
> [ 1.232000] [<784551ad>] ? ktime_get+0x16/0x34
> [ 1.232000] [<7908c8f5>] ? print_all_ICs+0x0/0x62a
> [ 1.232000] [<7908c8f5>] ? print_all_ICs+0x0/0x62a
> [ 1.232000] [<7840107f>] ? _stext+0x7f/0x1f2
> [ 1.232000] [<786c2658>] ? put_dec+0x44/0x137
> [ 1.232000] [<784afae4>] ? page_count+0x22/0x3f
> [ 1.232000] [<784b1c0a>] ? get_page_from_freelist+0x51f/0x6b0
> [ 1.232000] [<786c2658>] ? put_dec+0x44/0x137
> [ 1.232000] [<784dcbee>] ? check_object+0x207/0x252
> [ 1.232000] [<786bb54f>] ? ida_get_new_above+0x2b0/0x2ca
> [ 1.232000] [<784dd5c5>] ? __slab_free+0x11a/0x4af
> [ 1.232000] [<784df012>] ? kmem_cache_free+0xce/0x163
> [ 1.232000] [<786bb54f>] ? ida_get_new_above+0x2b0/0x2ca
> [ 1.232000] [<786bb54f>] ? ida_get_new_above+0x2b0/0x2ca
> [ 1.232000] [<786bb75f>] ? ida_pre_get+0x13/0x18b
> [ 1.232000] [<7853f384>] ? proc_register+0x32a/0x34e
> [ 1.232000] [<7853f5bd>] ? create_proc_entry+0xf0/0x119
> [ 1.232000] [<7847e0bc>] ? register_irq_proc+0x87/0xbb
> [ 1.232000] [<7908251b>] ? kernel_init+0x8d/0x10a
> [ 1.232000] [<7908248e>] ? kernel_init+0x0/0x10a
> [ 1.232000] [<78403ee7>] ? kernel_thread_helper+0x7/0x10
> [ 1.232000] Code: 44 00 00 89 d1 8b 15 08 8b de 78 8d 84 10 00 c0 ff ff 89 08 5d c3 55 89 e5 0f 1f 44 00 00 8b 15 08 8b de 78 8d 84 10 00 c0 ff ff <8b> 00 5d c3 55 89 e5 0f 1f 44 00 00 89 c2 eb 02 f3 90 8b 02 85
> [ 1.232000] EIP: [<78417d5c>] native_apic_mem_read+0x15/0x19 SS:ESP 0068:9786fd38
> [ 1.232000] CR2: 00000000ffffb020
> [ 1.232000] ---[ end trace a7919e7f17c0a725 ]---
> [ 1.232000] Kernel panic - not syncing: Fatal exception
so !cpu_has_apic
we may add one native_apic_mem_read_dummy? also we could avoid alloc_bootmem_pages(PAGE_SIZE) to spare 4k bytes.
and we should check if cpu_has_apic in print_all_ICs()
YH
next prev parent reply other threads:[~2009-05-11 16:12 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20090430084145.GD21699@elte.hu>
2009-05-02 4:48 ` [PATCH] x86: read apic id if it is not acpi_lapic Yinghai Lu
2009-05-02 7:02 ` Cyrill Gorcunov
2009-05-02 17:40 ` [PATCH] x86: read apic id if it is not acpi_lapic -v2 Yinghai Lu
[not found] ` <20090502184108.GC4791@lenovo>
[not found] ` <49FC9BFC.4040904@kernel.org>
[not found] ` <20090502192441.GE4791@lenovo>
[not found] ` <49FC9F28.2070802@kernel.org>
[not found] ` <20090502193203.GG4791@lenovo>
2009-05-02 22:27 ` [PATCH] x86: change apic_version array to bsp apic ver only Yinghai Lu
2009-05-11 9:20 ` [PATCH] x86: read apic id if it is not acpi_lapic -v2 Ingo Molnar
2009-05-11 9:26 ` Ingo Molnar
2009-05-11 9:40 ` Cyrill Gorcunov
2009-05-11 11:06 ` Ingo Molnar
2009-05-11 9:53 ` [tip:x86/apic] x86: read apic ID in the !acpi_lapic case tip-bot for Yinghai Lu
2009-05-11 11:02 ` Ingo Molnar
2009-05-11 13:41 ` Cyrill Gorcunov
2009-05-11 13:49 ` Ingo Molnar
2009-05-11 17:43 ` Yinghai Lu
2009-05-11 18:05 ` Cyrill Gorcunov
2009-05-11 20:01 ` Ingo Molnar
2009-05-11 20:05 ` Cyrill Gorcunov
2009-05-11 20:14 ` Yinghai Lu
2009-05-11 13:54 ` [tip:x86/apic] x86: apic: Fixmap apic address even if apic disabled tip-bot for Cyrill Gorcunov
2009-05-11 16:11 ` Yinghai Lu [this message]
2009-05-12 10:36 ` [tip:irq/numa] x86: read apic ID in the !acpi_lapic case tip-bot for Yinghai Lu
2009-05-12 11:22 ` Ingo Molnar
2009-05-12 14:51 ` Cyrill Gorcunov
2009-05-12 14:58 ` Ingo Molnar
2009-05-12 15:00 ` Cyrill Gorcunov
2009-05-12 15:04 ` Yinghai Lu
2009-05-12 15:06 ` Ingo Molnar
2009-05-12 16:46 ` Ingo Molnar
2009-05-12 17:02 ` Cyrill Gorcunov
2009-05-12 17:12 ` Yinghai Lu
2009-05-12 17:27 ` Cyrill Gorcunov
2009-05-12 18:31 ` Yinghai Lu
2009-05-12 18:33 ` Ingo Molnar
2009-05-12 18:35 ` Yinghai Lu
2009-05-12 19:05 ` Ingo Molnar
2009-05-12 19:23 ` Yinghai Lu
2009-05-13 13:14 ` Ingo Molnar
2009-05-13 16:41 ` Yinghai Lu
2009-05-18 7:39 ` [tip:irq/numa] x86: don't call read_apic_id if !cpu_has_apic tip-bot for Yinghai Lu
2009-05-12 16:48 ` [tip:irq/numa] x86/pci: add 4 more return parameters to IO_APIC_get_PCI_irq_vector(), fix tip-bot for Cyrill Gorcunov
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=4A084E38.2050107@kernel.org \
--to=yinghai@kernel.org \
--cc=eswierk@aristanetworks.com \
--cc=gorcunov@openvz.org \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=mingo@redhat.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