OpenCore  1.0.4
OpenCore Bootloader
Loading...
Searching...
No Matches
AppleSmBios.h
Go to the documentation of this file.
1
13#ifndef APPLE_SMBIOS_H
14#define APPLE_SMBIOS_H
15
16#include <IndustryStandard/SmBios.h>
17
18#pragma pack (1)
19
20#define APPLE_SMBIOS_TYPE_FIRMWARE_INFORMATION 128
21#define APPLE_SMBIOS_TYPE_MEMORY_SPD_DATA 130
22#define APPLE_SMBIOS_TYPE_PROCESSOR_TYPE 131
23#define APPLE_SMBIOS_TYPE_PROCESSOR_BUS_SPEED 132
24#define APPLE_SMBIOS_TYPE_PLATFORM_FEATURE 133
25#define APPLE_SMBIOS_TYPE_SMC_INFORMATION 134
26
27#define APPLE_NUMBER_OF_FLASHMAP_ENTRIES 8
28
29#define APPLE_SMBIOS_SMC_VERSION_SIZE 16
30
31// APPLE_REGION_TYPE
32enum {
39};
40
41typedef UINT8 APPLE_REGION_TYPE;
42
43// APPLE_FIRMWARE_REGION_INFO
44typedef PACKED struct {
46 UINT32 EndAddress;
48
49// APPLE_SMBIOS_TABLE_TYPE128
50typedef PACKED struct {
51 SMBIOS_STRUCTURE Hdr;
53 UINT8 Reserved[3];
61
62// APPLE_SMBIOS_TABLE_TYPE130
63typedef struct {
64 SMBIOS_STRUCTURE Hdr;
66 UINT16 Offset;
67 UINT16 Size;
68 UINT16 Data[];
70
71//
72// It might be that 0x01 was intended for Pentium, and 0x08 for Atom.
73// Reference binaries: AppleSmBios.efi and AppleSystemInfo.framework
74//
75// typedef struct {
76// UINT32 MajorType;
77// UINT32 MinorType;
78// UINT32 NumberOfCores;
79// CONST CHAR8 *MarketingName;
80// CONST CHAR8 *TechnicalName;
81// } PROCESSOR_INFO;
82//
83// The cpu types listed here originate from AppleSystemInfo.framework and are not
84// complete per se. The match of a certain CPU is firstly done by MajorType and
85// NumberOfCores, and MinorType does not need to match. For a more complete
86// table refer to AppleProcessorType enum, which is built based on Mac dumps.
87//
88// <0201> 01 cores Intel Core Solo Intel Core Solo
89// <0201> 02 cores Intel Core Duo Intel Core Duo
90// <0301> 01 cores Intel Core 2 Solo Intel Core 2 Solo
91// <0301> 02 cores Intel Core 2 Duo Intel Core 2 Duo
92// <0401> 01 cores Single-Core Intel Xeon Single-Core Intel Xeon
93// <0401> 02 cores Dual-Core Intel Xeon Dual-Core Intel Xeon
94// <0402> 01 cores Single-Core Intel Xeon Single-Core Intel Xeon
95// <0402> 02 cores Dual-Core Intel Xeon Dual-Core Intel Xeon
96// <0402> 03 cores Unknown Intel Xeon Unknown Intel Xeon
97// <0402> 04 cores Quad-Core Intel Xeon Quad-Core Intel Xeon
98// <0501> 01 cores Single-Core Intel Xeon Single-Core Intel Xeon
99// <0501> 02 cores Dual-Core Intel Xeon Dual-Core Intel Xeon
100// <0501> 03 cores Unknown Intel Xeon Unknown Intel Xeon
101// <0501> 04 cores Quad-Core Intel Xeon Quad-Core Intel Xeon
102// <0501> 06 cores 6-Core Intel Xeon 6-Core Intel Xeon
103// <0601> 01 cores Intel Core i5 Intel Core i5
104// <0601> 02 cores Intel Core i5 Intel Core i5
105// <0601> 03 cores Intel Core i5 Intel Core i5
106// <0601> 04 cores Intel Core i5 Intel Core i5
107// <0601> 06 cores Intel Core i5 Intel Core i5
108// <0701> 01 cores Intel Core i7 Intel Core i7
109// <0701> 02 cores Intel Core i7 Intel Core i7
110// <0701> 03 cores Intel Core i7 Intel Core i7
111// <0701> 04 cores Intel Core i7 Intel Core i7
112// <0701> 06 cores Intel Core i7 Intel Core i7
113// <0901> 01 cores Intel Core i3 Intel Core i3
114// <0901> 02 cores Intel Core i3 Intel Core i3
115// <0901> 03 cores Intel Core i3 Intel Core i3
116// <0901> 04 cores Intel Core i3 Intel Core i3
117// <0A01> 04 cores Quad-Core Intel Xeon E5 Quad-Core Intel Xeon E5
118// <0A01> 06 cores 6-Core Intel Xeon E5 6-Core Intel Xeon E5
119// <0A01> 08 cores 8-Core Intel Xeon E5 8-Core Intel Xeon E5
120// <0A01> 10 cores 10-Core Intel Xeon E5 10-Core Intel Xeon E5
121// <0A01> 12 cores 12-Core Intel Xeon E5 12-Core Intel Xeon E5
122// <0B01> 01 cores Intel Core M Intel Core M
123// <0B01> 02 cores Intel Core M Intel Core M
124// <0B01> 03 cores Intel Core M Intel Core M
125// <0B01> 04 cores Intel Core M Intel Core M
126// <0C01> 01 cores Intel Core m3 Intel Core m3
127// <0C01> 02 cores Intel Core m3 Intel Core m3
128// <0C01> 03 cores Intel Core m3 Intel Core m3
129// <0C01> 04 cores Intel Core m3 Intel Core m3
130// <0D01> 01 cores Intel Core m5 Intel Core m5
131// <0D01> 02 cores Intel Core m5 Intel Core m5
132// <0D01> 03 cores Intel Core m5 Intel Core m5
133// <0D01> 04 cores Intel Core m5 Intel Core m5
134// <0E01> 01 cores Intel Core m7 Intel Core m7
135// <0E01> 02 cores Intel Core m7 Intel Core m7
136// <0E01> 03 cores Intel Core m7 Intel Core m7
137// <0E01> 04 cores Intel Core m7 Intel Core m7
138// <0F01> 08 cores Intel Xeon W Intel Xeon W
139// <0F01> 10 cores Intel Xeon W Intel Xeon W
140// <0F01> 12 cores Intel Xeon W Intel Xeon W (10.15+)
141// <0F01> 14 cores Intel Xeon W Intel Xeon W
142// <0F01> 16 cores Intel Xeon W Intel Xeon W (10.15+)
143// <0F01> 18 cores Intel Xeon W Intel Xeon W
144// <0F01> 24 cores Intel Xeon W Intel Xeon W (10.15+)
145// <0F01> 28 cores Intel Xeon W Intel Xeon W (10.15+)
146// <1001> 06 cores Intel Core i9 Intel Core i9
147// <1001> 08 cores Intel Core i9 Intel Core i9 (10.15+)
148// <1001> 10 cores Intel Core i9 Intel Core i9 (10.15+)
149//
150// Also see here for a list of CPUs used on Mac models:
151// https://docs.google.com/spreadsheets/d/1x09b5-DGh8ozNwN5ZjAi7TMnOp4TDm6DbmrKu86i_bQ
152//
153
154//
155// Apple Processor Type Information - Processor Types.
156//
157enum {
162 AppleProcessorTypeXeonPenrynType1 = 0x0401, // may not be used
166
170
174
178
182
183 AppleProcessorTypeCorei5Type5 = 0x0605, // NOTE: we are putting 0x0609 on IM191 (i5-8600), although it should be 0x0605.
186
187 AppleProcessorTypeCorei5Type6 = 0x0606, // i5 5250U (iMac16,1, MacBookAir7,1 and 7,2), i5 5675R (iMac16,2), i5 5257U (MacBookPro12,1)
188 AppleProcessorTypeCorei7Type6 = 0x0706, // ideal value for Broadwell i7, need confirmation
189 AppleProcessorTypeCorei3Type6 = 0x0906, // ideal value for Broadwell i3, need confirmation
190
191 // placeholder for i5Type7 (maybe 0x0607 ???)
192 AppleProcessorTypeCorei7Type7 = 0x0707, // i7 6700HQ (MacBookPro13,3)
193 // placeholder for i3Type7 (maybe 0x0907 ???)
194
195 AppleProcessorTypeCorei5Type8 = 0x0608, // i5 8210Y (MacBookAir8,1)
196 // placeholder for i7Type8 (maybe 0x0708 ???)
197 // placeholder for i3Type8 (maybe 0x0908 ???)
198
199 AppleProcessorTypeCorei5Type9 = 0x0609, // i5 8259U (MacBookPro15,2), i5 8500B (Macmini8,1)
200 AppleProcessorTypeCorei7Type9 = 0x0709, // i7 8850H (MacBookPro15,1), i7 8700B (Macmini8,1)
201 // placeholder for i3Type9 (maybe 0x0909 ???)
202
203 AppleProcessorTypeCoreMType1 = 0x0B01, // may not be used
204 AppleProcessorTypeCoreMType6 = 0x0B06, // M 5Y51 (MacBook8,1)
205
206 AppleProcessorTypeCoreM3Type1 = 0x0C01, // may not be used
207 AppleProcessorTypeCoreM3Type7 = 0x0C07, // m3-7Y32 (MacBook10,1)
208
209 AppleProcessorTypeCoreM5Type1 = 0x0D01, // may not be used
210 AppleProcessorTypeCoreM5Type7 = 0x0D07, // m5-6Y54 (MacBook9,1)
211
212 AppleProcessorTypeCoreM7Type1 = 0x0E01, // may not be used
213 AppleProcessorTypeCoreM7Type7 = 0x0E07, // might be used on Core m7 (SKL), need confirmation
214
215 AppleProcessorTypeXeonW = 0x0F01, // iMacPro1,1
216
217 AppleProcessorTypeCorei9Type1 = 0x1001, // may not be used
218 AppleProcessorTypeCorei9Type5 = 0x1005, // SKL-X i9, most likely to be invalid!
219 AppleProcessorTypeCorei9Type9 = 0x1009 // i9 9980HK (MacBookPro16,1)
221
222// APPLE_PROCESSOR_TYPE_CLASS
223
224enum {
241
242typedef struct {
246
251
252// APPLE_SMBIOS_TABLE_TYPE131
253typedef PACKED struct {
254 SMBIOS_STRUCTURE Hdr;
256 UINT8 Reserved[2];
258
259// APPLE_SMBIOS_TABLE_TYPE132
260typedef struct {
261 SMBIOS_STRUCTURE Hdr;
264
265// APPLE_SMBIOS_TABLE_TYPE133
266typedef struct {
267 SMBIOS_STRUCTURE Hdr;
270
271// APPLE_SMBIOS_TABLE_TYPE134
272typedef PACKED struct {
273 SMBIOS_STRUCTURE Hdr;
276
277// APPLE_SMBIOS_STRUCTURE_POINTER
288
289#pragma pack ()
290
291#endif // APPLE_SMBIOS_H
APPLE_FIRMWARE_REGION_INFO FlashMap[APPLE_NUMBER_OF_FLASHMAP_ENTRIES]
Definition AppleSmBios.h:57
PACKED struct @35 APPLE_FIRMWARE_REGION_INFO
#define APPLE_SMBIOS_SMC_VERSION_SIZE
Definition AppleSmBios.h:29
@ AppleProcessorTypeXeonW
@ AppleProcessorTypeCorei5Type9
@ AppleProcessorTypeCorei3Type1
@ AppleProcessorTypeCorei5Type3
@ AppleProcessorTypeCorei3Type4
@ AppleProcessorTypeCorei7Type7
@ AppleProcessorTypeCorei7Type4
@ AppleProcessorTypeCorei7Type1
@ AppleProcessorTypeCorei5Type8
@ AppleProcessorTypeXeonE5
@ AppleProcessorTypeCorei7Type9
@ AppleProcessorTypeCoreMType6
@ AppleProcessorTypeCore2DuoType2
@ AppleProcessorTypeCorei7Type5
@ AppleProcessorTypeCorei5Type2
@ AppleProcessorTypeCorei7Type3
@ AppleProcessorTypeCoreM5Type7
@ AppleProcessorTypeCoreM7Type1
@ AppleProcessorTypeCoreMType1
@ AppleProcessorTypeCoreSolo
@ AppleProcessorTypeCore2DuoType1
@ AppleProcessorTypeCorei9Type5
@ AppleProcessorTypeCorei5Type1
@ AppleProcessorTypeCorei3Type3
@ AppleProcessorTypeCorei7Type2
@ AppleProcessorTypeXeonPenrynType1
@ AppleProcessorTypeCoreM5Type1
@ AppleProcessorTypeXeon
@ AppleProcessorTypeCorei5Type6
@ AppleProcessorTypeCorei3Type2
@ AppleProcessorTypeCorei9Type9
@ AppleProcessorTypeCoreM3Type7
@ AppleProcessorTypeCoreM7Type7
@ AppleProcessorTypeCorei3Type6
@ AppleProcessorTypeXeonPenrynType2
@ AppleProcessorTypeCorei9Type1
@ AppleProcessorTypeCorei5Type5
@ AppleProcessorTypeCorei5Type4
@ AppleProcessorTypeUnknown
@ AppleProcessorTypeCoreM3Type1
@ AppleProcessorTypeCorei3Type5
@ AppleProcessorTypeCorei7Type6
APPLE_PROCESSOR_TYPE ProcessorType
UINT32 StartAddress
Definition AppleSmBios.h:45
UINT8 Reserved[3]
Definition AppleSmBios.h:53
@ AppleProcessorMajorI5
@ AppleProcessorMajorXeonPenryn
@ AppleProcessorMajorXeonNehalem
@ AppleProcessorMajorUnknown
@ AppleProcessorMajorCore
@ AppleProcessorMajorXeonE5
@ AppleProcessorMajorI7
@ AppleProcessorMajorCore2
@ AppleProcessorMajorM
@ AppleProcessorMajorM5
@ AppleProcessorMajorM3
@ AppleProcessorMajorM7
@ AppleProcessorMajorI3
@ AppleProcessorMajorI9
@ AppleProcessorMajorXeonW
UINT8 NumberOfRegions
Definition AppleSmBios.h:52
PACKED struct @39 APPLE_SMBIOS_TABLE_TYPE131
#define APPLE_NUMBER_OF_FLASHMAP_ENTRIES
Definition AppleSmBios.h:27
UINT8 SmcVersion[APPLE_SMBIOS_SMC_VERSION_SIZE]
UINT32 FirmwareFeatures
Definition AppleSmBios.h:54
@ AppleRegionTypeNvram
Definition AppleSmBios.h:36
@ AppleRegionTypeMain
Definition AppleSmBios.h:35
@ AppleRegionTypeConfig
Definition AppleSmBios.h:37
@ AppleRegionTypeRecovery
Definition AppleSmBios.h:34
@ AppleRegionTypeDiagvault
Definition AppleSmBios.h:38
@ AppleRegionTypeReserved
Definition AppleSmBios.h:33
UINT32 FirmwareFeaturesMask
Definition AppleSmBios.h:55
PACKED struct @36 APPLE_SMBIOS_TABLE_TYPE128
PACKED struct @40 APPLE_SMBIOS_TABLE_TYPE134
UINT8 APPLE_REGION_TYPE
Definition AppleSmBios.h:41
APPLE_REGION_TYPE RegionTypeMap[APPLE_NUMBER_OF_FLASHMAP_ENTRIES]
Definition AppleSmBios.h:56
SMBIOS_STRUCTURE Hdr
Definition AppleSmBios.h:51
UINT32 ExtendedFirmwareFeaturesMask
Definition AppleSmBios.h:59
UINT32 EndAddress
Definition AppleSmBios.h:46
UINT32 ExtendedFirmwareFeatures
Definition AppleSmBios.h:58
APPLE_PROCESSOR_TYPE_INFO Detail
APPLE_SMBIOS_TABLE_TYPE134 * Type134
APPLE_SMBIOS_TABLE_TYPE132 * Type132
SMBIOS_STRUCTURE_POINTER Standard
APPLE_SMBIOS_TABLE_TYPE128 * Type128
APPLE_SMBIOS_TABLE_TYPE133 * Type133
APPLE_SMBIOS_TABLE_TYPE131 * Type131
APPLE_SMBIOS_TABLE_TYPE130 * Type130