Re: [patch] Assigning syscall numbers for testing

Alan Cox
2001-12-24T17:02:40Z

> Well, I'm not going to mess with code, but here's the example. Say you
> start at syscall 240 for dynamic registration. Someone then submits a patch

The number you start at depends on the kernel you run.

> modify the base of your patch, but if it has been accepted into any real
> kernels anywhere, then someone could inadvertently end up running a user
> space app compiled against Linus' new kernel and that uses the newly
> allocated syscalls 240 and 241. If that's run on an older kernel with your

The code on execution will read the syscall numbers from procfs. It will
find new numbers and call those. Its a very simple implementation of lazy
binding. It only breaks if you actually run out of syscalls, and then it
fails safe.

Alan