Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 322881
b: refs/heads/master
c: eceeb43
h: refs/heads/master
i:
  322879: ab2a7db
v: v3
  • Loading branch information
Dan Carpenter authored and Matthew Garrett committed Sep 13, 2012
1 parent b41e31e commit ea4edfb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 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: f661848b74b33069b0b7068c414bd282c407781d
refs/heads/master: eceeb4371240aff22e9a535a2bc57d2311820942
13 changes: 7 additions & 6 deletions trunk/drivers/platform/x86/thinkpad_acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -545,7 +545,7 @@ TPACPI_HANDLE(hkey, ec, "\\_SB.HKEY", /* 600e/x, 770e, 770x */
*/

static int acpi_evalf(acpi_handle handle,
void *res, char *method, char *fmt, ...)
int *res, char *method, char *fmt, ...)
{
char *fmt0 = fmt;
struct acpi_object_list params;
Expand Down Expand Up @@ -606,7 +606,7 @@ static int acpi_evalf(acpi_handle handle,
success = (status == AE_OK &&
out_obj.type == ACPI_TYPE_INTEGER);
if (success && res)
*(int *)res = out_obj.integer.value;
*res = out_obj.integer.value;
break;
case 'v': /* void */
success = status == AE_OK;
Expand Down Expand Up @@ -7386,17 +7386,18 @@ static int fan_get_status(u8 *status)
* Add TPACPI_FAN_RD_ACPI_FANS ? */

switch (fan_status_access_mode) {
case TPACPI_FAN_RD_ACPI_GFAN:
case TPACPI_FAN_RD_ACPI_GFAN: {
/* 570, 600e/x, 770e, 770x */
int res;

if (unlikely(!acpi_evalf(gfan_handle, &s, NULL, "d")))
if (unlikely(!acpi_evalf(gfan_handle, &res, NULL, "d")))
return -EIO;

if (likely(status))
*status = s & 0x07;
*status = res & 0x07;

break;

}
case TPACPI_FAN_RD_TPEC:
/* all except 570, 600e/x, 770e, 770x */
if (unlikely(!acpi_ec_read(fan_status_offset, &s)))
Expand Down

0 comments on commit ea4edfb

Please sign in to comment.