]> err.no Git - linux-2.6/commitdiff
ACPI: EC: Some hardware requires burst mode to operate properly
authorAlexey Starikovskiy <astarikovskiy@suse.de>
Thu, 10 Jan 2008 23:42:57 +0000 (02:42 +0300)
committerLen Brown <len.brown@intel.com>
Fri, 11 Jan 2008 01:50:12 +0000 (20:50 -0500)
Burst mode temporary (50 ms) locks EC to do only transactions with
driver, without it some hardware returns abstract garbage.

Reference: http://bugzilla.kernel.org/show_bug.cgi?id=9341

Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Signed-off-by: Len Brown <len.brown@intel.com>
drivers/acpi/ec.c

index 63862dfe347b65337d9d5838acdd48109d24a66b..445ecbabbe7686c3a2a00a548a96821cd02d46be 100644 (file)
@@ -575,6 +575,8 @@ acpi_ec_space_handler(u32 function, acpi_physical_address address,
        if (bits != 8 && acpi_strict)
                return AE_BAD_PARAMETER;
 
+       acpi_ec_burst_enable(ec);
+
        if (function == ACPI_READ) {
                result = acpi_ec_read(ec, address, &temp);
                *value = temp;
@@ -594,6 +596,8 @@ acpi_ec_space_handler(u32 function, acpi_physical_address address,
                }
        }
 
+       acpi_ec_burst_disable(ec);
+
        switch (result) {
        case -EINVAL:
                return AE_BAD_PARAMETER;