ACPI EC: remove potential deadlock from EC
authorAlexey Starikovskiy <astarikovskiy@suse.de>
Fri, 10 Aug 2007 20:45:18 +0000 (13:45 -0700)
committerLen Brown <len.brown@intel.com>
Sun, 12 Aug 2007 02:26:24 +0000 (22:26 -0400)
Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Len Brown <len.brown@intel.com>
drivers/acpi/ec.c

index b28b56524f0bceab21ee80b0b7b59d4d6db26a4b..2300d81bbc4e4aaf9b8fd17050ab0b4df9923d67 100644 (file)
@@ -710,9 +710,7 @@ static int acpi_ec_add(struct acpi_device *device)
        /* Check if we found the boot EC */
        if (boot_ec) {
                if (boot_ec->gpe == ec->gpe) {
-                       mutex_lock(&boot_ec->lock);
                        ec_remove_handlers(boot_ec);
-                       mutex_unlock(&boot_ec->lock);
                        mutex_destroy(&boot_ec->lock);
                        kfree(boot_ec);
                        first_ec = boot_ec = NULL;