Chameleon

Chameleon Commit Details

Date:2017-01-14 11:32:23 (3 years 9 months ago)
Author:ErmaC
Commit:2842
Parents: 2841
Message:General update
Changes:
M/trunk/i386/libsaio/hda.h
M/branches/ErmaC/Enoch/i386/libsaio/hda.c
M/branches/ErmaC/Enoch/i386/libsaio/hda.h
M/trunk/i386/boot2/boot.c
M/trunk/i386/libsaio/nvidia.c
M/branches/ErmaC/Enoch/i386/boot2/boot.c
M/trunk/i386/libsaio/ati.c
M/branches/ErmaC/Enoch/i386/libsaio/nvidia.c
M/branches/ErmaC/Enoch/i386/libsaio/ati.c
M/trunk/i386/libsaio/acpi_patcher.c
M/trunk/i386/libsaio/ati.h
M/branches/ErmaC/Enoch/i386/libsaio/acpi_patcher.c
M/branches/ErmaC/Enoch/i386/libsaio/ati.h
M/trunk/i386/libsaio/cpu.c
M/trunk/i386/libsaio/smbios_getters.c
M/trunk/i386/libsaio/platform.h
M/branches/ErmaC/Enoch/i386/libsaio/cpu.c
M/trunk/i386/libsaio/hda.c
M/branches/ErmaC/Enoch/i386/libsaio/platform.h
M/branches/ErmaC/Enoch/i386/libsaio/smbios_getters.c

File differences

