[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] Xen randomly stuck in mdelay() during MP initialization



On Wed, Jan 11, 2012 at 1:28 PM, Keir Fraser <keir.xen@xxxxxxxxx> wrote:
> On 11/01/2012 13:06, "Julian Pidancet" <julian.pidancet@xxxxxxxxx> wrote:
>
>> Hi,
>>
>> When trying to boot xen 4.1 on new hardware, Xen become stuck in
>> wakeup_secondary_cpu() in the mdelay function.
>>
>> Â Â Dprintk("Waiting for send to finish...\n");
>> Â Â timeout = 0;
>> Â Â do {
>> Â Â Â Â Dprintk("+");
>> Â Â Â Â udelay(100);
>> Â Â Â Â if ( !x2apic_enabled )
>> Â Â Â Â Â Â send_status = apic_read(APIC_ICR) & APIC_ICR_BUSY;
>> Â Â } while ( send_status && (timeout++ < 1000) );
>>
>> Â Â printk("before mdelay\n");
>> Â Â mdelay(10);
>> Â Â printk("after mdelay\n");
>>
>> Â Â Dprintk("Deasserting INIT.\n");
>>
>> The hang can happen randomly with any of the CPUs to wake up and
>> sometime doesn't happen at all.
>> Replacing mdelay(10) with udelay(10) seems to fix the issue.
>
> Do you see this in xen-unstable? Hopefully it is working there, and we can
> simply backport the fix.
>

I checked yesterday and the code of this function is the same in
xen-unstable, but I don't encounter the problem with xen-unstable.

What concerns me is that this is the only place in the function where
mdelay() is used, the rest of the function seems to be using udelay().
What's the difference between the two ?
Does mdelay() relies on some form of timer to execute ?

-- 
Julian

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.