Blame SOURCES/aapits-linux.patch

305057
diff --git a/tests/aapits/atexec.c b/tests/aapits/atexec.c
305057
index be86d00..fe47228 100644
305057
--- a/tests/aapits/atexec.c
305057
+++ b/tests/aapits/atexec.c
305057
@@ -639,6 +639,7 @@ AtBuildLocalFADT2 (
32dd66
 }
32dd66
 
32dd66
 
32dd66
+#if ACPI_MACHINE_WIDTH == 32
32dd66
 /*******************************************************************************
32dd66
  *
32dd66
  * FUNCTION:    AtBuildLocalRSDT
305057
@@ -757,6 +758,7 @@ AtBuildLocalRSDT (
32dd66
         LocalRSDT->Header.Checksum = (UINT8)~LocalRSDT->Header.Checksum;
32dd66
     }
32dd66
 }
32dd66
+#endif
32dd66
 
32dd66
 
32dd66
 /*******************************************************************************
305057
@@ -1424,7 +1426,7 @@ AeRegionHandler (
32dd66
         ACPI_WARNING ((AE_INFO,
32dd66
             "Request on [%4.4s] is beyond region limit Req-%X+%X, Base=%X, Len-%X\n",
32dd66
             (RegionObject->Region.Node)->Name.Ascii, (UINT32) Address,
32dd66
-            ByteWidth, (UINT32) BufferAddress, Length));
32dd66
+            ByteWidth, (UINT32) BufferAddress, (UINT32) Length));
32dd66
 
32dd66
         return (AE_AML_REGION_LIMIT);
32dd66
     }
305057
@@ -1799,7 +1801,9 @@ AtCheckInteger(
32dd66
             Path, Obj.Integer.Value, Value);
32dd66
 #else
32dd66
         printf ("API Error: Value of %s is 0x%llx instead of expected 0x%llx\n",
32dd66
-            Path, Obj.Integer.Value, Value);
32dd66
+            Path,
32dd66
+	    (long long unsigned int) Obj.Integer.Value,
32dd66
+	    (long long unsigned int) Value);
32dd66
 #endif
32dd66
         Status = AE_ERROR;
32dd66
     }
305057
@@ -1878,7 +1882,7 @@ AtCheckString(
32dd66
     {
32dd66
         TestErrors++;
32dd66
         printf ("Test Error: cannot allocate buffer of %d bytes\n",
32dd66
-            Results.Length);
32dd66
+                (int) Results.Length);
32dd66
         return (AE_NO_MEMORY);
32dd66
     }
32dd66
     Results.Pointer = Object;
305057
@@ -1959,7 +1963,8 @@ AtCheckBuffer(
32dd66
     {
32dd66
         printf ("AtCheckBuffer: unexpected length %d of Buffer vs"
32dd66
             " calculated %d bytes\n",
32dd66
-            Results.Length, ACPI_ROUND_UP_TO_NATIVE_WORD(sizeof (ACPI_OBJECT) + Length));
32dd66
+            (int)Results.Length,
32dd66
+	    (int)(ACPI_ROUND_UP_TO_NATIVE_WORD(sizeof (ACPI_OBJECT) + Length)));
32dd66
     }
32dd66
 
32dd66
     /* Initialize the return buffer structure */
305057
@@ -1968,7 +1973,7 @@ AtCheckBuffer(
32dd66
     {
32dd66
         TestErrors++;
32dd66
         printf ("Test Error: cannot allocate buffer of %d bytes\n",
32dd66
-            Results.Length);
32dd66
+            (int) Results.Length);
32dd66
         return (AE_NO_MEMORY);
32dd66
     }
32dd66
     Results.Pointer = Object;
305057
diff --git a/tests/aapits/atinit.c b/tests/aapits/atinit.c
305057
index 0c74029..90cd137 100644
305057
--- a/tests/aapits/atinit.c
305057
+++ b/tests/aapits/atinit.c
305057
@@ -3024,7 +3024,7 @@ AtInitTest0041(void)
32dd66
             AapiErrors++;
32dd66
             printf ("API Error: AcpiGetSystemInfo() returned"
32dd66
                 " Length %d, expected %d\n",
32dd66
-                OutBuffer.Length, sizeof (Info));
32dd66
+                (int) OutBuffer.Length, (int) sizeof (Info));
32dd66
             return (AE_ERROR);
32dd66
         }
32dd66
 
305057
@@ -3046,7 +3046,7 @@ AtInitTest0041(void)
32dd66
             AapiErrors++;
