Re: Suggestion: LKM should be able to add system call for itself



On Mon, 7 Jul 2008 08:12:00 -0400
"Jinkai Gao" <mickeygjk@xxxxxxxxx> wrote:

On Mon, Jul 7, 2008 at 3:01 AM, Arjan van de Ven
<arjan@xxxxxxxxxxxxx> wrote:
On Mon, 7 Jul 2008 01:09:30 -0400
"Jinkai Gao" <mickeygjk@xxxxxxxxx> wrote:

Above is to demonstrate that LKM is extension to kernel, and the
system calls should be able to extend as long as the kernel is
extending. So The LKM should be able to define its own user
interface by adding new system call for itself.

Since we promise a stable ABI to userspace, this is a bit of a
problem.

But... look today, we already have various system calls implemented
by modules. (example: sys_nfsservctl)
but to make it fully dynamic? Not a good idea... nobody would be
able to program to it.

Why? Using the interface we provide to add and delete system call (the
module can only unregister the system calls registered by itself), all
the existing system calls will be the same. It is just you can have
more system calls then you need, That shouldn't be a problem.

but when the kernel later adds new ones.. overlap.

Really.. it's not hard to do this. Look at nfs etc. You CAN do this,
just you need to reserve your system call number officially (and create
a manpage for it describing what it does)... and then it doesn't really
matter if it's module or vmlinux who provides it. Again.. nfs has
solved this.



--
If you want to reach me at my work email, use arjan@xxxxxxxxxxxxxxx
For development, discussion and tips for power savings,
visit http://www.lesswatts.org
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: [Q] giving priority to network interfaces?
    ... The second interface connects the Ultra to ... > NFS server is in kernel-space. ... In 5.8 NFS runs in the kernel in the SYS class at priority 60 (lowest ...
    (comp.unix.solaris)
  • Re: Warning/Oops report of the week of September 16th, 2008
    ... oldest entries in the list and as it happens for *every* print job, ... it's a warnign about the parport /proc interface. ... said he could perhaps send patches to extend it (yet leave the old name to ... kernel bug per se, or even anything that is fixable without changing ...
    (Linux-Kernel)
  • [BUG] panic 2.6.20-rc3 in nf_conntrack
    ... When I shut down my ppp0 interface the kernel ... This kernel had the ipp2p patch from patch-o-matic-ng applied, ... # Firmware Drivers ... # ACPI Support ...
    (Linux-Kernel)
  • [PATCH 3/3] Add documentation about why the in-kernel api is the way it is.
    ... +The Linux Kernel Driver Interface ... +kernel interface, nor does it have a stable kernel interface. ...
    (Linux-Kernel)
  • Re: [PATCH 0/7] dlm: overview
    ... > aren't just unique within a single cluster (think clusters of clusters, ... How the configuration gets from the config file to kernel is a mystery to me ... By a message over a socket, ... Let's have no magical filesystems in the core interface please. ...
    (Linux-Kernel)