diff options
author | Bob Moore <robert.moore@intel.com> | 2013-07-16 21:48:15 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-07-22 19:06:49 -0400 |
commit | a7d5caf6d21814a855422df75c2d8c093cb2019a (patch) | |
tree | 9c86c64aa1f4b020f17af3db44d9f17ee2dcedff /drivers/acpi/acpica | |
parent | 3b2f64d00c46e1e4e9bd0bb9bb12619adac27a4b (diff) |
ACPICA: Update comments about behavior when _STA does not exist
No functional change. Add some comments concerning behavior
when the _STA method does not exist. According to the ACPI
specification, in this case the device should be assumed to be
present, functional, and enabled.
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Acked-by: Len Brown <len.brown@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/acpica')
-rw-r--r-- | drivers/acpi/acpica/nsxfname.c | 7 | ||||
-rw-r--r-- | drivers/acpi/acpica/uteval.c | 8 |
2 files changed, 13 insertions, 2 deletions
diff --git a/drivers/acpi/acpica/nsxfname.c b/drivers/acpi/acpica/nsxfname.c index f3a4d95899f7..21a2ef363ad4 100644 --- a/drivers/acpi/acpica/nsxfname.c +++ b/drivers/acpi/acpica/nsxfname.c | |||
@@ -379,9 +379,14 @@ acpi_get_object_info(acpi_handle handle, | |||
379 | * Get extra info for ACPI Device/Processor objects only: | 379 | * Get extra info for ACPI Device/Processor objects only: |
380 | * Run the _STA, _ADR and, sx_w, and _sx_d methods. | 380 | * Run the _STA, _ADR and, sx_w, and _sx_d methods. |
381 | * | 381 | * |
382 | * Note: none of these methods are required, so they may or may | 382 | * Notes: none of these methods are required, so they may or may |
383 | * not be present for this device. The Info->Valid bitfield is used | 383 | * not be present for this device. The Info->Valid bitfield is used |
384 | * to indicate which methods were found and run successfully. | 384 | * to indicate which methods were found and run successfully. |
385 | * | ||
386 | * For _STA, if the method does not exist, then (as per the ACPI | ||
387 | * specification), the returned current_status flags will indicate | ||
388 | * that the device is present/functional/enabled. Otherwise, the | ||
389 | * current_status flags reflect the value returned from _STA. | ||
385 | */ | 390 | */ |
386 | 391 | ||
387 | /* Execute the Device._STA method */ | 392 | /* Execute the Device._STA method */ |
diff --git a/drivers/acpi/acpica/uteval.c b/drivers/acpi/acpica/uteval.c index ee83adb97b1e..4fd68971019b 100644 --- a/drivers/acpi/acpica/uteval.c +++ b/drivers/acpi/acpica/uteval.c | |||
@@ -239,7 +239,8 @@ acpi_ut_evaluate_numeric_object(char *object_name, | |||
239 | * RETURN: Status | 239 | * RETURN: Status |
240 | * | 240 | * |
241 | * DESCRIPTION: Executes _STA for selected device and stores results in | 241 | * DESCRIPTION: Executes _STA for selected device and stores results in |
242 | * *Flags. | 242 | * *Flags. If _STA does not exist, then the device is assumed |
243 | * to be present/functional/enabled (as per the ACPI spec). | ||
243 | * | 244 | * |
244 | * NOTE: Internal function, no parameter validation | 245 | * NOTE: Internal function, no parameter validation |
245 | * | 246 | * |
@@ -257,6 +258,11 @@ acpi_ut_execute_STA(struct acpi_namespace_node *device_node, u32 * flags) | |||
257 | ACPI_BTYPE_INTEGER, &obj_desc); | 258 | ACPI_BTYPE_INTEGER, &obj_desc); |
258 | if (ACPI_FAILURE(status)) { | 259 | if (ACPI_FAILURE(status)) { |
259 | if (AE_NOT_FOUND == status) { | 260 | if (AE_NOT_FOUND == status) { |
261 | /* | ||
262 | * if _STA does not exist, then (as per the ACPI specification), | ||
263 | * the returned flags will indicate that the device is present, | ||
264 | * functional, and enabled. | ||
265 | */ | ||
260 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, | 266 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, |
261 | "_STA on %4.4s was not found, assuming device is present\n", | 267 | "_STA on %4.4s was not found, assuming device is present\n", |
262 | acpi_ut_get_node_name(device_node))); | 268 | acpi_ut_get_node_name(device_node))); |