On Fri, 27 May 2011, Jiageng Yu wrote:
> 2011/5/27 Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>:
> > On Fri, May 27, 2011 at 05:58:51PM +0800, Jiageng Yu wrote:
> >> I have updated the pv linux kernel from 2.6.32.40 to 2.6.32.41. I
> >> found the generic_apic_probe always led to a kernel panic when I try
> >> to make the minimal DomU kernel.
> >>
> >> The 2.6.32.41 pv linux use the new apic probe mechanism:
> >
> > new..? What was it before?
>
>
> The linux kernel will invoke probe_default, which permanently returns 1.
> I wander to know may I just return 1 in 2.6.32.41 kernel? If there is
> no further problems.
>
It seems to me that we have to return 1 unless CONFIG_X86_LOCAL_APIC is
disabled, and in that case we wouldn't need to set anything at all.
Considering that the default apic probe function will just return 1, I
suggest we just remove xen_safe_probe completely.
In fact we don't have it upstream.
Patch completely untested below:
---
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
index 0493093..0c31ceb 100644
--- a/arch/x86/xen/enlighten.c
+++ b/arch/x86/xen/enlighten.c
@@ -759,14 +759,6 @@ static __init int xen_safe_flat_acpi_madt_oem_check(char
*oem_id,
return 1;
}
-static __init int xen_safe_probe(void) {
-
- if (!xen_initial_domain())
- return 0;
-
- return 1;
-}
-
struct apic apic_xen = {
.name = "xen",
};
@@ -779,7 +771,6 @@ static __init void set_xen_basic_apic_ops(void)
apic->icr_write = xen_apic_icr_write;
apic->wait_icr_idle = xen_apic_wait_icr_idle;
apic->safe_wait_icr_idle = xen_safe_apic_wait_icr_idle;
- apic->probe = xen_safe_probe;
apic->acpi_madt_oem_check = xen_safe_flat_acpi_madt_oem_check;
/* Copy over the full contents of the newly modified apic into
* our apic_xen, which is to be called first by apic_probe[]. */
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|