Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 210330
b: refs/heads/master
c: 2b8fd91
h: refs/heads/master
v: v3
  • Loading branch information
Rafael J. Wysocki authored and Jesse Barnes committed Aug 24, 2010
1 parent 33f7ab1 commit ade38f8
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 17 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: ab8e8957a2ae21c0f036476c6db13e949be730ac
refs/heads/master: 2b8fd9186d9275b07aef43e5bb4e98cd571f9a7d
20 changes: 7 additions & 13 deletions trunk/drivers/acpi/pci_root.c
Original file line number Diff line number Diff line change
Expand Up @@ -249,12 +249,8 @@ static acpi_status acpi_pci_query_osc(struct acpi_pci_root *root,
status = acpi_pci_run_osc(root->device->handle, capbuf, &result);
if (ACPI_SUCCESS(status)) {
root->osc_support_set = support;
if (control) {
if (control)
*control = result;
} else {
root->osc_control_qry = result;
root->osc_queried = 1;
}
}
return status;
}
Expand Down Expand Up @@ -409,14 +405,12 @@ acpi_status acpi_pci_osc_control_set(acpi_handle handle, u32 flags)
goto out;

/* Need to query controls first before requesting them */
if (!root->osc_queried) {
status = acpi_pci_query_osc(root, root->osc_support_set, NULL);
if (ACPI_FAILURE(status))
goto out;
}
if ((root->osc_control_qry & control_req) != control_req) {
printk(KERN_DEBUG
"Firmware did not grant requested _OSC control\n");
flags = control_req;
status = acpi_pci_query_osc(root, root->osc_support_set, &flags);
if (ACPI_FAILURE(status))
goto out;

if (flags != control_req) {
status = AE_SUPPORT;
goto out;
}
Expand Down
3 changes: 0 additions & 3 deletions trunk/include/acpi/acpi_bus.h
Original file line number Diff line number Diff line change
Expand Up @@ -377,9 +377,6 @@ struct acpi_pci_root {

u32 osc_support_set; /* _OSC state of support bits */
u32 osc_control_set; /* _OSC state of control bits */
u32 osc_control_qry; /* the latest _OSC query result */

u32 osc_queried:1; /* has _OSC control been queried? */
};

/* helper */
Expand Down

0 comments on commit ade38f8

Please sign in to comment.