Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 44941
b: refs/heads/master
c: 50c1e11
h: refs/heads/master
i:
  44939: 8290a1e
v: v3
  • Loading branch information
Alexey Starikovskiy authored and Len Brown committed Dec 8, 2006
1 parent f043c65 commit 4c7dea6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a86e277259b08be0f00cfcb182922da3ffc50f04
refs/heads/master: 50c1e1138cb94f6aca0f8555777edbcefe0324e2
7 changes: 2 additions & 5 deletions trunk/drivers/acpi/ec.c
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,6 @@ enum {

#define ACPI_EC_DELAY 500 /* Wait 500ms max. during EC ops */
#define ACPI_EC_UDELAY_GLK 1000 /* Wait 1ms max. to get global lock */
#define ACPI_EC_UDELAY 100 /* Poll @ 100us increments */
#define ACPI_EC_UDELAY_COUNT 1000 /* Wait 100ms max. during EC ops */

enum {
EC_INTR = 1, /* Output buffer full */
Expand Down Expand Up @@ -159,11 +157,10 @@ static int acpi_ec_check_status(struct acpi_ec *ec, u8 event)
static int acpi_ec_wait(struct acpi_ec *ec, u8 event)
{
if (acpi_ec_mode == EC_POLL) {
int i;
for (i = 0; i < ACPI_EC_UDELAY_COUNT; ++i) {
unsigned long delay = jiffies + msecs_to_jiffies(ACPI_EC_DELAY);
while (time_before(jiffies, delay)) {
if (acpi_ec_check_status(ec, event))
return 0;
udelay(ACPI_EC_UDELAY);
}
} else {
if (wait_event_timeout(ec->wait,
Expand Down

0 comments on commit 4c7dea6

Please sign in to comment.