Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ACPI: Remove duplicate definitions for _STA bits

No need to duplicate the existing definitions in include/acpi/actypes.h.

syntax only -- no functional change.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Len Brown <len.brown@intel.com>

authored by

Bjorn Helgaas and committed by
Len Brown
a0bd4ac4 d8938801

+7 -16
+4 -9
drivers/acpi/acpi_memhotplug.c
··· 44 44 MODULE_DESCRIPTION("Hotplug Mem Driver"); 45 45 MODULE_LICENSE("GPL"); 46 46 47 - /* ACPI _STA method values */ 48 - #define ACPI_MEMORY_STA_PRESENT (0x00000001UL) 49 - #define ACPI_MEMORY_STA_ENABLED (0x00000002UL) 50 - #define ACPI_MEMORY_STA_FUNCTIONAL (0x00000008UL) 51 - 52 47 /* Memory Device States */ 53 48 #define MEMORY_INVALID_STATE 0 54 49 #define MEMORY_POWER_ON_STATE 1 ··· 199 204 * Check for device status. Device should be 200 205 * present/enabled/functioning. 201 206 */ 202 - if (!((current_status & ACPI_MEMORY_STA_PRESENT) 203 - && (current_status & ACPI_MEMORY_STA_ENABLED) 204 - && (current_status & ACPI_MEMORY_STA_FUNCTIONAL))) 207 + if (!((current_status & ACPI_STA_DEVICE_PRESENT) 208 + && (current_status & ACPI_STA_DEVICE_ENABLED) 209 + && (current_status & ACPI_STA_DEVICE_FUNCTIONING))) 205 210 return -ENODEV; 206 211 207 212 return 0; ··· 281 286 return -ENODEV; 282 287 283 288 /* Check for device status. Device should be disabled */ 284 - if (current_status & ACPI_MEMORY_STA_ENABLED) 289 + if (current_status & ACPI_STA_DEVICE_ENABLED) 285 290 return -EINVAL; 286 291 287 292 return 0;
+2 -4
drivers/acpi/container.c
··· 49 49 MODULE_DESCRIPTION("ACPI container driver"); 50 50 MODULE_LICENSE("GPL"); 51 51 52 - #define ACPI_STA_PRESENT (0x00000001) 53 - 54 52 static int acpi_container_add(struct acpi_device *device); 55 53 static int acpi_container_remove(struct acpi_device *device, int type); 56 54 ··· 73 75 74 76 status = acpi_get_handle(handle, "_STA", &temp); 75 77 if (ACPI_FAILURE(status)) 76 - return 1; /* _STA not found, assmue device present */ 78 + return 1; /* _STA not found, assume device present */ 77 79 78 80 status = acpi_evaluate_integer(handle, "_STA", NULL, &sta); 79 81 if (ACPI_FAILURE(status)) 80 82 return 0; /* Firmware error */ 81 83 82 - return ((sta & ACPI_STA_PRESENT) == ACPI_STA_PRESENT); 84 + return ((sta & ACPI_STA_DEVICE_PRESENT) == ACPI_STA_DEVICE_PRESENT); 83 85 } 84 86 85 87 /*******************************************************************/
+1 -3
drivers/acpi/processor_core.c
··· 70 70 #define ACPI_PROCESSOR_LIMIT_USER 0 71 71 #define ACPI_PROCESSOR_LIMIT_THERMAL 1 72 72 73 - #define ACPI_STA_PRESENT 0x00000001 74 - 75 73 #define _COMPONENT ACPI_PROCESSOR_COMPONENT 76 74 ACPI_MODULE_NAME("processor_core"); 77 75 ··· 777 779 778 780 779 781 status = acpi_evaluate_integer(handle, "_STA", NULL, &sta); 780 - if (ACPI_FAILURE(status) || !(sta & ACPI_STA_PRESENT)) { 782 + if (ACPI_FAILURE(status) || !(sta & ACPI_STA_DEVICE_PRESENT)) { 781 783 ACPI_EXCEPTION((AE_INFO, status, "Processor Device is not present")); 782 784 return 0; 783 785 }