32dd66
             printf ("API Error: AcpiGetSystemInfo() returned"
32dd66
                 " Length %d, expected %d\n",
32dd66
-                OutBuffer.Length, sizeof (Info));
32dd66
+                (int) OutBuffer.Length, (int) sizeof (Info));
32dd66
             return (AE_ERROR);
32dd66
         }
32dd66
 
305057
@@ -3066,7 +3066,7 @@ AtInitTest0041(void)
32dd66
             AapiErrors++;
32dd66
             printf ("API Error: AcpiGetSystemInfo() returned"
32dd66
                 " Length %d, expected %d\n",
32dd66
-                OutBuffer.Length, sizeof (Info));
32dd66
+                (int) OutBuffer.Length, (int) sizeof (Info));
32dd66
             return (AE_ERROR);
32dd66
         }
32dd66
         else if (OutBuffer.Pointer != &Info)
305057
@@ -3149,7 +3149,7 @@ AtInitTest0042(void)
32dd66
             AapiErrors++;
32dd66
             printf ("API Error: AcpiGetSystemInfo() returned"
32dd66
                 " Length %d, expected %d\n",
32dd66
-                OutBuffer.Length, sizeof (Info));
32dd66
+                (int) OutBuffer.Length, (int) sizeof (Info));
32dd66
             return (AE_ERROR);
32dd66
         }
32dd66
         else if (OutBuffer.Pointer != &Info)
305057
@@ -3214,7 +3214,7 @@ AtInitTest0043(void)
32dd66
             AapiErrors++;
32dd66
             printf ("API Error: AcpiGetSystemInfo() returned"
32dd66
                 " Length %d, expected %d\n",
32dd66
-                OutBuffer.Length, sizeof (ACPI_SYSTEM_INFO));
32dd66
+                (int) OutBuffer.Length, (int) sizeof (ACPI_SYSTEM_INFO));
32dd66
             return (AE_ERROR);
32dd66
         }
32dd66
         else
305057
diff --git a/tests/aapits/atmain.c b/tests/aapits/atmain.c
305057
index 12232c9..62230ef 100644
305057
--- a/tests/aapits/atmain.c
305057
+++ b/tests/aapits/atmain.c
305057
@@ -345,7 +345,7 @@ ExecuteTest (
32dd66
     {
32dd66
         printf ("ACPICA API TS err: test num %ld of test case %ld"
32dd66
             " is not implemented\n",
32dd66
-            test_num, test_case);
32dd66
+            (long int) test_num, (long int) test_case);
32dd66
         return (AtRetNotImpl);
32dd66
     }
32dd66
 
305057
@@ -460,7 +460,7 @@ main(
32dd66
     if (test_case < 1 || test_case > AT_TEST_CASE_NUM)
32dd66
     {
32dd66
         printf ("ACPICA API TS err: test case %ld is out of range 1 - %d\n",
32dd66
-            test_case, AT_TEST_CASE_NUM);
32dd66
+            (long int) test_case, (int) AT_TEST_CASE_NUM);
32dd66
         return (AtRetBadParam);
32dd66
     }
32dd66
 
305057
@@ -468,7 +468,7 @@ main(
32dd66
     if (test_num < 0 || test_num > AtTestCase[test_case].TestsNum)
32dd66
     {
32dd66
         printf ("ACPICA API TS err: test num %ld is out of range 0 - %d\n",
32dd66
-            test_num, AtTestCase[test_case].TestsNum);
32dd66
+            (long int) test_num, AtTestCase[test_case].TestsNum);
32dd66
         return (AtRetBadParam);
32dd66
     }
305057
 
305057
diff --git a/tests/aapits/atnamespace.c b/tests/aapits/atnamespace.c
305057
index 06dd66d..9e0dcc1 100644
305057
--- a/tests/aapits/atnamespace.c
305057
+++ b/tests/aapits/atnamespace.c
305057
@@ -2535,7 +2535,8 @@ AtGetObjectInfoTypeCommon(
32dd66
 #else
32dd66
                 printf ("API Error: Address of %s (0x%llX) != (0x%llX)\n",
32dd66
                     PathNames[2 * i + 1],
32dd66
-                    Info->Address, ExpectedInfo[i].Address);
32dd66
+                    (long long unsigned int) Info->Address,
32dd66
+		    (long long unsigned int) ExpectedInfo[i].Address);
32dd66
 #endif
32dd66
 #else
