From: Ben Gras Date: Thu, 8 Feb 2007 14:23:03 +0000 (+0000) Subject: supply instance to 2nd at_wini instance. X-Git-Tag: v3.1.3~91 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/zpipe.c?a=commitdiff_plain;h=ebde52a9bcd650176fa1caeff4adf70ab022f0fa;p=minix.git supply instance to 2nd at_wini instance. requires a little cooperation from at_wini. --- diff --git a/drivers/at_wini/at_wini.c b/drivers/at_wini/at_wini.c index 7b68446d4..95c567d6f 100644 --- a/drivers/at_wini/at_wini.c +++ b/drivers/at_wini/at_wini.c @@ -395,7 +395,7 @@ PRIVATE struct driver w_dtab = { /*===========================================================================* * at_winchester_task * *===========================================================================*/ -PUBLIC int main() +PUBLIC int main(int argc, char *argv[]) { /* Install signal handlers. Ask PM to transform signal into message. */ struct sigaction sa; @@ -406,6 +406,7 @@ PUBLIC int main() if (sigaction(SIGTERM,&sa,NULL)<0) panic("AT","sigaction failed", errno); /* Set special disk parameters then call the generic main loop. */ + env_setargs(argc, argv); init_params(); signal(SIGTERM, SIG_IGN); driver_task(&w_dtab); diff --git a/drivers/at_wini/at_wini.h b/drivers/at_wini/at_wini.h index b9d57aabd..3b0b8d0c4 100644 --- a/drivers/at_wini/at_wini.h +++ b/drivers/at_wini/at_wini.h @@ -2,7 +2,7 @@ #include "../libdriver/driver.h" #include "../libdriver/drvlib.h" -_PROTOTYPE(int main, (void)); +_PROTOTYPE(int main, (int argc, char *argv[])); #define VERBOSE 0 /* display identify messages during boot */ #define ENABLE_ATAPI 1 /* add ATAPI cd-rom support to driver */ diff --git a/drivers/memory/ramdisk/rc b/drivers/memory/ramdisk/rc index 094b52918..e4e781634 100644 --- a/drivers/memory/ramdisk/rc +++ b/drivers/memory/ramdisk/rc @@ -8,7 +8,7 @@ then /bin/service -c up /bin/bios_wini -dev /dev/c0d0 else /bin/service -c up /bin/at_wini -dev /dev/c0d0 -config /etc/drivers.conf -label at_wini_0 - /bin/service -c up /bin/at_wini -dev /dev/c1d0 -config /etc/drivers.conf -label at_wini_1 + /bin/service -c up /bin/at_wini -dev /dev/c1d0 -config /etc/drivers.conf -label at_wini_1 -args ata_instance=1 #/bin/service -c up /bin/at_wini -dev /dev/c0d0 -script /etc/rs.single -config /etc/drivers.conf fi