int loadPrebootRAMDisk() { mountRAMDisk("bt(0,0)/Extra/Preboot.dmg"); if (gRAMDiskMI != NULL) { printf("\n"); return 0; } else { return -1; } }
void processRAMDiskCommand(char ** argPtr, const char * cmd) { char * ptr = *argPtr; char param[1024]; getNextArg(&ptr, param); if (strcmp(cmd, "m") == 0) { mountRAMDisk(param); sleep(2); } else if (strcmp(cmd, "u") == 0) { umountRAMDisk(); sleep(2); } else if (strcmp(cmd, "e") == 0) { setRAMDiskBTHook(true); sleep(2); } else if (strcmp(cmd, "d") == 0) { setRAMDiskBTHook(false); sleep(2); } else if (strcmp(cmd, "i") == 0) { setActiveDisplayPage(1); clearScreenRows(0, 24); setCursorPosition(0, 0, 1); showInfoRAMDisk(); //Azi: check Chazi on these line breaks here*** printf("\n\nPress any key to continue.\n"); getchar(); setActiveDisplayPage(0); } else { setActiveDisplayPage(1); clearScreenRows(0, 24); setCursorPosition(0, 0, 1); printf("\nusage:\n"); printf("\n?rd i - display ramdisk information"); printf("\n?rd m <filename> - mount ramdisk image\n?rd u - unmount ramdisk image"); printf("\n?rd e - enable bt(0,0) alias\n?rd d - disable bt(0,0) alias"); printf("\n\nPress any key to continue.\n"); getchar(); setActiveDisplayPage(0); } }
int loadPrebootRAMDisk() { mountRAMDisk("bt(0,0)/Extra/Preboot.dmg"); if (gRAMDiskMI != NULL) { printf("\n"); // just a line break.. helps separating bdmesg*** return 0; } else { return -1; } }