Index: branches/cparm/doc/ModuleHelp.txt =================================================================== --- branches/cparm/doc/ModuleHelp.txt (revision 1675) +++ branches/cparm/doc/ModuleHelp.txt (revision 1676) @@ -65,6 +65,9 @@ if smbios.plist doesn't exist, factory values are kept(Disabled by default). + randomSerial=Yes|No Generate a machine serial number randomly, can be useful + for iCloud registration(Disabled by default). + RamDiskLoader module: -------------------- EnableRamDiskLoader=Yes|No Fully enable/disable the RamDiskLoader module (Enabled by default, if the module is installed) @@ -114,6 +117,8 @@ GenerateCStates=Yes|No Enable/Disable Generate C-states SSDT table (Disabled by default). EnableC4State=Yes|No Enable C4 state in C-states SSDT table, GenerateCStates=Yes is needed (Disabled by default). + StripAPICTable=Yes|No Enable/Disable Generate a stripped MADT (APIC) table (Enabled by default). + IntelFADTSpec=Yes|No Enable/Disable Intel recommendations for the FADT table (Enabled by default). Warning : When enabled, this setting disable the C2 and C3 C-states, but be aware that these are the Intel's recommendations for the newest CPU, if you really need those c-states please disable IntelFADTSpec. Index: branches/cparm/i386/modules/ACPICodec/acpi_codec.c =================================================================== --- branches/cparm/i386/modules/ACPICodec/acpi_codec.c (revision 1675) +++ branches/cparm/i386/modules/ACPICodec/acpi_codec.c (revision 1676) @@ -210,7 +210,7 @@ #define ACPI_TABLE_LIST_FULL_NON_RESERVED MAX_ACPI_TABLE + 1 -#define ULONG_MAX_32 4294967295UL +//#define ULONG_MAX_32 4294967295UL #define __RES(s, u) \ inline unsigned u \ @@ -377,7 +377,7 @@ U64 ptr = xsdt->TableOffsetEntry[index]; { - if (ptr > ULONG_MAX_32) + if (ptr > ULONG_MAX) { #if DEBUG_ACPI printf("Warning xsdt->TableOffsetEntry[%d]: Beyond addressable memory in this CPU mode, ignored !!!\n",index); @@ -2866,8 +2866,11 @@ { // Process sub-tables with Type as 4: Local APIC NMI ACPI_MADT_LOCAL_APIC_NMI *nmi = current; - current = nmi + 1; + current = nmi + 1; + if (!(nmi->IntiFlags & ACPI_MADT_ENABLED)) + continue; + if (LOCAL_APIC_NMI_CNT >= nb_cpu) continue; @@ -2900,6 +2903,9 @@ ACPI_MADT_LOCAL_SAPIC *sapic = current; current = sapic + 1; + if (!(sapic->LapicFlags & ACPI_MADT_ENABLED)) + continue; + if (LOCAL_SAPIC_CNT >= nb_cpu) continue; @@ -2932,6 +2938,9 @@ ACPI_MADT_INTERRUPT_SOURCE *intsrc = current; current = intsrc + 1; + if (!(intsrc->IntiFlags & ACPI_MADT_ENABLED)) + continue; + if (INT_SRC_CNT >= nb_cpu) continue; @@ -3024,7 +3033,7 @@ { MadtPointer = (ACPI_TABLE_MADT *)madt_file; - new_table_list[new_table_index] = 0ul; // This way, the non-patched table will not be added in our new rsdt/xsdt table list // note: for now we don't patch this table + new_table_list[new_table_index] = 0ul; // This way, the non-patched table will not be added in our new rsdt/xsdt table list } else { @@ -4899,7 +4908,7 @@ U64 ptr = xsdt->TableOffsetEntry[index]; { - if (ptr > ULONG_MAX_32) + if (ptr > ULONG_MAX) { #if DEBUG_ACPI printf("Warning xsdt->TableOffsetEntry[%d]: Beyond addressable memory in this CPU mode, ignored !!!\n",index);