Back out rev. 1.129 because it breaks the practice of auto-loading

hardware drivers.  Unlike pseudo-device drivers, which just attach
to the cloning framework and wait for "ifconfig create", h/w drivers
create interfaces for installed cards as soon as loaded.  The issue
of devd(8) involuntarily reloading modules should be dealt with in a
different way.
This commit is contained in:
yar 2007-03-24 20:26:54 +00:00
parent 5c635bf544
commit 4b29044813

View File

@ -228,6 +228,9 @@ main(int argc, char *argv[])
ifname = *argv;
argc--, argv++;
/* check and maybe load support for this interface */
ifmaybeload(ifname);
ifindex = if_nametoindex(ifname);
if (ifindex == 0) {
/*
@ -241,7 +244,6 @@ main(int argc, char *argv[])
if (iflen >= sizeof(name))
errx(1, "%s: cloning name too long",
ifname);
ifmaybeload(ifname);
ifconfig(argc, argv, NULL);
exit(0);
}