Re: [PATCH 0/11] ACPI: Fixes and cleanups related to iomaps management

From: Rafael J. Wysocki
Date: Mon Jan 24 2011 - 16:38:05 EST


On Monday, January 24, 2011, Henrique de Moraes Holschuh wrote:
> On Sun, 23 Jan 2011, Rafael J. Wysocki wrote:
> > On Sunday, January 23, 2011, Henrique de Moraes Holschuh wrote:
> > > On Sat, 22 Jan 2011, Rafael J. Wysocki wrote:
> > > > > I discovered CONFIG_THINKPAD_ACPI caused suspend-to-disk to hang. I
> > > > > need the Thinkpad ACPI to control the fan and bluetooth. It looks like
> > > > > the thinkpad acpi is trying acquire locks while suspending. Disabling
> > > > > cmos, light, led and hotkeys makes suspend-to-disk works again.
> > > >
> > > > Well, we should tell the thinkpad_acpi maintainer about that, then (CCed).
> > >
> > > What are the requirements re. mutexes for sleep-to-disk versus sleep-to-ram?
> >
> > No difference. Basically, there are two differences between suspend and
> > hibernation, as far as drivers are concerned:
> > (1) It's better to use the ->freeze()/->thaw() and ->poweroff()/->restore()
> > callbacks for hibernation.
> > (2) It may be _much_ more difficult to get free memory during hibernation
> > (so theoretically attempts to get memory during hibernation are more likely
> > to block).
>
> So, if there is nothing wrong with mutex use by itself...
>
> Thinkpad-acpi calls the thinkpad firmware (using normal ACPI method calls),
> which does SMI traps into the SMBIOS to do whatever it wants done. And that
> includes writing to the NVS (both the peecee RTC CMOS, and ACPI-backed
> "NVS").
>
> > Besides, the problem reported by Jeff seems to be caused by CPU hotplug.
>
> Something weird going on with CPU hotplug could throw Lenovo's
> way-too-complex-for-comfort SMM firmware out of wack alright.
>
> That can be checked. Lobotomize the driver so that it does not do the acpi
> calls in the suspend path (but keep everything else). If it still locks, it
> is not the firmware.

It turns out there's a bug in intel_idle causing people a lot of pain with CPU
hotplugging. Should be fixed now it the Linus' tree.

Thanks,
Rafael
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/