Various updates to support dynamically starting drivers.

Output during initialization should be suppressed. Unless an error occurs.
Note that main() can now be main(int argc, char **argv) and arguments can
be passed when bringing up the driver.
This commit is contained in:
Jorrit Herder
2005-08-02 15:30:36 +00:00
parent f44725b777
commit 52965b6f17
14 changed files with 72 additions and 51 deletions

View File

@@ -135,19 +135,7 @@ int sig; /* signal number */
PUBLIC void main(void)
{
/* Main routine of the printer task. */
message pr_mess; /* buffer for all incoming messages */
#if DEAD_CODE
struct sigaction sigact;
/* Install signal handler.*/
sigact.sa_handler = signal_handler;
sigact.sa_mask = ~0; /* block all other signals */
sigact.sa_flags = 0; /* default behaviour */
printf("PRINTER calls sigaction()\n");
if (sigaction(SIGTERM, &sigact, NULL) != OK)
report("PRINTER","warning, sigaction() failed", errno);
#endif
while (TRUE) {
receive(ANY, &pr_mess);