On Sun, 2007-01-07 at 00:15 -0800, Amit Choudhary wrote:
> 1. Invoke a system call using its name. Pass its name to the kernel as an argument of syscall() or
> some other function. Probably may make the invocation of the system call slower. If the name
> doesn't match in the kernel then an error can be returned.
>
> 2. Create a /proc entry that will return the number of the system call given its name. This number
> can then be used to invoke the system call.
Your argument has a built-in assumption that, whereas syscall numbers do
collide, syscall names will not. This assumption is not true; people
will quite often pick the same name for something independent of each
other.
Additionally, the proposed solutions will require a dramatic increase in
memory, to store a static string name for each syscall, and a marked
increase in CPU usage, to do string hashing and matching for each
syscall invocation (and these can occur very often). This overhead is
hard to justify just to support custom vendor kernels, as Rene pointed
out in a separate reply.
> These approaches will also remove the dependency from user space header file that contains the
> mapping from the system call name to its number. I hope that I made some sense.
I thought that this file was "shipped upwards" by the kernel already, as
a sanitized header?
-- Vadim Lobanov
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]