mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-15 21:30:43 +00:00
ACPICA: Resource Manager: update template walking with ACPI_NEXT_RESOURCE.
Cleanup the ACPI_NEXT_RESOURCE macro. Update AcpiWalkResources to use ACPI_NEXT_RESOURCE. Lv Zheng. Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
parent
57bf6aefc2
commit
fb4e50269c
@ -606,9 +606,7 @@ acpi_walk_resources(acpi_handle device_handle,
|
||||
|
||||
/* Get the next resource descriptor */
|
||||
|
||||
resource =
|
||||
ACPI_ADD_PTR(struct acpi_resource, resource,
|
||||
resource->length);
|
||||
resource = ACPI_NEXT_RESOURCE(resource);
|
||||
}
|
||||
|
||||
ACPI_FREE(buffer.pointer);
|
||||
|
@ -591,7 +591,10 @@ struct acpi_resource {
|
||||
#define ACPI_RS_SIZE_MIN (u32) ACPI_ROUND_UP_TO_NATIVE_WORD (12)
|
||||
#define ACPI_RS_SIZE(type) (u32) (ACPI_RS_SIZE_NO_DATA + sizeof (type))
|
||||
|
||||
#define ACPI_NEXT_RESOURCE(res) (struct acpi_resource *)((u8 *) res + res->length)
|
||||
/* Macro for walking resource templates with multiple descriptors */
|
||||
|
||||
#define ACPI_NEXT_RESOURCE(res) \
|
||||
ACPI_ADD_PTR (struct acpi_resource, (res), (res)->length)
|
||||
|
||||
struct acpi_pci_routing_table {
|
||||
u32 length;
|
||||
|
Loading…
Reference in New Issue
Block a user