Skip to content

Commit 44eeb73

Browse files
committed
fix mp structures to be 64bit safe
The embedded pointer types caused them to grow in the 64bit build. Switch them over to 32bit integers so the structures remain correct.
1 parent 07a6397 commit 44eeb73

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

include/mp.h

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
struct mp { // floating pointer
44
uchar signature[4]; // "_MP_"
5-
void *physaddr; // phys addr of MP config table
5+
uint physaddr; // phys addr of MP config table
66
uchar length; // 1
77
uchar specrev; // [14]
88
uchar checksum; // all bytes must add up to 0
@@ -17,10 +17,10 @@ struct mpconf { // configuration table header
1717
uchar version; // [14]
1818
uchar checksum; // all bytes must add up to 0
1919
uchar product[20]; // product id
20-
uint *oemtable; // OEM table pointer
20+
uint oemtable; // OEM table pointer
2121
ushort oemlength; // OEM table length
2222
ushort entry; // entry count
23-
uint *lapicaddr; // address of local APIC
23+
uint lapicaddr; // address of local APIC
2424
ushort xlength; // extended table length
2525
uchar xchecksum; // extended table checksum
2626
uchar reserved;
@@ -42,7 +42,7 @@ struct mpioapic { // I/O APIC table entry
4242
uchar apicno; // I/O APIC id
4343
uchar version; // I/O APIC version
4444
uchar flags; // I/O APIC flags
45-
uint *addr; // I/O APIC address
45+
uint addr; // I/O APIC address
4646
};
4747

4848
// Table entry types

0 commit comments

Comments
 (0)