]> git.baikalelectronics.ru Git - kernel.git/commit
libata: restore acpi disable functionality
authorAaron Lu <aaron.lu@intel.com>
Mon, 26 Nov 2012 05:55:25 +0000 (13:55 +0800)
committerJeff Garzik <jgarzik@redhat.com>
Mon, 3 Dec 2012 09:57:15 +0000 (04:57 -0500)
commita7e1fb282e39755e409c213302f6f3803e87cf21
tree0bae4e559e963bdc1b487806848b5df7021a3283
parentd5d4a5677b2d0ee88ae270347fae084f3453fc13
libata: restore acpi disable functionality

Commit b6c98d576 "libata-acpi: improve ACPI disabling" introdcued the
behaviour of disabling ATA ACPI if ata_acpi_on_devcfg failed the 2nd
time, but commit c3ba563d0 dropped this behaviour and this caused
problem for Dimitris Damigos, where his laptop can not resume correctly.

The bugzilla page for it is:
https://bugzilla.kernel.org/show_bug.cgi?id=49331

The problem is, ata_dev_push_id will fail the 2nd time it is invoked,
and due to disabling ACPI code is dropped, ata_acpi_on_devcfg which
calls ata_dev_push_id will keep failing and eventually made the device
disabled.

This patch restores the original behaviour, if acpi failed the 2nd time,
disable acpi functionality for the device(and we do not event need to
add a debug message for this as it is still there ;-).

Reported-by: Dimitris Damigos <damigos@freemail.gr>
Signed-off-by: Aaron Lu <aaron.lu@intel.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
drivers/ata/libata-acpi.c
include/linux/libata.h