diff options
author | Lv Zheng <lv.zheng@intel.com> | 2014-10-14 02:23:43 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2014-10-20 18:44:53 -0400 |
commit | 459572a7503bccb5435936488088c8db4f51d3ab (patch) | |
tree | 940d26a86d078b486ec332d04a76bbcc3e094398 /drivers/acpi | |
parent | c95f25b03667c50e7184a63bdf4c32dff0de2f6f (diff) |
ACPI / EC: Enhance the logs to apply to QR_EC transactions.
Currently some logs are applied to new transactions, but QR_EC transactions
are not included. This patch merges the code path to make the logs also
applying to the QR_EC transactions.
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi')
-rw-r--r-- | drivers/acpi/ec.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/acpi/ec.c b/drivers/acpi/ec.c index 9cb4d0c468eb..b15a431301a0 100644 --- a/drivers/acpi/ec.c +++ b/drivers/acpi/ec.c | |||
@@ -303,12 +303,15 @@ static int acpi_ec_transaction_unlocked(struct acpi_ec *ec, | |||
303 | spin_lock_irqsave(&ec->lock, tmp); | 303 | spin_lock_irqsave(&ec->lock, tmp); |
304 | /* following two actions should be kept atomic */ | 304 | /* following two actions should be kept atomic */ |
305 | ec->curr = t; | 305 | ec->curr = t; |
306 | pr_debug("transaction start (cmd=0x%02x, addr=0x%02x)\n", | ||
307 | t->command, t->wdata ? t->wdata[0] : 0); | ||
306 | start_transaction(ec); | 308 | start_transaction(ec); |
307 | spin_unlock_irqrestore(&ec->lock, tmp); | 309 | spin_unlock_irqrestore(&ec->lock, tmp); |
308 | ret = ec_poll(ec); | 310 | ret = ec_poll(ec); |
309 | spin_lock_irqsave(&ec->lock, tmp); | 311 | spin_lock_irqsave(&ec->lock, tmp); |
310 | if (ec->curr->command == ACPI_EC_COMMAND_QUERY) | 312 | if (ec->curr->command == ACPI_EC_COMMAND_QUERY) |
311 | clear_bit(EC_FLAGS_QUERY_PENDING, &ec->flags); | 313 | clear_bit(EC_FLAGS_QUERY_PENDING, &ec->flags); |
314 | pr_debug("transaction end\n"); | ||
312 | ec->curr = NULL; | 315 | ec->curr = NULL; |
313 | spin_unlock_irqrestore(&ec->lock, tmp); | 316 | spin_unlock_irqrestore(&ec->lock, tmp); |
314 | return ret; | 317 | return ret; |
@@ -334,8 +337,6 @@ static int acpi_ec_transaction(struct acpi_ec *ec, struct transaction *t) | |||
334 | goto unlock; | 337 | goto unlock; |
335 | } | 338 | } |
336 | } | 339 | } |
337 | pr_debug("transaction start (cmd=0x%02x, addr=0x%02x)\n", | ||
338 | t->command, t->wdata ? t->wdata[0] : 0); | ||
339 | /* disable GPE during transaction if storm is detected */ | 340 | /* disable GPE during transaction if storm is detected */ |
340 | if (test_bit(EC_FLAGS_GPE_STORM, &ec->flags)) { | 341 | if (test_bit(EC_FLAGS_GPE_STORM, &ec->flags)) { |
341 | /* It has to be disabled, so that it doesn't trigger. */ | 342 | /* It has to be disabled, so that it doesn't trigger. */ |
@@ -356,7 +357,6 @@ static int acpi_ec_transaction(struct acpi_ec *ec, struct transaction *t) | |||
356 | t->irq_count); | 357 | t->irq_count); |
357 | set_bit(EC_FLAGS_GPE_STORM, &ec->flags); | 358 | set_bit(EC_FLAGS_GPE_STORM, &ec->flags); |
358 | } | 359 | } |
359 | pr_debug("transaction end\n"); | ||
360 | if (ec->global_lock) | 360 | if (ec->global_lock) |
361 | acpi_release_global_lock(glk); | 361 | acpi_release_global_lock(glk); |
362 | unlock: | 362 | unlock: |