Subject: ACPI: Avoid twice read access to EC data I/O port >From : Zhao Yakui <yakui.zhao@xxxxxxxxx> In current kernel when OS reads the data returned by the EC controller, the EC data I/O port is accessed twice. In fact is is meaningless. Only once access to EC data I/O port is enough to get data returned by EC controller. Signed-off-by : Zhao Yakui <yakui.zhao@xxxxxxxxx> Acked-by : Alexey Starikovskiy <astarikovskiy@xxxxxxx> --- drivers/acpi/ec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Index: linux-2.6/drivers/acpi/ec.c =================================================================== --- linux-2.6.orig/drivers/acpi/ec.c +++ linux-2.6/drivers/acpi/ec.c @@ -150,7 +150,7 @@ static inline u8 acpi_ec_read_data(struc { u8 x = inb(ec->data_addr); pr_debug(PREFIX "---> data = 0x%2.2x\n", x); - return inb(ec->data_addr); + return x; } static inline void acpi_ec_write_cmd(struct acpi_ec *ec, u8 command) -- To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html