modload system call name
By timatworkhomeandinbetween on Dec 09, 2007
This weekend I've had to write a modloadable system call to read a cpu register that I can't read from userland on an amd64 box. Everything went well until I tried to modload the syscall module I'd built..
# modload /home/timu/src/syscalls/test1 can't load module Dec 9 21:27:22 aaaaa test1: REQUEST INFO : Out of memory or no room in system tables Dec 9 21:27:22 aaaaa test1: INITIALIZED Dec 9 21:27:22 aaaaa genunix: WARNING: system call missing from bind fileObvious I must have missed adding an entry to /etc/name_to_sysnum !
# grep timu /etc/name_to_sysnum timuSyscall 66oh! Its not that as I had used an unused number. ah! How does the system match the module name to the syscall number, there is nothing in the driver I have written to do that...It must be the name..
# cp test1 timuSyscall # modload /home/timu/src/syscalls/timuSyscall Dec 9 21:30:04 aaaaa timuSyscall: REQUEST INFO Dec 9 21:30:04 aaaaa timuSyscall: INITIALIZED #So the module name that you are modloading must match the name you put in /etc/name_to_sysnum.