32dd66
                 printf ("API Error: Address of %s (0x%X) != (0x%X)\n",
305057
@@ -2908,7 +2909,8 @@ AtGetNextObjectTypeCommon(
32dd66
         TestErrors++;
32dd66
         printf ("AtGetNextObjectTypeCommon: different numbers of entities"
32dd66
             "in TypesNames (%d) and LevelTypes0000 (%d)\n",
32dd66
-            TypesCount, sizeof (LevelTypes0000) / sizeof (ACPI_OBJECT_TYPE));
32dd66
+            TypesCount,
32dd66
+	    (int) (sizeof (LevelTypes0000) / sizeof (ACPI_OBJECT_TYPE)));
32dd66
         return (AE_ERROR);
32dd66
     }
32dd66
 
305057
@@ -4192,7 +4194,9 @@ AtCheckHandlePathMapping(
32dd66
             Pathname, Obj.Integer.Value, Value);
32dd66
 #else
32dd66
         printf ("API Error: Value of %s is 0x%llx instead of expected 0x%llx\n",
32dd66
-            Pathname, Obj.Integer.Value, Value);
32dd66
+            Pathname,
32dd66
+	    (long long unsigned int) Obj.Integer.Value,
32dd66
+	    (long long unsigned int) Value);
32dd66
 #endif
32dd66
         Status = AE_ERROR;
32dd66
     }
305057
@@ -5199,7 +5203,7 @@ AtGetNameExceptionTest(
32dd66
             {
32dd66
                 AapiErrors++;
32dd66
                 printf ("API Error: AcpiOsAllocate(%d) returned NULL\n",
32dd66
-                    OutName.Length);
32dd66
+                    (int) OutName.Length);
32dd66
                 return (AE_ERROR);
32dd66
             }
32dd66
         }
305057
diff --git a/tests/aapits/atosxfctrl.c b/tests/aapits/atosxfctrl.c
305057
index fe8b562..76f5310 100644
305057
--- a/tests/aapits/atosxfctrl.c
305057
+++ b/tests/aapits/atosxfctrl.c
305057
@@ -737,13 +737,15 @@ ACPI_OSXF_EMUL_REG
32dd66
 #if ACPI_MACHINE_WIDTH == 64
32dd66
 #ifdef    _MSC_VER
32dd66
         printf("OsxfCtrlFingReg: unexpected Width %d of Reg 0x%I64x\n",
32dd66
+            Width, Address);
32dd66
 #else
32dd66
         printf("OsxfCtrlFingReg: unexpected Width %d of Reg 0x%llx\n",
32dd66
+            Width, (long long unsigned int) Address);
32dd66
 #endif
32dd66
 #else
32dd66
         printf("OsxfCtrlFingReg: unexpected Width %d of Reg 0x%x\n",
32dd66
-#endif
32dd66
             Width, Address);
32dd66
+#endif
32dd66
         return (NULL);
32dd66
     }
32dd66
 
305057
@@ -764,15 +766,19 @@ ACPI_OSXF_EMUL_REG
32dd66
 #ifdef    _MSC_VER
32dd66
                 printf("OsxfCtrlFingReg: intersection Regs (0x%I64x: 0x%x)"
32dd66
                     " and (0x%I64x: 0x%x)\n",
32dd66
+                    Reg->Address, Reg->Width, Address, Width);
32dd66
 #else
32dd66
                 printf("OsxfCtrlFingReg: intersection Regs (0x%llx: 0x%x)"
32dd66
                     " and (0x%llx: 0x%x)\n",
32dd66
+                    (long long unsigned int) Reg->Address,
32dd66
+		    Reg->Width,
32dd66
+		    (long long unsigned int) Address, Width);
32dd66
 #endif
32dd66
 #else
32dd66
                 printf("OsxfCtrlFingReg: intersection Regs (0x%x: 0x%x)"
32dd66
                     " and (0x%x: 0x%x)\n",
32dd66
-#endif
32dd66
                     Reg->Address, Reg->Width, Address, Width);
32dd66
+#endif
32dd66
                 return (NULL);
32dd66
             }
32dd66
         }
305057
@@ -786,13 +792,15 @@ ACPI_OSXF_EMUL_REG
32dd66
 #if ACPI_MACHINE_WIDTH == 64
32dd66
 #ifdef    _MSC_VER
32dd66
             printf("OsxfCtrlFingReg: no memory for Reg (0x%I64x: 0x%x)\n",
32dd66
+                Reg->Address, Reg->Width);
32dd66
 #else
32dd66
             printf("OsxfCtrlFingReg: no memory for Reg (0x%llx: 0x%x)\n",
32dd66
+                (long long unsigned int) Reg->Address, Reg->Width);
32dd66
 #endif
32dd66
 #else
32dd66
             printf("OsxfCtrlFingReg: no memory for Reg (0x%x: 0x%x)\n",
32dd66
-#endif
32dd66
                 Reg->Address, Reg->Width);
32dd66
+#endif
32dd66
             return (NULL);
