Index: branches/ErmaC/Enoch/i386/libsaio/nvidia_helper.c =================================================================== --- branches/ErmaC/Enoch/i386/libsaio/nvidia_helper.c (revision 2881) +++ branches/ErmaC/Enoch/i386/libsaio/nvidia_helper.c (revision 2882) @@ -1,153 +0,0 @@ -/* - * Copyright (c) 2012 cparm . All rights reserved. - * - */ - -#include "libsaio.h" -#include "bootstruct.h" -#include "xml.h" -#include "nvidia_helper.h" -#include "pci.h" -#include "nvidia.h" - -/* - - NVIDIA card injection usage e.g (to be placed in the boot.plist): - - NVIDIA - - - Chipset Name - Quadro FX 380 - IOPCIPrimaryMatch - 0x10DE0658 - VRam Size - 256 - - - Chipset Name - YOUR_CARD_NAME - IOPCIPrimaryMatch - YOUR_CARD_ID - IOPCISubDevId - YOUR_CARD_SUB_ID(if necessary) - VRam Size - YOUR_CARD_VRAM_SIZE - - - Chipset Name - YOUR_SECOND_CARD_NAME - IOPCIPrimaryMatch - YOUR_SECOND_CARD_ID - IOPCISubDevId - YOUR_SECOND_CARD_SUB_ID(if necessary) - VRam Size - YOUR_SECOND_CARD_VRAM_SIZE - - . - . - . - . - - - */ - -cardList_t *cardList = NULL; - -void add_card(char *model, uint32_t id, uint32_t subid, uint64_t videoRam) -{ - - cardList_t *new_card = malloc(sizeof(cardList_t)); - if (new_card) - { - new_card->next = cardList; - - cardList = new_card; - - new_card->id = id; - new_card->subid = subid; - new_card->videoRam = videoRam; - new_card->model = model; - } -} - -cardList_t *FindCardWithIds(uint32_t id, uint32_t subid) -{ - cardList_t *entry = cardList; - while(entry) - { - if((entry->id == id) && (entry->subid == subid)) - { - return entry; - } - else - { - entry = entry->next; - } - - } - - // LET A SECOND CHANCE by seaching only for the device-id - entry = cardList; - while(entry) - { - if(entry->id == id) - { - return entry; - } - else - { - entry = entry->next; - } - - } - - return NULL; -} - -void fill_card_list(void) -{ - unsigned int i, count; - TagPtr NVDIATag; - char *model_name = NULL; - char *match_id = NULL; - char *sub_id = NULL; - char *vram_size = NULL; - uint32_t dev_id = 0; - uint32_t subdev_id = 0; - uint64_t VramSize = 0; - - if ((NVDIATag = XMLCastArray(XMLGetProperty(bootInfo->chameleonConfig.dictionary, (const char *)"NVIDIA")))) - { - count = XMLTagCount(NVDIATag); - - for (i=0; i. All rights reserved. - * - */ - - -#ifndef __LIBSAIO_NVIDIA_HELPER_H -#define __LIBSAIO_NVIDIA_HELPER_H - -typedef struct cardList_t -{ - char *model; - uint32_t id; - uint32_t subid; - uint64_t videoRam; - struct cardList_t *next; -} cardList_t; - -void add_card(char *model, uint32_t id, uint32_t subid, uint64_t videoRam); -void fill_card_list(void); -cardList_t *FindCardWithIds(uint32_t id, uint32_t subid); - -#endif //__LIBSAIO_NVIDIA_HELPER_H Index: branches/ErmaC/Enoch/i386/libsaio/bootstruct.c =================================================================== --- branches/ErmaC/Enoch/i386/libsaio/bootstruct.c (revision 2881) +++ branches/ErmaC/Enoch/i386/libsaio/bootstruct.c (revision 2882) @@ -140,6 +140,7 @@ bcopy(oldAddr, bootArgs, sizeof(boot_args)); } + // 10.12 and 10.13 new bootArgs? } //============================================================================== Index: branches/ErmaC/Enoch/i386/libsaio/Makefile =================================================================== --- branches/ErmaC/Enoch/i386/libsaio/Makefile (revision 2881) +++ branches/ErmaC/Enoch/i386/libsaio/Makefile (revision 2882) @@ -37,7 +37,7 @@ smbios.o smbios_getters.o smbios_decode.o \ fake_efi.o ext2fs.o \ hpet.o dram_controllers.o spd.o usb.o pci_setup.o \ - device_inject.o networking.o nvidia_helper.o nvidia.o ati.o gma.o hda.o pci_root.o \ + device_inject.o networking.o gfx_helper.o nvidia.o ati.o gma.o hda.o pci_root.o \ convert.o aml_generator.o console.o exfat.o base64-decode.o SAIO_OBJS := $(addprefix $(OBJROOT)/, $(SAIO_OBJS)) Index: branches/ErmaC/Enoch/i386/libsaio/gfx_helper.c =================================================================== --- branches/ErmaC/Enoch/i386/libsaio/gfx_helper.c (revision 0) +++ branches/ErmaC/Enoch/i386/libsaio/gfx_helper.c (revision 2882) @@ -0,0 +1,153 @@ +/* + * Copyright (c) 2012 cparm . All rights reserved. + * + */ + +#include "libsaio.h" +#include "bootstruct.h" +#include "xml.h" +#include "gfx_helper.h" +#include "pci.h" +#include "nvidia.h" + +/* + + NVIDIA card injection usage e.g (to be placed in the boot.plist): + + NVIDIA + + + Chipset Name + Quadro FX 380 + IOPCIPrimaryMatch + 0x10DE0658 + VRam Size + 256 + + + Chipset Name + YOUR_CARD_NAME + IOPCIPrimaryMatch + YOUR_CARD_ID + IOPCISubDevId + YOUR_CARD_SUB_ID(if necessary) + VRam Size + YOUR_CARD_VRAM_SIZE + + + Chipset Name + YOUR_SECOND_CARD_NAME + IOPCIPrimaryMatch + YOUR_SECOND_CARD_ID + IOPCISubDevId + YOUR_SECOND_CARD_SUB_ID(if necessary) + VRam Size + YOUR_SECOND_CARD_VRAM_SIZE + + . + . + . + . + + + */ + +cardList_t *cardList = NULL; + +void add_card(char *model, uint32_t id, uint32_t subid, uint64_t videoRam) +{ + + cardList_t *new_card = malloc(sizeof(cardList_t)); + if (new_card) + { + new_card->next = cardList; + + cardList = new_card; + + new_card->id = id; + new_card->subid = subid; + new_card->videoRam = videoRam; + new_card->model = model; + } +} + +cardList_t *FindCardWithIds(uint32_t id, uint32_t subid) +{ + cardList_t *entry = cardList; + while(entry) + { + if((entry->id == id) && (entry->subid == subid)) + { + return entry; + } + else + { + entry = entry->next; + } + + } + + // LET A SECOND CHANCE by seaching only for the device-id + entry = cardList; + while(entry) + { + if(entry->id == id) + { + return entry; + } + else + { + entry = entry->next; + } + + } + + return NULL; +} + +void fill_card_list(void) +{ + unsigned int i, count; + TagPtr NVDIATag; + char *model_name = NULL; + char *match_id = NULL; + char *sub_id = NULL; + char *vram_size = NULL; + uint32_t dev_id = 0; + uint32_t subdev_id = 0; + uint64_t VramSize = 0; + + if ((NVDIATag = XMLCastArray(XMLGetProperty(bootInfo->chameleonConfig.dictionary, (const char *)"NVIDIA")))) + { + count = XMLTagCount(NVDIATag); + + for (i=0; i. All rights reserved. + * + */ + +#ifndef __LIBSAIO_GFX_HELPER_H +#define __LIBSAIO_GFX_HELPER_H + +typedef struct cardList_t +{ + char *model; + uint32_t id; + uint32_t subid; + uint64_t videoRam; + struct cardList_t *next; +} cardList_t; + +void add_card(char *model, uint32_t id, uint32_t subid, uint64_t videoRam); +void fill_card_list(void); +cardList_t *FindCardWithIds(uint32_t id, uint32_t subid); + +#endif //__LIBSAIO_GFX_HELPER_H Index: branches/ErmaC/Enoch/i386/libsaio/nvidia.c =================================================================== --- branches/ErmaC/Enoch/i386/libsaio/nvidia.c (revision 2881) +++ branches/ErmaC/Enoch/i386/libsaio/nvidia.c (revision 2882) @@ -55,7 +55,7 @@ #include "device_inject.h" #include "convert.h" #include "nvidia.h" -#include "nvidia_helper.h" +#include "gfx_helper.h" #if DEBUG_NVIDIA #define DBG(x...) printf(x) Index: branches/ErmaC/Enoch/i386/libsaio/fake_efi.c =================================================================== --- branches/ErmaC/Enoch/i386/libsaio/fake_efi.c (revision 2881) +++ branches/ErmaC/Enoch/i386/libsaio/fake_efi.c (revision 2882) @@ -633,9 +633,9 @@ DT__AddProperty(efiPlatformNode, CPU_Frequency_prop, sizeof(uint64_t), &Platform.CPU.CPUFrequency); } - DT__AddProperty(efiPlatformNode,START_POWER_EV, sizeof(STARTUP_POWER_EVENTS), (EFI_UINT8 *) &STARTUP_POWER_EVENTS); + DT__AddProperty(efiPlatformNode, START_POWER_EV, sizeof(STARTUP_POWER_EVENTS), (EFI_UINT8 *) &STARTUP_POWER_EVENTS); - DT__AddProperty(efiPlatformNode,DEV_PATH_SUP, sizeof(DEVICE_PATHS_SUPPORTED), (EFI_UINT8 *) &DEVICE_PATHS_SUPPORTED); + DT__AddProperty(efiPlatformNode, DEV_PATH_SUP, sizeof(DEVICE_PATHS_SUPPORTED), (EFI_UINT8 *) &DEVICE_PATHS_SUPPORTED); DT__AddProperty(efiPlatformNode, SYSTEM_ID_PROP, UUID_LEN, (EFI_UINT32 *)Platform.UUID); @@ -830,14 +830,15 @@ // Micky1979 : MIMIC booter entry for El Capitan if ( MacOSVerCurrent >= MacOSVer2Int("10.11") ) // El Capitan { + verbose("Adding booter spec to the Platform Expert \n"); - // booter-build-time (Fri May 22 19:06:42 PDT 2015) DP1 - // booter-build-time (Fri Jul 24 17:39:22 PDT 2015) DP7 + + // booter-build-time (Fri Apr 14 16:21:16 PDT 2017) 10.12.5 DT__AddProperty(chosenNode, "booter-build-time", sizeof(I386BOOT_BUILDDATE), I386BOOT_BUILDDATE); - // booter-name (boot.efi) + // booter-name DT__AddProperty(chosenNode, "booter-name", sizeof("Enoch"), "Enoch"); - // booter-version (version:295.0.0.1.1) DP1 - // booter-version (version:304) DP7 + + // booter-version (version:324.50.13) 10.12.5 DT__AddProperty(chosenNode, "booter-version", sizeof(I386BOOT_CHAMELEONREVISION), I386BOOT_CHAMELEONREVISION); } } Index: branches/ErmaC/Enoch/i386/boot2/drivers.c =================================================================== --- branches/ErmaC/Enoch/i386/boot2/drivers.c (revision 2881) +++ branches/ErmaC/Enoch/i386/boot2/drivers.c (revision 2882) @@ -967,7 +967,7 @@ snprintf(gFileSpec, 4096, "%s%s", module->executablePath, fileName); #if FAKESMC_SUPPORT - if (!strcmp(fileName, "EmbeddedFakeSMC")) + if (!strcmp(fileName, "EmbeddedFakeSMC")) { verbose("\t Loading embedded FakeSMC: "); embedded = malloc(FakeSMC_un_len); @@ -1531,12 +1531,14 @@ case 3: kernelOSVer = 0xA0C0200; break; case 4: kernelOSVer = 0xA0C0300; break; case 5: kernelOSVer = 0xA0C0400; break; - default:kernelOSVer = 0xA0C0400; break; //Last known kernel (add here updates) + case 6: kernelOSVer = 0xA0C0500; break; +// case 7: kernelOSVer = 0xA0C0600; break; + default:kernelOSVer = 0xA0C0500; break; //Last known kernel (add here updates) } break; default: - kernelOSVer = 0xA0C0400; - break; //Last known kernel is Sierra 10.12.4 + kernelOSVer = 0xA0C0500; + break; //Last known kernel is Sierra 10.12.5 } } else @@ -1595,8 +1597,10 @@ case 0xA0C0200: gDarwinMajor = 16; gDarwinMinor = 3; gDarwinRev = 0; break; // 10.12.2 case 0xA0C0300: gDarwinMajor = 16; gDarwinMinor = 4; gDarwinRev = 0; break; // 10.12.3 case 0xA0C0400: gDarwinMajor = 16; gDarwinMinor = 5; gDarwinRev = 0; break; // 10.12.4 + case 0xA0C0500: gDarwinMajor = 16; gDarwinMinor = 6; gDarwinRev = 0; break; // 10.12.5 +// case 0xA0C0600: gDarwinMajor = 16; gDarwinMinor = x; gDarwinRev = x; break; // 10.12.6 // default = last known kernel - default: gDarwinMajor = 16; gDarwinMinor = 5; gDarwinRev = 0; break; // 10.12.4; + default: gDarwinMajor = 16; gDarwinMinor = 6; gDarwinRev = 0; break; // 10.12.5; } } Index: branches/ErmaC/Enoch/i386/boot2/boot.c =================================================================== --- branches/ErmaC/Enoch/i386/boot2/boot.c (revision 2881) +++ branches/ErmaC/Enoch/i386/boot2/boot.c (revision 2882) @@ -1341,8 +1341,8 @@ // =============================================================================== - bootArgs->csrCapabilities = CSR_VALID_FLAGS; - bootArgs->boot_SMC_plimit = 0; + bootArgs->csrCapabilities = CSR_VALID_FLAGS; + bootArgs->boot_SMC_plimit = 0; } } Index: branches/ErmaC/Enoch/i386/boot2/options.c =================================================================== --- branches/ErmaC/Enoch/i386/boot2/options.c (revision 2881) +++ branches/ErmaC/Enoch/i386/boot2/options.c (revision 2882) @@ -377,7 +377,7 @@ //========================================================================== -static const MenuItem * gMenuItems = NULL; +static const MenuItem *gMenuItems = NULL; static int gMenuItemCount; static int gMenuRow; @@ -1387,7 +1387,7 @@ gOverrideKernel = true; } - // Ermac : Inject "kext-dev-mode=1" if OS X 10.10 is detected + // ErmaC: Inject "kext-dev-mode=1" if OS X 10.10 is detected if ( (gMacOSVersion[3] == '1') && (gMacOSVersion[4] == '0') ) // OS X is 10.10 { verbose("Added: kext-dev-mode=1\n");