]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
ACPICA: Fix wrong resource descriptor length for 64-bit build
authorBob Moore <robert.moore@intel.com>
Fri, 4 Jul 2008 02:56:13 +0000 (10:56 +0800)
committerLen Brown <len.brown@intel.com>
Thu, 23 Oct 2008 03:14:35 +0000 (23:14 -0400)
The "minimal" descriptors such as EndTag are calculated as 12
bytes long, but the actual length in the internal descriptor is
16 because of the round-up to 8 on 64-bit build.

http://www.acpica.org/bugzilla/show_bug.cgi?id=728

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
include/acpi/actypes.h

index 4ea4f40bf894c22e0a1f99b745bd503e6a996f24..73d6b1cb07f3e7d981dc0935d16175ae099abb39 100644 (file)
@@ -1225,8 +1225,8 @@ struct acpi_resource {
 
 #pragma pack()
 
-#define ACPI_RS_SIZE_MIN                    12
 #define ACPI_RS_SIZE_NO_DATA                8  /* Id + Length fields */
+#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)