--- loader2/cdinstall.c | 14 ++---- loader2/cdinstall.h | 8 +-- loader2/driverdisk.c | 14 +---- loader2/driverdisk.h | 1 - loader2/driverselect.c | 9 +--- loader2/hardware.c | 78 +++++---------------------- loader2/hardware.h | 22 ++------ loader2/hdinstall.c | 20 +++----- loader2/hdinstall.h | 4 +- loader2/loader.c | 136 +++++++++--------------------------------------- loader2/loader.h | 3 - loader2/method.h | 5 +-- loader2/nfsinstall.c | 8 +-- loader2/nfsinstall.h | 4 +- loader2/telnetd.c | 4 +- loader2/telnetd.h | 4 +- loader2/urlinstall.c | 7 +-- loader2/urlinstall.h | 4 +- 18 files changed, 70 insertions(+), 275 deletions(-) diff --git a/loader2/cdinstall.c b/loader2/cdinstall.c index 165348a..c6b3394 100644 --- a/loader2/cdinstall.c +++ b/loader2/cdinstall.c @@ -220,8 +220,7 @@ static void queryCDMediaCheck(char *dev, char *location) { * as /mnt/runtime. */ char * setupCdrom(char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps modDeps, int interactive, int requirepkgs) { + int interactive, int requirepkgs) { int i, r, rc; int foundinvalid = 0; int stage2inram = 0; @@ -343,20 +342,15 @@ char * setupCdrom(char * location, struct loaderData_s * loaderData, /* try to find a install CD non-interactively */ char * findAnacondaCD(char * location, - moduleInfoSet modInfo, - moduleList modLoaded, - moduleDeps modDeps, int requirepkgs) { - return setupCdrom(location, NULL, modInfo, modLoaded, modDeps, 0, requirepkgs); + return setupCdrom(location, NULL, 0, requirepkgs); } /* look for a CD and mount it. if we have problems, ask */ char * mountCdromImage(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr) { + char * location, struct loaderData_s * loaderData) { - return setupCdrom(location, loaderData, modInfo, modLoaded, *modDepsPtr, 1, 1); + return setupCdrom(location, loaderData, 1, 1); } void setKickstartCD(struct loaderData_s * loaderData, int argc, char ** argv) { diff --git a/loader2/cdinstall.h b/loader2/cdinstall.h index cf3a64e..314a2c5 100644 --- a/loader2/cdinstall.h +++ b/loader2/cdinstall.h @@ -4,13 +4,9 @@ #include "method.h" char * mountCdromImage(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr); + char * location, struct loaderData_s * loaderData); -char * findAnacondaCD(char * location, moduleInfoSet modInfo, - moduleList modLoaded, moduleDeps modDeps, - int requirepkgs); +char * findAnacondaCD(char * location, int requirepkgs); void setKickstartCD(struct loaderData_s * loaderData, int argc, diff --git a/loader2/driverdisk.c b/loader2/driverdisk.c index 6707ad4..d4bca34 100644 --- a/loader2/driverdisk.c +++ b/loader2/driverdisk.c @@ -32,7 +32,6 @@ #include "fwloader.h" #include "method.h" #include "modules.h" -#include "moduledeps.h" #include "moduleinfo.h" #include "windows.h" #include "hardware.h" @@ -96,7 +95,6 @@ static void copyErrorFn (char *msg) { /* this copies the contents of the driver disk to a ramdisk and loads * the moduleinfo, etc. assumes a "valid" driver disk mounted at mntpt */ static int loadDriverDisk(struct loaderData_s *loaderData, char *mntpt) { - moduleDeps *modDepsPtr = loaderData->modDepsPtr; moduleInfoSet modInfo = loaderData->modInfo; char file[200], dest[200]; char * title; @@ -154,9 +152,6 @@ static int loadDriverDisk(struct loaderData_s *loaderData, char *mntpt) { sprintf(file, "%s/modinfo", mntpt); readModuleInfo(file, modInfo, location, 1); - sprintf(file, "%s/modules.dep", mntpt); - mlLoadDeps(modDepsPtr, file); - sprintf(file, "%s/modules.alias", mntpt); pciReadDrivers(file); @@ -241,10 +236,6 @@ int getRemovableDevices(char *** devNames) { */ int loadDriverFromMedia(int class, struct loaderData_s *loaderData, int usecancel, int noprobe) { - moduleList modLoaded = loaderData->modLoaded; - moduleDeps *modDepsPtr = loaderData->modDepsPtr; - moduleInfoSet modInfo = loaderData->modInfo; - char * device = NULL, * part = NULL, * ddfile = NULL; char ** devNames = NULL; enum { DEV_DEVICE, DEV_PART, DEV_CHOOSEFILE, DEV_LOADFILE, @@ -470,7 +461,7 @@ int loadDriverFromMedia(int class, struct loaderData_s *loaderData, break; } - busProbe(modInfo, modLoaded, *modDepsPtr, 0); + busProbe(0); devices = probeDevices(class, BUS_UNSPEC, PROBE_LOADED); if (devices) @@ -550,8 +541,7 @@ static void loadFromLocation(struct loaderData_s * loaderData, char * dir) { } loadDriverDisk(loaderData, dir); - busProbe(loaderData->modInfo, loaderData->modLoaded, * - loaderData->modDepsPtr, 0); + busProbe(0); } void getDDFromSource(struct loaderData_s * loaderData, char * src) { diff --git a/loader2/driverdisk.h b/loader2/driverdisk.h index a9aece6..93da18e 100644 --- a/loader2/driverdisk.h +++ b/loader2/driverdisk.h @@ -3,7 +3,6 @@ #include "loader.h" #include "modules.h" -#include "moduledeps.h" #include "moduleinfo.h" int loadDriverFromMedia(int class, struct loaderData_s *loaderData, diff --git a/loader2/driverselect.c b/loader2/driverselect.c index 17adf69..acba7d5 100644 --- a/loader2/driverselect.c +++ b/loader2/driverselect.c @@ -141,7 +141,6 @@ int chooseManualDriver(int class, struct loaderData_s *loaderData) { struct sortModuleList * sortedOrder; char giveArgs = ' '; char ** moduleArgs = NULL; - moduleDeps modDeps = *loaderData->modDepsPtr; moduleInfoSet modInfo = loaderData->modInfo; newtComponent text, f, ok, back, argcheckbox, listbox; @@ -167,11 +166,6 @@ int chooseManualDriver(int class, struct loaderData_s *loaderData) { numSorted = 0; for (i = 0; i < modInfo->numModules; i++) { - if (mlModuleInList(modInfo->moduleList[i].moduleName, loaderData->modLoaded) || - !modInfo->moduleList[i].description || - ((type != DRIVER_ANY) && - (type != modInfo->moduleList[i].major))) - continue; sortedOrder[numSorted].index = i; sortedOrder[numSorted++].modInfo = modInfo; } @@ -274,8 +268,7 @@ int chooseManualDriver(int class, struct loaderData_s *loaderData) { return chooseManualDriver(class, loaderData); } - mlLoadModule(modInfo->moduleList[num].moduleName, loaderData->modLoaded, modDeps, - modInfo, moduleArgs); + mlLoadModule(modInfo->moduleList[num].moduleName, moduleArgs); free(sortedOrder); return LOADER_OK; diff --git a/loader2/hardware.c b/loader2/hardware.c index fff8407..ccd40dd 100644 --- a/loader2/hardware.c +++ b/loader2/hardware.c @@ -156,8 +156,7 @@ int probeiSeries(moduleInfoSet modInfo, moduleList modLoaded, * FIXME: this syntax is likely to change in a future release * but is done as a quick hack for the present. */ -int earlyModuleLoad(moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps modDeps, int justProbe) { +int earlyModuleLoad(int justProbe) { int fd, len, i; char buf[1024], *cmdLine; int argc; @@ -181,77 +180,31 @@ int earlyModuleLoad(moduleInfoSet modInfo, moduleList modLoaded, for (i=0; i < argc; i++) { if (!strncasecmp(argv[i], "driverload=", 11)) { logMessage(INFO, "loading %s early", argv[i] + 11); - mlLoadModuleSet(argv[i] + 11, modLoaded, modDeps, modInfo); + mlLoadModuleSet(argv[i] + 11); } } return 0; } -int busProbe(moduleInfoSet modInfo, moduleList modLoaded, moduleDeps modDeps, - int justProbe) { - int i; - char ** modList; - char modules[1024]; - - /* we always want to try to find out about pcmcia controllers even - * if using noprobe */ - initializePcmciaController(modLoaded, modDeps, modInfo); - - /* we can't really *probe* on iSeries, but we can pretend */ - probeiSeries(modInfo, modLoaded, modDeps); - +int busProbe(int justProbe) { /* autodetect whatever we can */ - if (detectHardware(modInfo, &modList)) { - logMessage(ERROR, "failed to scan pci bus!"); + if (justProbe) return 0; - } else if (modList && justProbe) { - for (i = 0; modList[i]; i++) - printf("%s\n", modList[i]); - } else if (modList) { - *modules = '\0'; - - for (i = 0; modList[i]; i++) { - if (i) strcat(modules, ":"); - strcat(modules, modList[i]); - } - - mlLoadModuleSet(modules, modLoaded, modDeps, modInfo); - } else - logMessage(INFO, "found nothing"); - - return 0; + return detectHardware(NULL); } -void ipv6Setup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo) { +void ipv6Setup() { if (!FL_NOIPV6(flags)) - mlLoadModule("ipv6", modLoaded, modDeps, modInfo, NULL); -} - - -void scsiSetup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo) { - mlLoadModuleSet("scsi_mod:sd_mod:sr_mod", modLoaded, modDeps, modInfo); -#if defined(__s390__) || defined(__s390x__) - mlLoadModule("zfcp", modLoaded, modDeps, modInfo, NULL); -#endif - mlLoadModule("iscsi_tcp", modLoaded, modDeps, modInfo, NULL); -} - -void ideSetup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo) { - mlLoadModuleSet("cdrom:ide-cd", modLoaded, modDeps, modInfo); + mlLoadModule("ipv6", NULL); } - /* check if the system has been booted with dasd parameters */ /* These parameters define the order in which the DASDs */ /* are visible to Linux. Otherwise load dasd modules probeonly, */ /* then parse proc to find active DASDs */ /* Reload dasd_mod with correct range of DASD ports */ -void dasdSetup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo) { +void dasdSetup() { #if !defined(__s390__) && !defined(__s390x__) return; #else @@ -283,24 +236,21 @@ void dasdSetup(moduleList modLoaded, moduleDeps modDeps, free(line); } if(dasd_parms[0]) { - mlLoadModule("dasd_mod", modLoaded, modDeps, modInfo, dasd_parms); + mlLoadModule("dasd_mod", dasd_parms); - mlLoadModuleSet("dasd_diag_mod:dasd_fba_mod:dasd_eckd_mod", - modLoaded, modDeps, modInfo); + mlLoadModuleSet("dasd_diag_mod:dasd_fba_mod:dasd_eckd_mod"); free(dasd_parms); return; } else { dasd_parms[0] = "dasd=autodetect"; - mlLoadModule("dasd_mod", modLoaded, modDeps, modInfo, dasd_parms); - mlLoadModuleSet("dasd_diag_mod:dasd_fba_mod:dasd_eckd_mod", - modLoaded, modDeps, modInfo); + mlLoadModule("dasd_mod", dasd_parms); + mlLoadModuleSet("dasd_diag_mod:dasd_fba_mod:dasd_eckd_mod"); free(dasd_parms); } #endif } -void spufsSetup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo) { +void spufsSetup() { #if !defined(__powerpc__) return; #else @@ -311,7 +261,7 @@ void spufsSetup(moduleList modLoaded, moduleDeps modDeps, while (fgets(buf, 1024, fd) != NULL) { if(!strncmp(buf, "cpu\t\t:", 5)) { if(strstr(buf, "Cell")) { - mlLoadModule("spufs", modLoaded, modDeps, modInfo, NULL); + mlLoadModule("spufs", NULL); break; } } diff --git a/loader2/hardware.h b/loader2/hardware.h index db96610..b9d1ce8 100644 --- a/loader2/hardware.h +++ b/loader2/hardware.h @@ -3,24 +3,12 @@ #include "modules.h" -int scsiTapeInitialize(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo); +int earlyModuleLoad(int justProbe); +int busProbe(int justProbe); -int earlyModuleLoad(moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps modDeps, int justProbe); -int busProbe(moduleInfoSet modInfo, moduleList modLoaded, moduleDeps modDeps, - int justProbe); +void dasdSetup(); -void scsiSetup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo); -void ideSetup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo); -void dasdSetup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo); +void ipv6Setup(); -void ipv6Setup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo); - -void spufsSetup(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo); +void spufsSetup(); #endif diff --git a/loader2/hdinstall.c b/loader2/hdinstall.c index e9780d2..f238e1c 100644 --- a/loader2/hdinstall.c +++ b/loader2/hdinstall.c @@ -50,9 +50,7 @@ extern uint64_t flags; /* pull in second stage image for hard drive install */ static int loadHDImages(char * prefix, char * dir, char * device, char * mntpoint, - char * location, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr) { + char * location) { int fd = 0, rc, idx; char *path, *target = NULL, *dest, *cdurl; char *stg2list[] = {"stage2.img", "minstg2.img", NULL}; @@ -65,7 +63,7 @@ static int loadHDImages(char * prefix, char * dir, idx = 0; /* try to see if we're booted off of a CD with stage2 */ - cdurl = findAnacondaCD(location, modInfo, modLoaded, *modDepsPtr, 0); + cdurl = findAnacondaCD(location, 0); if (cdurl) { logMessage(INFO, "Detected stage 2 image on CD"); winStatus(50, 3, _("Media Detected"), @@ -132,9 +130,7 @@ static int loadHDImages(char * prefix, char * dir, } /* given a partition device and directory, tries to mount hd install image */ -static char * setupIsoImages(char * device, char * dirName, char * location, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr) { +static char * setupIsoImages(char * device, char * dirName, char * location) { int rc; char * url; char filespec[1024]; @@ -172,7 +168,7 @@ static char * setupIsoImages(char * device, char * dirName, char * location, /* This code is for copying small stage2 into ram */ /* and mounting */ rc = loadHDImages("/tmp/loopimage", "/", "/dev/loop1", - "/mnt/runtime", location, modInfo, modLoaded, modDepsPtr); + "/mnt/runtime", location); if (rc) { newtWinMessage(_("Error"), _("OK"), _("An error occured reading the install " @@ -209,9 +205,7 @@ static char * setupIsoImages(char * device, char * dirName, char * location, * ISO images on that filesystem */ char * mountHardDrive(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr) { + char * location, struct loaderData_s * loaderData) { int rc; int i; @@ -251,7 +245,7 @@ char * mountHardDrive(struct installMethod * method, if (!strncmp(kspart, "/dev/", 5)) kspart = kspart + 5; - url = setupIsoImages(kspart, ksdirectory, location, modInfo, modLoaded, modDepsPtr); + url = setupIsoImages(kspart, ksdirectory, location); if (!url) { logMessage(ERROR, "unable to find %s installation images on hd", getProductName()); @@ -384,7 +378,7 @@ char * mountHardDrive(struct installMethod * method, logMessage(INFO, "partition %s selected", selpart); - url = setupIsoImages(selpart + 5, dir, location, modInfo, modLoaded, modDepsPtr); + url = setupIsoImages(selpart + 5, dir, location); if (!url) { newtWinMessage(_("Error"), _("OK"), _("Device %s does not appear to contain " diff --git a/loader2/hdinstall.h b/loader2/hdinstall.h index dcb59b3..317b733 100644 --- a/loader2/hdinstall.h +++ b/loader2/hdinstall.h @@ -12,9 +12,7 @@ struct hdInstallData { void setKickstartHD(struct loaderData_s * loaderData, int argc, char ** argv); char * mountHardDrive(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr); + char * location, struct loaderData_s * loaderData); int kickstartFromHD(char *kssrc); int kickstartFromBD(char *kssrc); diff --git a/loader2/loader.c b/loader2/loader.c index 3792671..d330254 100644 --- a/loader2/loader.c +++ b/loader2/loader.c @@ -63,16 +63,11 @@ /* module stuff */ #include "modules.h" #include "moduleinfo.h" -#include "moduledeps.h" -#include "modstubs.h" #include "driverdisk.h" /* hardware stuff */ #include "hardware.h" -#include "firewire.h" -#include "pcmcia.h" -#include "usb.h" /* install method stuff */ #include "method.h" @@ -244,8 +239,7 @@ char * getProductPath(void) { return productPath; } -void initializeConsole(moduleList modLoaded, moduleDeps modDeps, - moduleInfoSet modInfo) { +void initializeConsole() { /* enable UTF-8 console */ printf("\033%%G"); fflush(stdout); @@ -928,7 +922,7 @@ static void checkForRam(void) { } } -static int haveDeviceOfType(int type, moduleList modLoaded) { +static int haveDeviceOfType(int type) { struct device ** devices; devices = probeDevices(type, BUS_UNSPEC, PROBE_LOADED); @@ -941,9 +935,7 @@ static int haveDeviceOfType(int type, moduleList modLoaded) { /* fsm for the basics of the loader. */ static char *doLoaderMain(char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, - moduleList modLoaded, - moduleDeps * modDepsPtr) { + moduleInfoSet modInfo) { enum { STEP_LANG, STEP_KBD, STEP_METHOD, STEP_DRIVER, STEP_DRIVERDISK, STEP_NETWORK, STEP_IFACE, STEP_IP, STEP_URL, STEP_DONE } step; @@ -984,7 +976,7 @@ static char *doLoaderMain(char * location, * we can fast-path the CD and not make people answer questions in * text mode. */ if (!FL_ASKMETHOD(flags) && !FL_KICKSTART(flags)) { - url = findAnacondaCD(location, modInfo, modLoaded, * modDepsPtr, !FL_RESCUE(flags)); + url = findAnacondaCD(location, !FL_RESCUE(flags)); /* if we found a CD and we're not in rescue or vnc mode return */ /* so we can short circuit straight to stage 2 from CD */ if (url && (!FL_RESCUE(flags) && !hasGraphicalOverride())) @@ -1099,7 +1091,7 @@ static char *doLoaderMain(char * location, break; case STEP_DRIVER: { - if (needed == -1 || haveDeviceOfType(needed, modLoaded)) { + if (needed == -1 || haveDeviceOfType(needed)) { step = STEP_NETWORK; dir = 1; needed = -1; @@ -1157,7 +1149,7 @@ static char *doLoaderMain(char * location, } needsNetwork = 1; - if (!haveDeviceOfType(CLASS_NETWORK, modLoaded)) { + if (!haveDeviceOfType(CLASS_NETWORK)) { needed = CLASS_NETWORK; step = STEP_DRIVER; break; @@ -1293,8 +1285,7 @@ static char *doLoaderMain(char * location, url = installMethods[validMethods[methodNum]].mountImage( installMethods + validMethods[methodNum], - location, loaderData, modInfo, modLoaded, - modDepsPtr); + location, loaderData); if (!url) { step = STEP_IP ; loaderData->ipinfo_set = 0; @@ -1317,29 +1308,13 @@ static char *doLoaderMain(char * location, static int manualDeviceCheck(struct loaderData_s *loaderData) { char ** devices; int i, j, rc, num = 0; - struct moduleInfo * mi; unsigned int width = 40; char * buf; - moduleInfoSet modInfo = loaderData->modInfo; - moduleList modLoaded = loaderData->modLoaded; - do { - devices = malloc((modLoaded->numModules + 1) * sizeof(*devices)); - for (i = 0, j = 0; i < modLoaded->numModules; i++) { - if (!modLoaded->mods[i].weLoaded) continue; - - if (!(mi = findModuleInfo(modInfo, modLoaded->mods[i].name)) || - (!mi->description)) - continue; - - rc = asprintf(&devices[j], "%s (%s)", mi->description, - modLoaded->mods[i].name); - if (strlen(devices[j]) > width) - width = strlen(devices[j]); - j++; - } - + /* FIXME */ + devices = malloc(1 * sizeof(*devices)); + j = 0; devices[j] = NULL; if (width > 70) @@ -1460,15 +1435,12 @@ int main(int argc, char ** argv) { struct stat sb; struct serial_struct si; - int i; char * arg; FILE *f; char twelve = 12; moduleInfoSet modInfo; - moduleList modLoaded; - moduleDeps modDeps; char *url = NULL; @@ -1496,13 +1468,6 @@ int main(int argc, char ** argv) { /* Make sure sort order is right. */ setenv ("LC_COLLATE", "C", 1); - if (!strcmp(argv[0] + strlen(argv[0]) - 6, "insmod")) - return ourInsmodCommand(argc, argv); - if (!strcmp(argv[0] + strlen(argv[0]) - 8, "modprobe")) - return ourInsmodCommand(argc, argv); - if (!strcmp(argv[0] + strlen(argv[0]) - 5, "rmmod")) - return ourRmmodCommand(argc, argv); - /* Very first thing, set up tracebacks and debug features. */ rc = anaconda_trace_init(); @@ -1571,10 +1536,10 @@ int main(int argc, char ** argv) { logMessage(INFO, "text mode forced due to serial/virtpconsole"); flags |= LOADER_FLAGS_TEXT; } - set_fw_search_path(&loaderData, "/firmware:/modules/firmware"); + set_fw_search_path(&loaderData, "/firmware:/lib/firmware"); start_fw_loader(&loaderData); - arg = FL_TESTING(flags) ? "./module-info" : "/modules/module-info"; + arg = FL_TESTING(flags) ? "./module-info" : "/lib/modules/module-info"; modInfo = newModuleInfoSet(); if (readModuleInfo(arg, modInfo, NULL, 0)) { fprintf(stderr, "failed to read %s\n", arg); @@ -1582,11 +1547,7 @@ int main(int argc, char ** argv) { stop_fw_loader(&loaderData); exit(1); } - mlReadLoadedList(&modLoaded); - modDeps = mlNewDeps(); - mlLoadDeps(&modDeps, "/modules/modules.dep"); - - initializeConsole(modLoaded, modDeps, modInfo); + initializeConsole(); checkForRam(); @@ -1596,40 +1557,23 @@ int main(int argc, char ** argv) { setenv("TERM", "vt100", 1); #if defined(__powerpc__) /* hack for pcspkr breaking ppc right now */ - mlLoadModuleSet("cramfs:vfat:nfs:loop:isofs:floppy:edd:squashfs:ext3:ext4dev:ext2", - modLoaded, modDeps, modInfo); + mlLoadModuleSet("cramfs:vfat:nfs:loop:isofs:floppy:edd:squashfs:ext3:ext4dev:ext2"); #else - mlLoadModuleSet("cramfs:vfat:nfs:loop:isofs:floppy:edd:pcspkr:squashfs:ext4dev:ext3:ext2", - modLoaded, modDeps, modInfo); + mlLoadModuleSet("cramfs:vfat:nfs:loop:isofs:floppy:edd:pcspkr:squashfs:ext4dev:ext3:ext2"); #endif /* IPv6 support is conditional */ - ipv6Setup(modLoaded, modDeps, modInfo); + ipv6Setup(); /* now let's do some initial hardware-type setup */ - ideSetup(modLoaded, modDeps, modInfo); - scsiSetup(modLoaded, modDeps, modInfo); - dasdSetup(modLoaded, modDeps, modInfo); - spufsSetup(modLoaded, modDeps, modInfo); - - /* Note we *always* do this. If you could avoid this you could get - a system w/o USB keyboard support, which would be bad. */ - usbInitialize(modLoaded, modDeps, modInfo); - - /* now let's initialize any possible firewire. fun */ - firewireInitialize(modLoaded, modDeps, modInfo); - - /* explicitly read this to let libkudzu know we want to merge - * in future tables rather than replace the initial one */ - pciReadDrivers("/modules/modules.alias"); + dasdSetup(); + spufsSetup(); if (loaderData.lang && (loaderData.lang_set == 1)) { setLanguage(loaderData.lang); } /* FIXME: this is a bit of a hack */ - loaderData.modLoaded = modLoaded; - loaderData.modDepsPtr = &modDeps; loaderData.modInfo = modInfo; if (FL_MODDISK(flags)) { @@ -1649,9 +1593,10 @@ int main(int argc, char ** argv) { * FIXME: this syntax is likely to change in a future release * but is done as a quick hack for the present. */ - earlyModuleLoad(modInfo, modLoaded, modDeps, 0); + mlInitModuleConfig(); + earlyModuleLoad(0); - busProbe(modInfo, modLoaded, modDeps, 0); + busProbe(FL_NOPROBE(flags)); /* JKFIXME: we'd really like to do this before the busprobe, but then * we won't have network devices available (and that's the only thing @@ -1675,9 +1620,9 @@ int main(int argc, char ** argv) { } if (FL_TELNETD(flags)) - startTelnetd(&loaderData, modInfo, modLoaded, modDeps); + startTelnetd(&loaderData); - url = doLoaderMain("/mnt/source", &loaderData, modInfo, modLoaded, &modDeps); + url = doLoaderMain("/mnt/source", &loaderData, modInfo); if (!FL_TESTING(flags)) { int ret; @@ -1711,14 +1656,6 @@ int main(int argc, char ** argv) { spawnShell(); /* we can attach gdb now :-) */ - /* JKFIXME: kickstart devices crap... probably kind of bogus now though */ - - - /* we might have already loaded these, but trying again doesn't hurt */ - ideSetup(modLoaded, modDeps, modInfo); - scsiSetup(modLoaded, modDeps, modInfo); - busProbe(modInfo, modLoaded, modDeps, 0); - if (FL_NOPROBE(flags) && !loaderData.ksFile) { startNewt(); manualDeviceCheck(&loaderData); @@ -1729,17 +1666,7 @@ int main(int argc, char ** argv) { else if (FL_UPDATES(flags)) loadUpdates(&loaderData); - mlLoadModuleSet("md:raid0:raid1:raid5:raid6:raid456:raid10:linear:fat:msdos:jbd:lock_nolock:gfs2:reiserfs:jfs:xfs:dm-mod:dm-zero:dm-mirror:dm-snapshot:dm-multipath:dm-round-robin:dm-emc:dm-crypt:blkcipher:cbc:aes_generic:sha256_generic", modLoaded, modDeps, modInfo); - - usbInitializeMouse(modLoaded, modDeps, modInfo); - - /* we've loaded all the modules we're going to. write out a file - * describing which scsi disks go with which scsi adapters */ - writeScsiDisks(modLoaded); - - /* if we are in rescue mode lets load st.ko for tape support */ - if (FL_RESCUE(flags)) - scsiTapeInitialize(modLoaded, modDeps, modInfo); + mlLoadModuleSet("md:raid0:raid1:raid5:raid6:raid456:raid10:linear:fat:msdos:jbd:lock_nolock:gfs2:reiserfs:jfs:xfs:dm-mod:dm-zero:dm-mirror:dm-snapshot:dm-multipath:dm-round-robin:dm-emc:dm-crypt:blkcipher:cbc:aes:sha256"); /* we only want to use RHupdates on nfs installs. otherwise, we'll * use files on the first iso image and not be able to umount it */ @@ -1881,21 +1808,6 @@ int main(int argc, char ** argv) { *argptr++ = "--loglevel"; *argptr++ = loaderData.logLevel; } - - for (i = 0; i < modLoaded->numModules; i++) { - if (!modLoaded->mods[i].path) continue; - if (!strcmp(modLoaded->mods[i].path, - "/mnt/runtime/modules/modules.cgz")) { - continue; - } - - *argptr++ = "--module"; - *argptr = alloca(80); - sprintf(*argptr, "%s:%s", modLoaded->mods[i].path, - modLoaded->mods[i].name); - - argptr++; - } } *argptr = NULL; diff --git a/loader2/loader.h b/loader2/loader.h index e4b7f06..014e7b6 100644 --- a/loader2/loader.h +++ b/loader2/loader.h @@ -96,7 +96,6 @@ char * getProductPath(void); char * getProductArch(void); #include "modules.h" -#include "moduledeps.h" /* JKFIXME: I don't like all of the _set attribs, but without them, * we can't tell if it was explicitly set by kickstart/cmdline or * if we just got it going through the install. */ @@ -127,8 +126,6 @@ struct loaderData_s { char *fw_search_pathz; size_t fw_search_pathz_len; - moduleList modLoaded; - moduleDeps * modDepsPtr; moduleInfoSet modInfo; }; diff --git a/loader2/method.h b/loader2/method.h index 112e725..4546924 100644 --- a/loader2/method.h +++ b/loader2/method.h @@ -2,7 +2,6 @@ #define H_METHOD #include "modules.h" -#include "moduledeps.h" #include "loader.h" #include <kudzu/kudzu.h> @@ -21,9 +20,7 @@ struct installMethod { int network; enum deviceClass deviceType; /* for pcmcia */ char * (*mountImage)(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr); + char * location, struct loaderData_s * loaderData); }; int umountLoopback(char * mntpoint, char * device); diff --git a/loader2/nfsinstall.c b/loader2/nfsinstall.c index eca7ac5..e700a27 100644 --- a/loader2/nfsinstall.c +++ b/loader2/nfsinstall.c @@ -76,9 +76,7 @@ int nfsGetSetup(char ** hostptr, char ** dirptr) { } char * mountNfsImage(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr) { + char * location, struct loaderData_s * loaderData) { char * host = NULL; char * directory = NULL; char * mountOpts = NULL; @@ -153,7 +151,7 @@ char * mountNfsImage(struct installMethod * method, if (!access("/mnt/source/images/stage2.img", R_OK)) { logMessage(INFO, "can access /mnt/source/images/stage2.img"); /* try to see if we're booted off of a CD with stage2 */ - cdurl = findAnacondaCD("/mnt/stage2", modInfo, modLoaded, *modDepsPtr, 0); + cdurl = findAnacondaCD("/mnt/stage2", 0); if (cdurl) { logMessage(INFO, "Detected stage 2 image on CD"); winStatus(50, 3, _("Media Detected"), @@ -205,7 +203,7 @@ char * mountNfsImage(struct installMethod * method, logMessage(WARNING, "failed to mount iso %s loopback", path); else { /* try to see if we're booted off of a CD with stage2 */ - cdurl = findAnacondaCD("/mnt/stage2", modInfo, modLoaded, *modDepsPtr, 0); + cdurl = findAnacondaCD("/mnt/stage2", 0); if (cdurl) { logMessage(INFO, "Detected stage 2 image on CD"); winStatus(50, 3, _("Media Detected"), diff --git a/loader2/nfsinstall.h b/loader2/nfsinstall.h index f1dc74b..5eb158c 100644 --- a/loader2/nfsinstall.h +++ b/loader2/nfsinstall.h @@ -14,9 +14,7 @@ void setKickstartNfs(struct loaderData_s * loaderData, int argc, char ** argv); int kickstartFromNfs(char * url, struct loaderData_s * loaderData); char * mountNfsImage(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr); + char * location, struct loaderData_s * loaderData); int getFileFromNfs(char * url, char * dest, struct loaderData_s * loaderData); #endif diff --git a/loader2/telnetd.c b/loader2/telnetd.c index c624740..303c467 100644 --- a/loader2/telnetd.c +++ b/loader2/telnetd.c @@ -228,9 +228,7 @@ int beTelnet(void) { return 0; } -void startTelnetd(struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps modDeps) { +void startTelnetd(struct loaderData_s * loaderData) { char ret[47]; struct networkDeviceConfig netCfg; ip_addr_t *tip; diff --git a/loader2/telnetd.h b/loader2/telnetd.h index 145c55f..a60b635 100644 --- a/loader2/telnetd.h +++ b/loader2/telnetd.h @@ -1,8 +1,6 @@ #ifndef TELNETD_H #define TELNETD_H -void startTelnetd(struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps modDeps); +void startTelnetd(struct loaderData_s * loaderData); #endif diff --git a/loader2/urlinstall.c b/loader2/urlinstall.c index 3eb90ec..c38d01e 100644 --- a/loader2/urlinstall.c +++ b/loader2/urlinstall.c @@ -169,9 +169,7 @@ static int loadUrlImages(struct iurlinfo * ui) { } char * mountUrlImage(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDeps) { + char * location, struct loaderData_s * loaderData) { int rc; char * url; struct iurlinfo ui; @@ -236,8 +234,7 @@ char * mountUrlImage(struct installMethod * method, /* ok messy - see if we have a stage2 on local CD */ /* before trying to pull one over network */ - cdurl = findAnacondaCD(location, modInfo, modLoaded, - *modDeps, 0); + cdurl = findAnacondaCD(location, 0); if (cdurl) { /* verify that our URL is specifying the correct tree */ /* we do this by attempting to pull a .discinfo file */ diff --git a/loader2/urlinstall.h b/loader2/urlinstall.h index 0162c53..8d60685 100644 --- a/loader2/urlinstall.h +++ b/loader2/urlinstall.h @@ -12,9 +12,7 @@ void setKickstartUrl(struct loaderData_s * loaderData, int argc, char ** argv); int kickstartFromUrl(char * url, struct loaderData_s * loaderData); char * mountUrlImage(struct installMethod * method, - char * location, struct loaderData_s * loaderData, - moduleInfoSet modInfo, moduleList modLoaded, - moduleDeps * modDepsPtr); + char * location, struct loaderData_s * loaderData); int getFileFromUrl(char * url, char * dest, struct loaderData_s * loaderData); -- 1.5.3.7 _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list