32dd66
         }
32dd66
         Reg->Type = Type;
305057
@@ -932,14 +940,19 @@ OsxfCtrlRegService(UINT32 ServiceFlag)
32dd66
 #if ACPI_MACHINE_WIDTH == 64
32dd66
 #ifdef    _MSC_VER
32dd66
             printf("%.2u (%s Address 0x%I64x: Width %.2u) r/w counts: %u/%u\n",
32dd66
+                i, (Reg->Type == EMUL_REG_SYS)? "SYS": "IO",
32dd66
+                Reg->Address, Reg->Width, Reg->ReadCount, Reg->WriteCount);
32dd66
 #else
32dd66
             printf("%.2u (%s Address 0x%llx: Width %.2u) r/w counts: %u/%u\n",
32dd66
+                i, (Reg->Type == EMUL_REG_SYS)? "SYS": "IO",
32dd66
+                (long long unsigned int) Reg->Address,
32dd66
+		Reg->Width, Reg->ReadCount, Reg->WriteCount);
32dd66
 #endif
32dd66
 #else
32dd66
             printf("%.2u (%s Address 0x%.4x: Width %.2u) r/w counts: %u/%u\n",
32dd66
-#endif
32dd66
                 i, (Reg->Type == EMUL_REG_SYS)? "SYS": "IO",
32dd66
                 Reg->Address, Reg->Width, Reg->ReadCount, Reg->WriteCount);
32dd66
+#endif
32dd66
             Reg = Reg->Next;
32dd66
             i++;
32dd66
         }
305057
diff --git a/tests/aapits/atresource.c b/tests/aapits/atresource.c
305057
index b13dc67..d0570f8 100644
305057
--- a/tests/aapits/atresource.c
305057
+++ b/tests/aapits/atresource.c
305057
@@ -174,7 +174,7 @@ AtRsrcTest0000(void)
32dd66
         AapiErrors++;
32dd66
         printf ("API Error: AcpiGetCurrentResources(%s) returned Length %d,"
32dd66
             " expected %d\n",
32dd66
-            Pathname, OutBuffer.Length, RT0000_DEV0_CRS_LEN);
32dd66
+            Pathname, (int) OutBuffer.Length, RT0000_DEV0_CRS_LEN);
32dd66
         return (AE_ERROR);
32dd66
     }
32dd66
 
305057
@@ -490,7 +490,7 @@ AtRsrcTest0005(void)
32dd66
         AapiErrors++;
32dd66
         printf ("API Error: AcpiGetCurrentResources(%s) returned Length %d,"
32dd66
             " expected %d\n",
32dd66
-            Pathname, OutBuffer.Length, RT0000_DEV0_CRS_LEN);
32dd66
+            Pathname, (int) OutBuffer.Length, RT0000_DEV0_CRS_LEN);
32dd66
         return (AE_ERROR);
32dd66
     }
32dd66
 
305057
@@ -689,7 +689,7 @@ AtRsrcTest0007(void)
32dd66
         AapiErrors++;
32dd66
         printf ("Api Error: Resource->Length (%d) != %d\n",
32dd66
             CurrentResource->Length,
32dd66
-            ACPI_ROUND_UP_TO_NATIVE_WORD (ACPI_RS_SIZE (ACPI_RESOURCE_IRQ)));
32dd66
+            (int) (ACPI_ROUND_UP_TO_NATIVE_WORD (ACPI_RS_SIZE (ACPI_RESOURCE_IRQ))));
32dd66
     }
32dd66
 
32dd66
     if (CurrentResource->Data.Irq.Triggering != 0) /* Level-Triggered */
305057
@@ -981,7 +981,7 @@ AtRsrcTest0012(void)
32dd66
         AapiErrors++;
32dd66
         printf ("API Error: AcpiGetPossibleResources(%s) returned Length %d,"
32dd66
             " expected %d\n",
32dd66
-            Pathname, OutBuffer.Length, RT0000_DEV0_CRS_LEN);
32dd66
+            Pathname, (int) OutBuffer.Length, RT0000_DEV0_CRS_LEN);
32dd66
         return (AE_ERROR);
32dd66
     }
32dd66
 
305057
@@ -1923,7 +1923,7 @@ AtRsrcTest0026(void)
32dd66
         AapiErrors++;
32dd66
         printf ("API Error: AcpiGetIrqRoutingTable(%s) returned Length %d,"
32dd66
             " expected %d\n",
32dd66
-            Pathname, OutBuffer.Length, 0xA48);
32dd66
+            Pathname, (int) OutBuffer.Length, 0xA48);
32dd66
         return (AE_ERROR);
32dd66
     }
32dd66