summaryrefslogtreecommitdiffstats
path: root/usr.sbin
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/sade/main.c6
-rw-r--r--usr.sbin/sade/sade.h1
-rw-r--r--usr.sbin/sysinstall/main.c6
-rw-r--r--usr.sbin/sysinstall/modules.c10
-rw-r--r--usr.sbin/sysinstall/sysinstall.h1
5 files changed, 24 insertions, 0 deletions
diff --git a/usr.sbin/sade/main.c b/usr.sbin/sade/main.c
index b9ac365..3b1df90 100644
--- a/usr.sbin/sade/main.c
+++ b/usr.sbin/sade/main.c
@@ -127,6 +127,12 @@ main(int argc, char **argv)
/* Probe for all relevant devices on the system */
deviceGetAll();
+ /* Prompt for the driver floppy if appropriate. */
+ if (!pvariable_get("driverFloppyCheck")) {
+ driverFloppyCheck();
+ pvariable_set("driverFloppyCheck=1");
+ }
+
/* First, see if we have any arguments to process (and argv[0] counts if it's not "sysinstall") */
if (!RunningAsInit) {
int i, start_arg;
diff --git a/usr.sbin/sade/sade.h b/usr.sbin/sade/sade.h
index 0cf0110..5f19c13 100644
--- a/usr.sbin/sade/sade.h
+++ b/usr.sbin/sade/sade.h
@@ -757,6 +757,7 @@ extern void restorescr(WINDOW *w);
extern char *sstrncpy(char *dst, const char *src, int size);
/* modules.c */
+extern void driverFloppyCheck(void);
extern void moduleInitialize(void);
extern int kldBrowser(dialogMenuItem *self);
diff --git a/usr.sbin/sysinstall/main.c b/usr.sbin/sysinstall/main.c
index b9ac365..3b1df90 100644
--- a/usr.sbin/sysinstall/main.c
+++ b/usr.sbin/sysinstall/main.c
@@ -127,6 +127,12 @@ main(int argc, char **argv)
/* Probe for all relevant devices on the system */
deviceGetAll();
+ /* Prompt for the driver floppy if appropriate. */
+ if (!pvariable_get("driverFloppyCheck")) {
+ driverFloppyCheck();
+ pvariable_set("driverFloppyCheck=1");
+ }
+
/* First, see if we have any arguments to process (and argv[0] counts if it's not "sysinstall") */
if (!RunningAsInit) {
int i, start_arg;
diff --git a/usr.sbin/sysinstall/modules.c b/usr.sbin/sysinstall/modules.c
index 67a8c89..252ad30 100644
--- a/usr.sbin/sysinstall/modules.c
+++ b/usr.sbin/sysinstall/modules.c
@@ -36,6 +36,7 @@
#include <dirent.h>
#include <fcntl.h>
#include <fnmatch.h>
+#include <kenv.h>
/* Prototypes */
static int kldModuleFire(dialogMenuItem *self);
@@ -96,6 +97,15 @@ moduleInitialize(void)
}
}
+void
+driverFloppyCheck(void)
+{
+ /* Prompt for the driver floppy if requested. */
+ if (kenv(KENV_GET, "driver_floppy", NULL, 0) >= 0 &&
+ !msgYesNo("Would you like to load kernel modules from the driver floppy?"))
+ (void)kldBrowser(NULL);
+}
+
int
kldBrowser(dialogMenuItem *self)
{
diff --git a/usr.sbin/sysinstall/sysinstall.h b/usr.sbin/sysinstall/sysinstall.h
index 0cf0110..5f19c13 100644
--- a/usr.sbin/sysinstall/sysinstall.h
+++ b/usr.sbin/sysinstall/sysinstall.h
@@ -757,6 +757,7 @@ extern void restorescr(WINDOW *w);
extern char *sstrncpy(char *dst, const char *src, int size);
/* modules.c */
+extern void driverFloppyCheck(void);
extern void moduleInitialize(void);
extern int kldBrowser(dialogMenuItem *self);
OpenPOWER on IntegriCloud