trunk/i386/libsaio/acpi_patcher.c
1616
1717
1818
19
20
19
20
2121
2222
2323
#include "state_generator.h"
#ifndef DEBUG_ACPI
#define DEBUG_ACPI 0
#endif
#define DEBUG_ACPI 0
#endif
#if DEBUG_ACPI==2
#define DBG(x...) {printf(x); sleep(1);}
trunk/i386/libsaio/hda.c
184184
185185
186186
187
188
187189
188190
189191
......
625627
626628
627629
628
630
629631
630632
631633
632634
633635
634
636
635637
636638
637639
......
656658
657659
658660
659
661
660662
661663
662664
{ HDA_NVIDIA_GK106,"GK106" /*, 0, ? */ },
{ HDA_NVIDIA_GK107,"GK107" /*, 0, ? */ },
{ HDA_NVIDIA_GK104,"GK104" /*, 0, ? */ },
{ HDA_NVIDIA_GP104_2,"Pascal GP104-200" /*, 0, ? */ },
{ HDA_NVIDIA_GM204_2,"Maxwell GP204-200" /*, 0, ? */ },
//1002 Advanced Micro Devices [AMD] nee ATI Technologies Inc
{ HDA_ATI_SB450,"SB4x0" /*, 0, 0 */ },
name_format = "ATI %s HDA Controller (HDMi)"; break;
case INTEL_VENDORID:
name_format = "Intel %s High Definition Audio Controller"; break;
name_format = "Intel %s HDA Controller"; break;
case NVIDIA_VENDORID:
name_format = "nVidia %s HDA Controller (HDMi)"; break;
case RDC_VENDORID:
name_format = "RDC %s High Definition Audio Controller"; break;
name_format = "RDC %s HDA Controller"; break;
case SIS_VENDORID:
name_format = "SiS %s HDA Controller"; break;
}
/* Not in table */
snprintf(desc, sizeof(desc), "Unknown HD Audio device, vendor %04x, model %04x",
snprintf(desc, sizeof(desc), "Unknown HDA device, vendor %04x, model %04x",
controller_vendor_id, controller_device_id);
return desc;
}
trunk/i386/libsaio/hda.h
171171
172172
173173
174
175
174176
175177
176178
#define HDA_NVIDIA_GK106HDA_MODEL_CONSTRUCT(NVIDIA, 0x0e0b)
#define HDA_NVIDIA_GK110HDA_MODEL_CONSTRUCT(NVIDIA, 0x0e1a)
#define HDA_NVIDIA_GK107HDA_MODEL_CONSTRUCT(NVIDIA, 0x0e1b) // HDACodec de104200 (10de0042)
#define HDA_NVIDIA_GP104_2 HDA_MODEL_CONSTRUCT(NVIDIA, 0x10f0) // GeForce GTX 1070
#define HDA_NVIDIA_GM204_2 HDA_MODEL_CONSTRUCT(NVIDIA, 0x0fbb) // GeForce GTX 970
#define HDA_NVIDIA_ALLHDA_MODEL_CONSTRUCT(NVIDIA, 0xffff)
/* ATI */
trunk/i386/libsaio/nvidia.c
821821
822822
823823
824
824
825825
826826
827827
......
847847
848848
849849
850
850
851851
852852
853853
......
911911
912912
913913
914
914
915915
916916
917917
......
943943
944944
945945
946
946
947947
948948
949949
......
12941294
12951295
12961296
1297
12971298
12981299
12991300
......
13191320
13201321
13211322
1323
1324
1325
1326
1327
1328
1329
13221330
13231331
13241332
......
13311339
13321340
13331341
1342
1343
13341344
13351345
13361346
1337
1347
1348
1349
1350
1351
13381352
13391353
13401354
......
13491363
13501364
13511365
1352
1353
1366
1367
1368
1369
1370
1371
1372
1373
1374
13541375
1355
1376
1377
1378
1379
1380
1381
13561382
13571383
13581384
13591385
13601386
13611387
1388
1389
1390
13621391
13631392
1393
13641394
13651395
13661396
......
13761406
13771407
13781408
1379
1409
13801410
13811411
1382
1412
13831413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
13841444
13851445
13861446
{ 0x10DE0A2A,"GeForce GT 230M" },
{ 0x10DE0A2B,"GeForce GT 330M" },
{ 0x10DE0A2C,"NVS 5100M" },
{ 0x10DE0A2D,"GeForce GT 320M" },
{ 0x10DE0A2D,"GeForce GT 320M" },
// 0A30 - 0A3F
{ 0x10DE0A30,"GeForce GT 330M" },
{ 0x10DE0A32,"GeForce GT 415" },
{ 0x10DE0A6A,"NVS 2100M" },
{ 0x10DE0A6C,"NVS 3100M" },
{ 0x10DE0A6E,"GeForce 305M" },
{ 0x10DE0A6F,"ION" },
{ 0x10DE0A6F,"ION" },
// 0A70 - 0A7F
{ 0x10DE0A70,"GeForce 310M" },
{ 0x10DE0A71,"GeForce 305M" },
{ 0x10DE0CAD,"N10E-ES" }, // SUBIDS
{ 0x10DE0CAE,"GT215-INT" },
{ 0x10DE0CAF,"GeForce GT 335M" },
// 0CB0 - 0CBF
// 0CB0 - 0CBF
{ 0x10DE0CB0,"GeForce GTS 350M" },
{ 0x10DE0CB1,"GeForce GTS 360M" },
{ 0x10DE0CBC,"Quadro FX 1800M" },
{ 0x10DE0DCD,"GeForce GT 555M" },
{ 0x10DE0DCE,"GeForce GT 555M" },
// { 0x10DE0DCF,"N12P-GT-B" },
// 0DD0 - 0DDF
// 0DD0 - 0DDF
{ 0x10DE0DD0,"N11E-GT" },
{ 0x10DE0DD1,"GeForce GTX 460M" },
{ 0x10DE0DD2,"GeForce GT 445M" },
{ 0x10DE1286,"GeForce GT 720" },
{ 0x10DE1287,"GeForce GT 730" }, // GK208
{ 0x10DE1288,"GeForce GT 720" }, // GK208
{ 0x10DE128b,"GeForce GT 710" },
// 1290 - 129F
{ 0x10DE1290,"GeForce GT 730M" },
{ 0x10DE1291,"GeForce GT 735M" },
{ 0x10DE1341,"GeForce 840M" },
{ 0x10DE1346,"GeForce 930M" }, // GM108M
{ 0x10DE1347,"GeForce 940M" }, // GM108M
{ 0x10DE1348,"GeForce 945M/945A" }, // GM108M
{ 0x10DE1349,"GeForce 930M" }, // GM108M
{ 0x10DE134D,"GeForce 940MX" }, // GM108M
{ 0x10DE134E,"GeForce 930MX" }, // GM108M
{ 0x10DE134F,"GeForce 920MX" }, // GM108M
{ 0x10DE137A,"Quadro K620M/M500M" }, // GM108GLM
{ 0x10DE137D,"GeForce 940A" }, // GM108M
{ 0x10DE1380,"GeForce GTX 750 Ti" },
{ 0x10DE1381,"GeForce GTX 750" },
{ 0x10DE1382,"GeForce GTX 745" },
{ 0x10DE1398,"GeForce 845M" }, //
{ 0x10DE139A,"GeForce GTX 950M" }, // GM107
{ 0x10DE139B,"GeForce GTX 960M" }, // GM107
{ 0x10DE139C,"GeForce 940M" }, // GM107M
{ 0x10DE139D,"GeForce GTX 750 Ti" }, // GM107M
{ 0x10DE13AD,"GM107 INT52" }, //
{ 0x10DE13AE,"GM107 CS1" }, //
//{ 0x10DE13AF,"Graphics Device" }, // GM107GLM
{ 0x10DE13B3,"Quadro K2200M" }, //
{ 0x10DE13B0,"GQuadro M2000M" }, // GM107GLM
{ 0x10DE13B1,"Quadro M1000M" }, // GM107GLM
{ 0x10DE13B2,"Quadro M600M" }, // GM107GLM
{ 0x10DE13B3,"Quadro K2200M" }, // GM107GLM
{ 0x10DE13B9,"NVS 810" }, // GM107GL
{ 0x10DE13BA,"Quadro K2200" },
{ 0x10DE13BB,"Quadro K620" },
{ 0x10DE13BC,"Quadro K1200" },
{ 0x10DE13D7,"GeForce GTX 980M" }, //
{ 0x10DE13D8,"GeForce GTX 970M" }, //
{ 0x10DE13D9,"GeForce GTX 965M" },
//{ 0x10DE13F0,"Graphics Device" }, // GM107GLM
//{ 0x10DE13F1,"Graphics Device" }, // GM107GLM
{ 0x10DE13DA,"GeForce GTX 980" }, // GM204M
{ 0x10DE13F0,"Quadro M5000" }, // GM204GL
{ 0x10DE13F1,"Quadro M4000" }, // GM204GL
{ 0x10DE13F2,"Tesla M60" }, // GM204GL
{ 0x10DE13F3,"Tesla M6" }, // GM204GL
{ 0x10DE13F8,"Quadro M5000M" }, // GM204GLM
{ 0x10DE13F9,"Quadro M4000M" }, // GM204GLM
{ 0x10DE13FA,"Quadro M3000M" }, // GM204GLM
{ 0x10DE13FB,"Quadro M5500" }, // GM204GLM
{ 0x10DE1401,"GeForce GTX 960" }, //
//{ 0x10DE1402,"Graphics Device" }, //
{ 0x10DE1402,"GeForce GTX 950" }, //
{ 0x10DE1406,"GeForce GTX 960" }, // GM206
{ 0x10DE1407,"GeForce GTX 750 v2" }, // GM206
{ 0x10DE1427,"GeForce GTX 965M" }, // GM206M
{ 0x10DE1430,"Quadro M2000" }, //
{ 0x10DE1431,"Tesla M4" }, // GM206GL
//{ 0x10DE143F,"Graphics Device" }, //
//{ 0x10DE1600,"Graphics Device" }, //
//{ 0x10DE1601,"Graphics Device" }, //
//{ 0x10DE1602,"Graphics Device" }, //
//{ 0x10DE1603,"Graphics Device" }, //
{ 0x10DE1617,"GeForce GTX 980M" }, //
{ 0x10DE1618,"GeForce GTX 970M" }, // GM204M
{ 0x10DE1619,"GeForce GTX 965M" }, // GM204M
{ 0x10DE161A,"GeForce GTX 980" }, // GM204M
//{ 0x10DE1630,"Graphics Device" }, //
//{ 0x10DE1631,"Graphics Device" }, //
{ 0x10DE1667,"GeForce GTX 965M" }, // GM204M
//{ 0x10DE1780,"Graphics Device" }, //
//{ 0x10DE1781,"Graphics Device" }, //
//{ 0x10DE1782,"Graphics Device" }, //
{ 0x10DE17BE,"GM107 CS1" }, // GM107
//{ 0x10DE17C1,"Graphics Device" }, //
{ 0x10DE17C2,"GeForce GTX Titan X" }, //
{ 0x10DE17C8,"GeForce GTX 980 TI" },
{ 0x10DE17C8,"GeForce GTX 980 TI" }, //
//{ 0x10DE17EE,"Graphics Device" }, //
//{ 0x10DE17EF,"Graphics Device" }, //
{ 0x10DE17F0,"Quadro M6000" }
{ 0x10DE17F0,"Quadro M6000" },
//{ 0x10DE17FF,"Graphics Device" }, //
{ 0x10DE17F1,"Quadro M6000" }, // GM200GL
{ 0x10DE17FD,"Tesla M40" }, // GM200GL
// 1B00 - 1CFFF
{ 0x10DE1B00, "Titan X Pascal"}, // GP102
//{ 0x10DE1B01,"Graphics Device" }, // GP102
{ 0x10DE1B30,"Quadro P6000" }, // GP102GL
//{ 0x10DE1B70,"Graphics Device" }, // GP102GL
//{ 0x10DE1B78,"Graphics Device" }, // GP102GL
{ 0x10DE1B80, "GeForce GTX 1080"}, // GP104
{ 0x10DE1B81, "GeForce GTX 1070"}, // GP104
//{ 0x10DE1B82,"Graphics Device" }, // GP104
//{ 0x10DE1B83,"Graphics Device" }, // GP104
{ 0x10DE1BA0,"GeForce GTX 1080" }, // GP104M
{ 0x10DE1BA1,"GeForce GTX 1070" }, // GP104M
{ 0x10DE1BB0,"Quadro P5000" }, // GP104GL
//{ 0x10DE1BB1,"Graphics Device" }, // GP104GL
//{ 0x10DE1BB4,"Graphics Device" }, // GP104GL
{ 0x10DE1BE0,"GeForce GTX 1080" }, //GP104M
{ 0x10DE1BE1,"GeForce GTX 1070" }, //GP104M
//{ 0x10DE1C00,"Graphics Device" }, // GP106
//{ 0x10DE1C01,"Graphics Device" }, // GP106
{ 0x10DE1C02, "GeForce GTX 1060"}, // GP106
{ 0x10DE1C03, "GeForce GTX 1060"}, // GP106
{ 0x10DE1c20,"GeForce GTX 1060" }, //GP106M
//{ 0x10DE1C30,"Graphics Device" }, // GP106GL
{ 0x10DE1C60,"GeForce GTX 1060" }, // GP106M
//{ 0x10DE1C70,"Graphics Device" }, // GP106GL
//{ 0x10DE1C80,"Graphics Device" }, // GP107
//{ 0x10DE1C81,"Graphics Device" }, // GP107
{ 0x10DE1C82,"GeForce GTX 1050 Ti"}, // GP107
};
static nvidia_card_info_t nvidia_card_exceptions[] = {
trunk/i386/libsaio/ati.c
6363
6464
6565
66
66
6767
6868
69
69
7070
7171
7272
......
8484
8585
8686
87
88
8789
8890
8991
......
9395
9496
9597
96
98
9799
98100
99101
......
105107
106108
107109
108
110
111
112
113
114
109115
110116
111
117
118
119
120
121
122
123
124
125
112126
113127
114128
......
12091223
12101224
12111225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
12121249
12131250
12141251
......
13091346
13101347
13111348
1312
1349
13131350
13141351
13151352
......
13221359
13231360
13241361
1325
1326
1362
1363
13271364
13281365
13291366
......
17671804
17681805
17691806
1807
17701808
17711809
17721810
......
17881826
17891827
17901828
1791
1829
17921830
17931831
1832
1833
1834
1835
1836
17941837
17951838
17961839
{"Galago",2},
{"Colobus",2},
{"Mangabey",2},
{"Nomascus",4}, // 5
{"Nomascus",5},
{"Orangutan",2},
/* AMD6000Controller */
{"Pithecia",2}, // 3
{"Pithecia",3},
{"Bulrushes",6},
{"Cattail",4},
{"Hydrilla",5},
{"Spikerush", 4},
{"Typha", 5},
/* AMD7000Controller */
{"Ramen",6},
{"Tako",6},
{"Namako",4},
{"Aji",4},
{"Buri",4},
{"Gari",5},
{"Futomaki",5},
{"Hamachi",4},
{"OPM", 6},
{"OPM", 5},
{"Ikura",1},
{"IkuraS",6},
{"Junsai",6},
/* AMD8000Controller */
{"Baladi", 6},
/* AMD9000Controller */
{"Exmoor",4},
{"Exmoor",6},
{"MalteseS",1},
{"Lagotto",4},
{"GreyhoundS",1},
{"Maltese",6},
{"Basset",4},
{"Greyhound",6},
{"Labrador",6}
{"Labrador",6},
/* AMD9500Controller */
{"Elqui",5},
{"Acre",3},
{"Berbice",5},
{"Caroni",5},
{"Florin",6},
{"Dayman",6},
{"Guariba",6}
};
static radeon_card_info_t radeon_cards[] = {
//{ 0x67BA,0x00000000, CHIP_FAMILY_HAWAII,"AMD Radeon", kFutomaki},
//{ 0x67BE,0x00000000, CHIP_FAMILY_HAWAII,"AMD Radeon", kFutomaki},
// Polaris 10
{ 0x67C0, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C1, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C2, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C4, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C7, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C8, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C9, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67CA, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67CC, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67CF, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67DF, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon RX480", kDayman },
// Polaris 11
{ 0x67E0, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon RX460", kAcre },
{ 0x67E1, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67E3, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67E7, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67E8, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67E9, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67EB, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67EF, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon RX460", kAcre },
{ 0x67FF, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
// PITCAIRN
{ 0x6800,0x00000000, CHIP_FAMILY_PITCAIRN,"AMD Radeon HD 7970M",kBuri}, // Mobile
{ 0x6801,0x00000000, CHIP_FAMILY_PITCAIRN,"AMD Radeon HD 8970M Series",kFutomaki}, // Mobile
// CEDAR
{ 0x68E0,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD 5470 Series",kGalago},
{ 0x68E1,0x00000000, CHIP_FAMILY_CEDAR,"AMD Radeon HD 6230",kGalago},
{ 0x68E1,0x00000000, CHIP_FAMILY_CEDAR,"AMD Radeon HD 6230/6350/8350",kGalago},
{ 0x68E4,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD 6370M Series",kGalago},
{ 0x68E5,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD 6300M Series",kGalago},
//{ 0x68E8,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD ??? Series",kNull},
//{ 0x68FE,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD ??? Series",kNull},
//
{ 0x6900,0x00000000, CHIP_FAMILY_TOPAS,"ATI Radeon R7 M260/M265", kExmoor},
{ 0x6901,0x00000000, CHIP_FAMILY_TOPAS,"ATI Radeon R5 M255", kExmoor},
{ 0x6900,0x00000000, CHIP_FAMILY_TOPAZ,"ATI Radeon R7 M260/M265", kExmoor},
{ 0x6901,0x00000000, CHIP_FAMILY_TOPAZ,"ATI Radeon R5 M255", kExmoor},
{ 0x6920,0x00000000, CHIP_FAMILY_AMETHYST,"ATI Radeon R9 M395X", kLabrador},
{ 0x6921,0x00000000, CHIP_FAMILY_AMETHYST,"ATI Radeon R9 M295X", kExmoor},
{ 0x692B,0x00000000, CHIP_FAMILY_TONGA,"ATI Firepro W7100", kBaladi},
"Hemlock",
"Juniper",
"Redwood",
// "Broadway",
/* Northern Islands */
"Barts",
"Caicos",
"Hawaii",
/* ... */
"Mullins",
"Topas",
"Topaz",
"Amethyst",
"Tonga",
"Fiji",
"Carrizo",
"Tobago",
"Ellesmere",
"Baffin",
""
};
trunk/i386/libsaio/ati.h
9999
100100
101101
102
102
103103
104104
105
106
107
108
109
105110
106111
107112
......
172177
173178
174179
180
181
175182
176183
177184
......
194201
195202
196203
204
205
206
207
197208
198209
199210
211
212
213
214
215
216
217
218
200219
201220
202221
CHIP_FAMILY_HAWAII,
/* ... */
CHIP_FAMILY_MULLINS,
CHIP_FAMILY_TOPAS,
CHIP_FAMILY_TOPAZ,
CHIP_FAMILY_AMETHYST,
CHIP_FAMILY_TONGA,
CHIP_FAMILY_FIJI,
CHIP_FAMILY_CARRIZO,
CHIP_FAMILY_TOBAGO,
CHIP_FAMILY_ELLESMERE, /* Polaris 10 */
CHIP_FAMILY_BAFFIN, /* Polaris 11 */
CHIP_FAMILY_LAST
} ati_chip_family_t;
kSpikerush,
kTypha,
/* AMD7000Controller */
kRamen,
kTako,
kNamako,
kAji,
kBuri,
kBaladi,
/* AMD9000Controller */
kExmoor,
kMalteseS,
kLagotto,
kGreyhoundS,
kMaltese,
kBasset,
kGreyhound,
kLabrador,
/* AMD9500Controller */
kElqui,
kAcre,
kBerbice,
kCaroni,
kFlorin,
kDayman,
kGuariba,
kCfgEnd
} config_name_t;
trunk/i386/libsaio/cpu.c
2020
2121
2222
23
2423
2524
2625
......
590589
591590
592591
592
593593
594594
595595
596
597596
598597
599598
599
600
601
600602
603
604
605
606
607
601608
602
609
610
603611
604612
605613
......
625633
626634
627635
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643636
644637
645638
......
665658
666659
667660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
668675
669676
670677
#define DBG(x...)
#endif
#define UI_CPUFREQ_ROUNDING_FACTOR10000000
clock_frequency_info_t gPEClockFrequencyInfo;
case CPUID_MODEL_JAKETOWN:
case CPUID_MODEL_SANDYBRIDGE:
case CPUID_MODEL_IVYBRIDGE:
case CPUID_MODEL_IVYBRIDGE_XEON:
case CPUID_MODEL_HASWELL_U5:
case CPUID_MODEL_HASWELL:
case CPUID_MODEL_HASWELL_SVR:
//case CPUID_MODEL_HASWELL_H:
case CPUID_MODEL_HASWELL_ULT:
case CPUID_MODEL_HASWELL_ULX:
case CPUID_MODEL_BROADWELL_HQ:
case CPUID_MODEL_BRASWELL:
case CPUID_MODEL_AVOTON:
case CPUID_MODEL_SKYLAKE:
case CPUID_MODEL_BRODWELL_SVR:
case CPUID_MODEL_BRODWELL_MSVR:
case CPUID_MODEL_KNIGHT:
case CPUID_MODEL_ANNIDALE:
case CPUID_MODEL_GOLDMONT:
case CPUID_MODEL_VALLEYVIEW:
case CPUID_MODEL_SKYLAKE_S:
//case CPUID_MODEL_:
case CPUID_MODEL_SKYLAKE_AVX:
case CPUID_MODEL_CANNONLAKE:
msr = rdmsr64(MSR_CORE_THREAD_COUNT); // 0x35
p->CPU.NoCores= (uint32_t)bitfield((uint32_t)msr, 31, 16);
p->CPU.NoThreads= (uint32_t)bitfield((uint32_t)msr, 15, 0);
break;
}
if (p->CPU.NoCores == 0)
{
p->CPU.NoCores= cores_per_package;
p->CPU.NoThreads= logical_per_package;
}
// MSR is *NOT* available on the Intel Atom CPU
// workaround for N270. I don't know why it detected wrong
if ((p->CPU.Model == CPUID_MODEL_ATOM) && (strstr(p->CPU.BrandString, "270")))
{
p->CPU.NoCores= 1;
p->CPU.NoThreads= 2;
}
// workaround for Xeon Harpertown and Yorkfield
if ((p->CPU.Model == CPUID_MODEL_PENRYN) &&
(p->CPU.NoCores== 0))
}
}
if (p->CPU.NoCores == 0)
{
p->CPU.NoCores= cores_per_package;
p->CPU.NoThreads= logical_per_package;
}
// MSR is *NOT* available on the Intel Atom CPU
// workaround for N270. I don't know why it detected wrong
if ((p->CPU.Model == CPUID_MODEL_ATOM) && (strstr(p->CPU.BrandString, "270")))
{
p->CPU.NoCores= 1;
p->CPU.NoThreads= 2;
}
// workaround for Quad
if ( strstr(p->CPU.BrandString, "Quad") )
{
trunk/i386/libsaio/platform.h
7373
7474
7575
76
76
7777
78
78
7979
8080
81
81
82
83
84
85
8286
8387
8488
#define CPUID_MODEL_BRODWELL_SVR0x4F// Broadwell Server **BDX
#define CPUID_MODEL_SKYLAKE_AVX0x55// Skylake with AVX-512 support.
#define CPUID_MODEL_BRODWELL_MSVR0x56// Broadwell Micro Server, Future Xeon **BDX-DE
//#define CPUID_MODEL_KNIGHT0x57
#define CPUID_MODEL_KNIGHT0x57// Knights Landing
#define CPUID_MODEL_ANNIDALE0x5A// Silvermont, Future Atom E3000, Z3000 (Annidale)
//#define CPUID_MODEL_GOLDMONT0x5C
#define CPUID_MODEL_GOLDMONT0x5C
#define CPUID_MODEL_VALLEYVIEW0x5D// Silvermont, Future Atom E3000, Z3000
#define CPUID_MODEL_SKYLAKE_S0x5E// Skylake **SKL
//#define CPUID_MODEL_CANNONLAKE0x66
#define CPUID_MODEL_CANNONLAKE0x66
#define CPUID_MODEL_DENVERTON0x5F// Goldmont Microserver
#define CPUID_MODEL_XEON_MILL0x85// Knights Mill
#define CPUID_MODEL_KABYLAKE10x8E// Kabylake Mobile
#define CPUID_MODEL_KABYLAKE20x9E// Kabylake Dektop
/* CPUID Vendor */
#defineCPUID_VID_INTEL"GenuineIntel"
trunk/i386/libsaio/smbios_getters.c
2020
2121
2222
23
24
25
2326
2427
2528
......
384387
385388
386389
387
388390
389391
390392
......
424426
425427
426428
427
428
429
430
431
429
430
431
432
433
432434
433
434
435
436
437
435438
436439
437440
......
456459
457460
458461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
459486
460487
461488
#define XEON "Xeon"
#define CORE_M "Core(TM) M"
#define CORE_M3 "Core(TM) m3"
#define CORE_M5 "Core(TM) m5"
#define CORE_M7 "Core(TM) m7"
#define CORE_I3 "Core(TM) i3"
#define CORE_I5 "Core(TM) i5"
#define CORE_I7 "Core(TM) i7"
return true;
case CPUID_MODEL_HASWELL_U5:// 0x3D -
case CPUID_MODEL_SKYLAKE_S:// 0x5E
if (strstr(Platform.CPU.BrandString, CORE_M))
{
value->word = 0xA01;// 2561 - Xeon
return true;
case CPUID_MODEL_ATOM_3700:// 0x37 -
case CPUID_MODEL_HASWELL:// 0x3C -
case CPUID_MODEL_HASWELL_SVR:// 0x3F -
case CPUID_MODEL_HASWELL_ULT:// 0x45 -
case CPUID_MODEL_HASWELL_ULX:// 0x46 -
case CPUID_MODEL_ATOM_3700:// 0x37
case CPUID_MODEL_HASWELL:// 0x3C
case CPUID_MODEL_HASWELL_SVR:// 0x3F
case CPUID_MODEL_HASWELL_ULT:// 0x45
case CPUID_MODEL_HASWELL_ULX:// 0x46
case CPUID_MODEL_BROADWELL_HQ:// 0x47
case CPUID_MODEL_SKYLAKE:
case CPUID_MODEL_SKYLAKE_AVX:
case CPUID_MODEL_SKYLAKE:// 0x4E
case CPUID_MODEL_SKYLAKE_AVX:// 0x55
case CPUID_MODEL_SKYLAKE_S:// 0x5E
if (strstr(Platform.CPU.BrandString, XEON))
{
return true;
}
if (strstr(Platform.CPU.BrandString, CORE_M))
{
value->word = 0xB06;// 2822
return true;
}
if (strstr(Platform.CPU.BrandString, CORE_M3))
{
value->word = 0xC05;
return true;
}
if (strstr(Platform.CPU.BrandString, CORE_M5))
{
value->word = 0xD05;
return true;
}
if (strstr(Platform.CPU.BrandString, CORE_M7))
{
value->word = 0xE05;
return true;
}
if (Platform.CPU.NoCores <= 2)
{
value->word = 0x904;// - Core i3
trunk/i386/boot2/boot.c
11201120
11211121
11221122
1123
1123
11241124
11251125
11261126
}
// OS X El Capitan 10.11
if ( MacOSVerCurrent >= MacOSVer2Int("10.11") ) // El Capitan and Up!
if ( MacOSVerCurrent >= MacOSVer2Int("10.11") ) // El Capitan and Sierra!
{
// ErmaC
verbose("\n");
branches/ErmaC/Enoch/i386/libsaio/acpi_patcher.c
1616
1717
1818
19
20
19
20
2121
2222
2323
#include "state_generator.h"
#ifndef DEBUG_ACPI
#define DEBUG_ACPI 0
#endif
#define DEBUG_ACPI 0
#endif
#if DEBUG_ACPI==2
#define DBG(x...) {printf(x); sleep(1);}
branches/ErmaC/Enoch/i386/libsaio/hda.c
184184
185185
186186
187
188
187189
188190
189191
......
625627
626628
627629
628
630
629631
630632
631633
632634
633635
634
636
635637
636638
637639
......
656658
657659
658660
659
661
660662
661663
662664
{ HDA_NVIDIA_GK106,"GK106" /*, 0, ? */ },
{ HDA_NVIDIA_GK107,"GK107" /*, 0, ? */ },
{ HDA_NVIDIA_GK104,"GK104" /*, 0, ? */ },
{ HDA_NVIDIA_GP104_2,"Pascal GP104-200" /*, 0, ? */ },
{ HDA_NVIDIA_GM204_2,"Maxwell GP204-200" /*, 0, ? */ },
//1002 Advanced Micro Devices [AMD] nee ATI Technologies Inc
{ HDA_ATI_SB450,"SB4x0" /*, 0, 0 */ },
name_format = "ATI %s HDA Controller (HDMi)"; break;
case INTEL_VENDORID:
name_format = "Intel %s High Definition Audio Controller"; break;
name_format = "Intel %s HDA Controller"; break;
case NVIDIA_VENDORID:
name_format = "nVidia %s HDA Controller (HDMi)"; break;
case RDC_VENDORID:
name_format = "RDC %s High Definition Audio Controller"; break;
name_format = "RDC %s HDA Controller"; break;
case SIS_VENDORID:
name_format = "SiS %s HDA Controller"; break;
}
/* Not in table */
snprintf(desc, sizeof(desc), "Unknown HD Audio device, vendor %04x, model %04x",
snprintf(desc, sizeof(desc), "Unknown HDA device, vendor %04x, model %04x",
controller_vendor_id, controller_device_id);
return desc;
}
branches/ErmaC/Enoch/i386/libsaio/hda.h
171171
172172
173173
174
175
174176
175177
176178
#define HDA_NVIDIA_GK106HDA_MODEL_CONSTRUCT(NVIDIA, 0x0e0b)
#define HDA_NVIDIA_GK110HDA_MODEL_CONSTRUCT(NVIDIA, 0x0e1a)
#define HDA_NVIDIA_GK107HDA_MODEL_CONSTRUCT(NVIDIA, 0x0e1b) // HDACodec de104200 (10de0042)
#define HDA_NVIDIA_GP104_2 HDA_MODEL_CONSTRUCT(NVIDIA, 0x10f0) // GeForce GTX 1070
#define HDA_NVIDIA_GM204_2 HDA_MODEL_CONSTRUCT(NVIDIA, 0x0fbb) // GeForce GTX 970
#define HDA_NVIDIA_ALLHDA_MODEL_CONSTRUCT(NVIDIA, 0xffff)
/* ATI */
branches/ErmaC/Enoch/i386/libsaio/nvidia.c
821821
822822
823823
824
824
825825
826826
827827
......
847847
848848
849849
850
850
851851
852852
853853
......
911911
912912
913913
914
914
915915
916916
917917
......
943943
944944
945945
946
946
947947
948948
949949
......
12941294
12951295
12961296
1297
12971298
12981299
12991300
......
13191320
13201321
13211322
1323
1324
1325
1326
1327
1328
1329
13221330
13231331
13241332
......
13311339
13321340
13331341
1342
1343
13341344
13351345
13361346
1337
1347
1348
1349
1350
1351
13381352
13391353
13401354
......
13491363
13501364
13511365
1352
1353
1366
1367
1368
1369
1370
1371
1372
1373
1374
13541375
1355
1376
1377
1378
1379
1380
1381
13561382
13571383
13581384
13591385
13601386
13611387
1388
1389
1390
13621391
13631392
1393
13641394
13651395
13661396
......
13761406
13771407
13781408
1379
1409
13801410
13811411
1382
1412
13831413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
13841444
13851445
13861446
{ 0x10DE0A2A,"GeForce GT 230M" },
{ 0x10DE0A2B,"GeForce GT 330M" },
{ 0x10DE0A2C,"NVS 5100M" },
{ 0x10DE0A2D,"GeForce GT 320M" },
{ 0x10DE0A2D,"GeForce GT 320M" },
// 0A30 - 0A3F
{ 0x10DE0A30,"GeForce GT 330M" },
{ 0x10DE0A32,"GeForce GT 415" },
{ 0x10DE0A6A,"NVS 2100M" },
{ 0x10DE0A6C,"NVS 3100M" },
{ 0x10DE0A6E,"GeForce 305M" },
{ 0x10DE0A6F,"ION" },
{ 0x10DE0A6F,"ION" },
// 0A70 - 0A7F
{ 0x10DE0A70,"GeForce 310M" },
{ 0x10DE0A71,"GeForce 305M" },
{ 0x10DE0CAD,"N10E-ES" }, // SUBIDS
{ 0x10DE0CAE,"GT215-INT" },
{ 0x10DE0CAF,"GeForce GT 335M" },
// 0CB0 - 0CBF
// 0CB0 - 0CBF
{ 0x10DE0CB0,"GeForce GTS 350M" },
{ 0x10DE0CB1,"GeForce GTS 360M" },
{ 0x10DE0CBC,"Quadro FX 1800M" },
{ 0x10DE0DCD,"GeForce GT 555M" },
{ 0x10DE0DCE,"GeForce GT 555M" },
// { 0x10DE0DCF,"N12P-GT-B" },
// 0DD0 - 0DDF
// 0DD0 - 0DDF
{ 0x10DE0DD0,"N11E-GT" },
{ 0x10DE0DD1,"GeForce GTX 460M" },
{ 0x10DE0DD2,"GeForce GT 445M" },
{ 0x10DE1286,"GeForce GT 720" },
{ 0x10DE1287,"GeForce GT 730" }, // GK208
{ 0x10DE1288,"GeForce GT 720" }, // GK208
{ 0x10DE128b,"GeForce GT 710" },
// 1290 - 129F
{ 0x10DE1290,"GeForce GT 730M" },
{ 0x10DE1291,"GeForce GT 735M" },
{ 0x10DE1341,"GeForce 840M" },
{ 0x10DE1346,"GeForce 930M" }, // GM108M
{ 0x10DE1347,"GeForce 940M" }, // GM108M
{ 0x10DE1348,"GeForce 945M/945A" }, // GM108M
{ 0x10DE1349,"GeForce 930M" }, // GM108M
{ 0x10DE134D,"GeForce 940MX" }, // GM108M
{ 0x10DE134E,"GeForce 930MX" }, // GM108M
{ 0x10DE134F,"GeForce 920MX" }, // GM108M
{ 0x10DE137A,"Quadro K620M/M500M" }, // GM108GLM
{ 0x10DE137D,"GeForce 940A" }, // GM108M
{ 0x10DE1380,"GeForce GTX 750 Ti" },
{ 0x10DE1381,"GeForce GTX 750" },
{ 0x10DE1382,"GeForce GTX 745" },
{ 0x10DE1398,"GeForce 845M" }, //
{ 0x10DE139A,"GeForce GTX 950M" }, // GM107
{ 0x10DE139B,"GeForce GTX 960M" }, // GM107
{ 0x10DE139C,"GeForce 940M" }, // GM107M
{ 0x10DE139D,"GeForce GTX 750 Ti" }, // GM107M
{ 0x10DE13AD,"GM107 INT52" }, //
{ 0x10DE13AE,"GM107 CS1" }, //
//{ 0x10DE13AF,"Graphics Device" }, // GM107GLM
{ 0x10DE13B3,"Quadro K2200M" }, //
{ 0x10DE13B0,"GQuadro M2000M" }, // GM107GLM
{ 0x10DE13B1,"Quadro M1000M" }, // GM107GLM
{ 0x10DE13B2,"Quadro M600M" }, // GM107GLM
{ 0x10DE13B3,"Quadro K2200M" }, // GM107GLM
{ 0x10DE13B9,"NVS 810" }, // GM107GL
{ 0x10DE13BA,"Quadro K2200" },
{ 0x10DE13BB,"Quadro K620" },
{ 0x10DE13BC,"Quadro K1200" },
{ 0x10DE13D7,"GeForce GTX 980M" }, //
{ 0x10DE13D8,"GeForce GTX 970M" }, //
{ 0x10DE13D9,"GeForce GTX 965M" },
//{ 0x10DE13F0,"Graphics Device" }, // GM107GLM
//{ 0x10DE13F1,"Graphics Device" }, // GM107GLM
{ 0x10DE13DA,"GeForce GTX 980" }, // GM204M
{ 0x10DE13F0,"Quadro M5000" }, // GM204GL
{ 0x10DE13F1,"Quadro M4000" }, // GM204GL
{ 0x10DE13F2,"Tesla M60" }, // GM204GL
{ 0x10DE13F3,"Tesla M6" }, // GM204GL
{ 0x10DE13F8,"Quadro M5000M" }, // GM204GLM
{ 0x10DE13F9,"Quadro M4000M" }, // GM204GLM
{ 0x10DE13FA,"Quadro M3000M" }, // GM204GLM
{ 0x10DE13FB,"Quadro M5500" }, // GM204GLM
{ 0x10DE1401,"GeForce GTX 960" }, //
//{ 0x10DE1402,"Graphics Device" }, //
{ 0x10DE1402,"GeForce GTX 950" }, //
{ 0x10DE1406,"GeForce GTX 960" }, // GM206
{ 0x10DE1407,"GeForce GTX 750 v2" }, // GM206
{ 0x10DE1427,"GeForce GTX 965M" }, // GM206M
{ 0x10DE1430,"Quadro M2000" }, //
{ 0x10DE1431,"Tesla M4" }, // GM206GL
//{ 0x10DE143F,"Graphics Device" }, //
//{ 0x10DE1600,"Graphics Device" }, //
//{ 0x10DE1601,"Graphics Device" }, //
//{ 0x10DE1602,"Graphics Device" }, //
//{ 0x10DE1603,"Graphics Device" }, //
{ 0x10DE1617,"GeForce GTX 980M" }, //
{ 0x10DE1618,"GeForce GTX 970M" }, // GM204M
{ 0x10DE1619,"GeForce GTX 965M" }, // GM204M
{ 0x10DE161A,"GeForce GTX 980" }, // GM204M
//{ 0x10DE1630,"Graphics Device" }, //
//{ 0x10DE1631,"Graphics Device" }, //
{ 0x10DE1667,"GeForce GTX 965M" }, // GM204M
//{ 0x10DE1780,"Graphics Device" }, //
//{ 0x10DE1781,"Graphics Device" }, //
//{ 0x10DE1782,"Graphics Device" }, //
{ 0x10DE17BE,"GM107 CS1" }, // GM107
//{ 0x10DE17C1,"Graphics Device" }, //
{ 0x10DE17C2,"GeForce GTX Titan X" }, //
{ 0x10DE17C8,"GeForce GTX 980 TI" },
{ 0x10DE17C8,"GeForce GTX 980 TI" }, //
//{ 0x10DE17EE,"Graphics Device" }, //
//{ 0x10DE17EF,"Graphics Device" }, //
{ 0x10DE17F0,"Quadro M6000" }
{ 0x10DE17F0,"Quadro M6000" },
//{ 0x10DE17FF,"Graphics Device" }, //
{ 0x10DE17F1,"Quadro M6000" }, // GM200GL
{ 0x10DE17FD,"Tesla M40" }, // GM200GL
// 1B00 - 1CFFF
{ 0x10DE1B00, "Titan X Pascal"}, // GP102
//{ 0x10DE1B01,"Graphics Device" }, // GP102
{ 0x10DE1B30,"Quadro P6000" }, // GP102GL
//{ 0x10DE1B70,"Graphics Device" }, // GP102GL
//{ 0x10DE1B78,"Graphics Device" }, // GP102GL
{ 0x10DE1B80, "GeForce GTX 1080"}, // GP104
{ 0x10DE1B81, "GeForce GTX 1070"}, // GP104
//{ 0x10DE1B82,"Graphics Device" }, // GP104
//{ 0x10DE1B83,"Graphics Device" }, // GP104
{ 0x10DE1BA0,"GeForce GTX 1080" }, // GP104M
{ 0x10DE1BA1,"GeForce GTX 1070" }, // GP104M
{ 0x10DE1BB0,"Quadro P5000" }, // GP104GL
//{ 0x10DE1BB1,"Graphics Device" }, // GP104GL
//{ 0x10DE1BB4,"Graphics Device" }, // GP104GL
{ 0x10DE1BE0,"GeForce GTX 1080" }, //GP104M
{ 0x10DE1BE1,"GeForce GTX 1070" }, //GP104M
//{ 0x10DE1C00,"Graphics Device" }, // GP106
//{ 0x10DE1C01,"Graphics Device" }, // GP106
{ 0x10DE1C02, "GeForce GTX 1060"}, // GP106
{ 0x10DE1C03, "GeForce GTX 1060"}, // GP106
{ 0x10DE1c20,"GeForce GTX 1060" }, //GP106M
//{ 0x10DE1C30,"Graphics Device" }, // GP106GL
{ 0x10DE1C60,"GeForce GTX 1060" }, // GP106M
//{ 0x10DE1C70,"Graphics Device" }, // GP106GL
//{ 0x10DE1C80,"Graphics Device" }, // GP107
//{ 0x10DE1C81,"Graphics Device" }, // GP107
{ 0x10DE1C82,"GeForce GTX 1050 Ti"}, // GP107
};
static nvidia_card_info_t nvidia_card_exceptions[] = {
branches/ErmaC/Enoch/i386/libsaio/ati.c
6565
6666
6767
68
68
6969
7070
71
71
7272
7373
7474
......
8686
8787
8888
89
90
8991
9092
9193
......
9597
9698
9799
98
100
99101
100102
101103
......
107109
108110
109111
110
112
113
114
115
116
111117
112118
113
119
120
121
122
123
124
125
126
127
114128
115129
116130
......
284298
285299
286300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
287324
288325
289326
......
384421
385422
386423
387
424
388425
389426
390427
......
397434
398435
399436
400
401
437
438
402439
403440
404441
......
842879
843880
844881
882
845883
846884
847885
......
863901
864902
865903
866
904
867905
868906
907
908
909
910
911
869912
870913
871914
......
12891332
12901333
12911334
1292
1335
12931336
12941337
12951338
{"Galago",2},
{"Colobus",2},
{"Mangabey",2},
{"Nomascus",4}, // 5
{"Nomascus",5},
{"Orangutan",2},
/* AMD6000Controller */
{"Pithecia",2}, // 3
{"Pithecia",3},
{"Bulrushes",6},
{"Cattail",4},
{"Hydrilla",5},
{"Spikerush", 4},
{"Typha", 5},
/* AMD7000Controller */
{"Ramen",6},
{"Tako",6},
{"Namako",4},
{"Aji",4},
{"Buri",4},
{"Gari",5},
{"Futomaki",5},
{"Hamachi",4},
{"OPM", 6},
{"OPM", 5},
{"Ikura",1},
{"IkuraS",6},
{"Junsai",6},
/* AMD8000Controller */
{"Baladi", 6},
/* AMD9000Controller */
{"Exmoor",4},
{"Exmoor",6},
{"MalteseS",1},
{"Lagotto",4},
{"GreyhoundS",1},
{"Maltese",6},
{"Basset",4},
{"Greyhound",6},
{"Labrador",6}
{"Labrador",6},
/* AMD9500Controller */
{"Elqui",5},
{"Acre",3},
{"Berbice",5},
{"Caroni",5},
{"Florin",6},
{"Dayman",6},
{"Guariba",6}
};
static radeon_card_info_t radeon_cards[] = {
//{ 0x67BA,0x00000000, CHIP_FAMILY_HAWAII,"AMD Radeon", kFutomaki},
//{ 0x67BE,0x00000000, CHIP_FAMILY_HAWAII,"AMD Radeon", kFutomaki},
// Polaris 10
{ 0x67C0, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C1, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C2, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C4, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C7, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C8, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67C9, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67CA, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67CC, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67CF, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon Polaris 10", kNull },
{ 0x67DF, 0x00000000, CHIP_FAMILY_ELLESMERE, "AMD Radeon RX480", kDayman },
// Polaris 11
{ 0x67E0, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon RX460", kAcre },
{ 0x67E1, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67E3, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67E7, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67E8, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67E9, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67EB, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
{ 0x67EF, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon RX460", kAcre },
{ 0x67FF, 0x00000000, CHIP_FAMILY_BAFFIN, "AMD Radeon Polaris 11", kNull },
// PITCAIRN
{ 0x6800,0x00000000, CHIP_FAMILY_PITCAIRN,"AMD Radeon HD 7970M",kBuri}, // Mobile
{ 0x6801,0x00000000, CHIP_FAMILY_PITCAIRN,"AMD Radeon HD 8970M Series",kFutomaki}, // Mobile
// CEDAR
{ 0x68E0,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD 5470 Series",kGalago},
{ 0x68E1,0x00000000, CHIP_FAMILY_CEDAR,"AMD Radeon HD 6230",kGalago},
{ 0x68E1,0x00000000, CHIP_FAMILY_CEDAR,"AMD Radeon HD 6230/6350/8350",kGalago},
{ 0x68E4,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD 6370M Series",kGalago},
{ 0x68E5,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD 6300M Series",kGalago},
//{ 0x68E8,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD ??? Series",kNull},
//{ 0x68FE,0x00000000, CHIP_FAMILY_CEDAR,"ATI Radeon HD ??? Series",kNull},
//
{ 0x6900,0x00000000, CHIP_FAMILY_TOPAS,"ATI Radeon R7 M260/M265", kExmoor},
{ 0x6901,0x00000000, CHIP_FAMILY_TOPAS,"ATI Radeon R5 M255", kExmoor},
{ 0x6900,0x00000000, CHIP_FAMILY_TOPAZ,"ATI Radeon R7 M260/M265", kExmoor},
{ 0x6901,0x00000000, CHIP_FAMILY_TOPAZ,"ATI Radeon R5 M255", kExmoor},
{ 0x6920,0x00000000, CHIP_FAMILY_AMETHYST,"ATI Radeon R9 M395X", kLabrador},
{ 0x6921,0x00000000, CHIP_FAMILY_AMETHYST,"ATI Radeon R9 M295X", kExmoor},
{ 0x692B,0x00000000, CHIP_FAMILY_TONGA,"ATI Firepro W7100", kBaladi},
"Hemlock",
"Juniper",
"Redwood",
// "Broadway",
/* Northern Islands */
"Barts",
"Caicos",
"Hawaii",
/* ... */
"Mullins",
"Topas",
"Topaz",
"Amethyst",
"Tonga",
"Fiji",
"Carrizo",
"Tobago",
"Ellesmere",
"Baffin",
""
};
void get_vram_size(void)
{
ati_chip_family_t chip_family = card->info->chip_family;
card->vram_size = 0;
if (chip_family >= CHIP_FAMILY_CEDAR)
branches/ErmaC/Enoch/i386/libsaio/ati.h
9999
100100
101101
102
102
103103
104104
105
106
107
108
109
105110
106111
107112
......
172177
173178
174179
180
181
175182
176183
177184
......
194201
195202
196203
204
205
206
207
197208
198209
199210
211
212
213
214
215
216
217
218
200219
201220
202221
CHIP_FAMILY_HAWAII,
/* ... */
CHIP_FAMILY_MULLINS,
CHIP_FAMILY_TOPAS,
CHIP_FAMILY_TOPAZ,
CHIP_FAMILY_AMETHYST,
CHIP_FAMILY_TONGA,
CHIP_FAMILY_FIJI,
CHIP_FAMILY_CARRIZO,
CHIP_FAMILY_TOBAGO,
CHIP_FAMILY_ELLESMERE, /* Polaris 10 */
CHIP_FAMILY_BAFFIN, /* Polaris 11 */
CHIP_FAMILY_LAST
} ati_chip_family_t;
kSpikerush,
kTypha,
/* AMD7000Controller */
kRamen,
kTako,
kNamako,
kAji,
kBuri,
kBaladi,
/* AMD9000Controller */
kExmoor,
kMalteseS,
kLagotto,
kGreyhoundS,
kMaltese,
kBasset,
kGreyhound,
kLabrador,
/* AMD9500Controller */
kElqui,
kAcre,
kBerbice,
kCaroni,
kFlorin,
kDayman,
kGuariba,
kCfgEnd
} config_name_t;
branches/ErmaC/Enoch/i386/libsaio/cpu.c
2020
2121
2222
23
2423
2524
2625
......
590589
591590
592591
592
593593
594594
595595
596
597596
598597
599598
599
600
601
600602
603
604
605
606
607
601608
602
609
610
603611
604612
605613
......
625633
626634
627635
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643636
644637
645638
......
665658
666659
667660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
668675
669676
670677
#define DBG(x...)
#endif
#define UI_CPUFREQ_ROUNDING_FACTOR10000000
clock_frequency_info_t gPEClockFrequencyInfo;
case CPUID_MODEL_JAKETOWN:
case CPUID_MODEL_SANDYBRIDGE:
case CPUID_MODEL_IVYBRIDGE:
case CPUID_MODEL_IVYBRIDGE_XEON:
case CPUID_MODEL_HASWELL_U5:
case CPUID_MODEL_HASWELL:
case CPUID_MODEL_HASWELL_SVR:
//case CPUID_MODEL_HASWELL_H:
case CPUID_MODEL_HASWELL_ULT:
case CPUID_MODEL_HASWELL_ULX:
case CPUID_MODEL_BROADWELL_HQ:
case CPUID_MODEL_BRASWELL:
case CPUID_MODEL_AVOTON:
case CPUID_MODEL_SKYLAKE:
case CPUID_MODEL_BRODWELL_SVR:
case CPUID_MODEL_BRODWELL_MSVR:
case CPUID_MODEL_KNIGHT:
case CPUID_MODEL_ANNIDALE:
case CPUID_MODEL_GOLDMONT:
case CPUID_MODEL_VALLEYVIEW:
case CPUID_MODEL_SKYLAKE_S:
//case CPUID_MODEL_:
case CPUID_MODEL_SKYLAKE_AVX:
case CPUID_MODEL_CANNONLAKE:
msr = rdmsr64(MSR_CORE_THREAD_COUNT); // 0x35
p->CPU.NoCores= (uint32_t)bitfield((uint32_t)msr, 31, 16);
p->CPU.NoThreads= (uint32_t)bitfield((uint32_t)msr, 15, 0);
break;
}
if (p->CPU.NoCores == 0)
{
p->CPU.NoCores= cores_per_package;
p->CPU.NoThreads= logical_per_package;
}
// MSR is *NOT* available on the Intel Atom CPU
// workaround for N270. I don't know why it detected wrong
if ((p->CPU.Model == CPUID_MODEL_ATOM) && (strstr(p->CPU.BrandString, "270")))
{
p->CPU.NoCores= 1;
p->CPU.NoThreads= 2;
}
// workaround for Xeon Harpertown and Yorkfield
if ((p->CPU.Model == CPUID_MODEL_PENRYN) &&
(p->CPU.NoCores== 0))
}
}
if (p->CPU.NoCores == 0)
{
p->CPU.NoCores= cores_per_package;
p->CPU.NoThreads= logical_per_package;
}
// MSR is *NOT* available on the Intel Atom CPU
// workaround for N270. I don't know why it detected wrong
if ((p->CPU.Model == CPUID_MODEL_ATOM) && (strstr(p->CPU.BrandString, "270")))
{
p->CPU.NoCores= 1;
p->CPU.NoThreads= 2;
}
// workaround for Quad
if ( strstr(p->CPU.BrandString, "Quad") )
{
branches/ErmaC/Enoch/i386/libsaio/platform.h
7373
7474
7575
76
76
7777
78
78
7979
8080
81
81
82
83
84
85
8286
8387
8488
#define CPUID_MODEL_BRODWELL_SVR0x4F// Broadwell Server **BDX
#define CPUID_MODEL_SKYLAKE_AVX0x55// Skylake with AVX-512 support.
#define CPUID_MODEL_BRODWELL_MSVR0x56// Broadwell Micro Server, Future Xeon **BDX-DE
//#define CPUID_MODEL_KNIGHT0x57
#define CPUID_MODEL_KNIGHT0x57// Knights Landing
#define CPUID_MODEL_ANNIDALE0x5A// Silvermont, Future Atom E3000, Z3000 (Annidale)
//#define CPUID_MODEL_GOLDMONT0x5C
#define CPUID_MODEL_GOLDMONT0x5C
#define CPUID_MODEL_VALLEYVIEW0x5D// Silvermont, Future Atom E3000, Z3000
#define CPUID_MODEL_SKYLAKE_S0x5E// Skylake **SKL
//#define CPUID_MODEL_CANNONLAKE0x66
#define CPUID_MODEL_CANNONLAKE0x66
#define CPUID_MODEL_DENVERTON0x5F// Goldmont Microserver
#define CPUID_MODEL_XEON_MILL0x85// Knights Mill
#define CPUID_MODEL_KABYLAKE10x8E// Kabylake Mobile
#define CPUID_MODEL_KABYLAKE20x9E// Kabylake Dektop
/* CPUID Vendor */
#defineCPUID_VID_INTEL"GenuineIntel"
branches/ErmaC/Enoch/i386/libsaio/smbios_getters.c
2020
2121
2222
23
24
25
2326
2427
2528
......
384387
385388
386389
387
388390
389391
390392
......
424426
425427
426428
427
428
429
430
431
429
430
431
432
433
432434
433
434
435
436
437
435438
436439
437440
......
456459
457460
458461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
459486
460487
461488
#define XEON "Xeon"
#define CORE_M "Core(TM) M"
#define CORE_M3 "Core(TM) m3"
#define CORE_M5 "Core(TM) m5"
#define CORE_M7 "Core(TM) m7"
#define CORE_I3 "Core(TM) i3"
#define CORE_I5 "Core(TM) i5"
#define CORE_I7 "Core(TM) i7"
return true;
case CPUID_MODEL_HASWELL_U5:// 0x3D -
case CPUID_MODEL_SKYLAKE_S:// 0x5E
if (strstr(Platform.CPU.BrandString, CORE_M))
{
value->word = 0xA01;// 2561 - Xeon
return true;
case CPUID_MODEL_ATOM_3700:// 0x37 -
case CPUID_MODEL_HASWELL:// 0x3C -
case CPUID_MODEL_HASWELL_SVR:// 0x3F -
case CPUID_MODEL_HASWELL_ULT:// 0x45 -
case CPUID_MODEL_HASWELL_ULX:// 0x46 -
case CPUID_MODEL_ATOM_3700:// 0x37
case CPUID_MODEL_HASWELL:// 0x3C
case CPUID_MODEL_HASWELL_SVR:// 0x3F
case CPUID_MODEL_HASWELL_ULT:// 0x45
case CPUID_MODEL_HASWELL_ULX:// 0x46
case CPUID_MODEL_BROADWELL_HQ:// 0x47
case CPUID_MODEL_SKYLAKE:
case CPUID_MODEL_SKYLAKE_AVX:
case CPUID_MODEL_SKYLAKE:// 0x4E
case CPUID_MODEL_SKYLAKE_AVX:// 0x55
case CPUID_MODEL_SKYLAKE_S:// 0x5E
if (strstr(Platform.CPU.BrandString, XEON))
{
return true;
}
if (strstr(Platform.CPU.BrandString, CORE_M))
{
value->word = 0xB06;// 2822
return true;
}
if (strstr(Platform.CPU.BrandString, CORE_M3))
{
value->word = 0xC05;
return true;
}
if (strstr(Platform.CPU.BrandString, CORE_M5))
{
value->word = 0xD05;
return true;
}
if (strstr(Platform.CPU.BrandString, CORE_M7))
{
value->word = 0xE05;
return true;
}
if (Platform.CPU.NoCores <= 2)
{
value->word = 0x904;// - Core i3
branches/ErmaC/Enoch/i386/boot2/boot.c
11161116
11171117
11181118
1119
1119
11201120
11211121
11221122
}
// OS X El Capitan 10.11
if ( MacOSVerCurrent >= MacOSVer2Int("10.11") ) // El Capitan and Up!
if ( MacOSVerCurrent >= MacOSVer2Int("10.11") ) // El Capitan and Sierra!
{
// ErmaC
verbose("\n");

Archive Download the corresponding diff file

Revision: 2842