Various updates to support dynamically starting drivers.
This commit is contained in:
parent
120e514506
commit
1d60e866c3
5 changed files with 15 additions and 10 deletions
|
@ -18,6 +18,7 @@ OBJECTS = \
|
|||
$(LIBRARY)(_svrctl.o) \
|
||||
$(LIBRARY)(_getsysinfo.o) \
|
||||
$(LIBRARY)(_getprocnr.o) \
|
||||
$(LIBRARY)(_devctl.o) \
|
||||
$(LIBRARY)(_findproc.o) \
|
||||
$(LIBRARY)(asynchio.o) \
|
||||
$(LIBRARY)(configfile.o) \
|
||||
|
@ -90,6 +91,9 @@ $(LIBRARY)(_seekdir.o): _seekdir.c
|
|||
$(LIBRARY)(_svrctl.o): _svrctl.c
|
||||
$(CC1) _svrctl.c
|
||||
|
||||
$(LIBRARY)(_devctl.o): _devctl.c
|
||||
$(CC1) _devctl.c
|
||||
|
||||
$(LIBRARY)(_getprocnr.o): _getprocnr.c
|
||||
$(CC1) _getprocnr.c
|
||||
|
||||
|
|
|
@ -11,7 +11,8 @@ int *proc_nr; /* return process number here */
|
|||
message m;
|
||||
|
||||
m.m1_p1 = proc_name;
|
||||
m.m1_i1 = strlen(proc_name) + 1;
|
||||
m.m1_i1 = -1; /* search by name */
|
||||
m.m1_i2 = strlen(proc_name) + 1;
|
||||
if (_syscall(MM, GETPROCNR, &m) < 0) return(-1);
|
||||
*proc_nr = m.m1_i1;
|
||||
return(0);
|
||||
|
|
|
@ -3,13 +3,12 @@
|
|||
#include <unistd.h>
|
||||
|
||||
|
||||
PUBLIC int getprocnr(proc_nr)
|
||||
int *proc_nr; /* return process number here */
|
||||
PUBLIC int getprocnr()
|
||||
{
|
||||
message m;
|
||||
m.m1_i1 = 0; /* tell PM to get own process nr */
|
||||
m.m1_i1 = -1; /* get own process number */
|
||||
m.m1_i2 = 0; /* get own process number */
|
||||
if (_syscall(MM, GETPROCNR, &m) < 0) return(-1);
|
||||
*proc_nr = m.m1_i1;
|
||||
return(0);
|
||||
return(m.m1_i1);
|
||||
}
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@ OBJECTS = \
|
|||
$(LIBRARY)(close.o) \
|
||||
$(LIBRARY)(closedir.o) \
|
||||
$(LIBRARY)(creat.o) \
|
||||
$(LIBRARY)(devctl.o) \
|
||||
$(LIBRARY)(dup.o) \
|
||||
$(LIBRARY)(dup2.o) \
|
||||
$(LIBRARY)(execl.o) \
|
||||
|
@ -162,6 +163,9 @@ $(LIBRARY)(closedir.o): closedir.s
|
|||
$(LIBRARY)(creat.o): creat.s
|
||||
$(CC1) creat.s
|
||||
|
||||
$(LIBRARY)(devctl.o): devctl.s
|
||||
$(CC1) devctl.s
|
||||
|
||||
$(LIBRARY)(dup.o): dup.s
|
||||
$(CC1) dup.s
|
||||
|
||||
|
|
|
@ -11,13 +11,10 @@ PROGRAMS= ../kernel/kernel \
|
|||
../servers/pm/pm \
|
||||
../servers/fs/fs \
|
||||
../servers/sm/sm \
|
||||
../servers/is/is \
|
||||
../drivers/tty/tty \
|
||||
../drivers/memory/memory \
|
||||
../drivers/at_wini/at_wini \
|
||||
../drivers/rtl8139/rtl8139 \
|
||||
../drivers/fxp/fxp \
|
||||
../drivers/log/log \
|
||||
../drivers/at_wini/at_wini \
|
||||
../drivers/bios_wini/bios_wini \
|
||||
../servers/init/init \
|
||||
# bootdev.img
|
||||
|
|
Loading…
Reference in a new issue