Re: [PATCH] compatibility syscall layer (lets try again)

From: Martin Schwidefsky (
Date: Mon Dec 09 2002 - 12:56:30 EST

> Well, that is tricky independently of the actual argument stuff - even
> _current_ system call restart ends up being tricky for you in that case,
> suspect. The current one already basically depends on rewriting the
> call number, it just leaves the arguments untouched.

The current system call restart doesn't change the system call number. We just
substract two from the psw address (aka eip) and go back to user space.

> One thing you could do (which is pretty much architecture-independent) is
> to have a "restart" flag in the thread info structure. The system call
> entry code-path already has to check the thread info structure for things
> like the "ptrace" flags, so it shouldn't add much overhead to the system
> call entrypoint.

Hmm, probably the best thing to do. I though about changing the return address
in the last frame of the stack but this is ugly and confuses the code. Another
flag in thread_info (_TIF_RESTART?) doesn't add any instruction on the hot
path in the system call handler and is simple enough to implement.

blue skies,

Linux/390 Design & Development, IBM Deutschland Entwicklung GmbH
Schönaicherstr. 220, D-71032 Böblingen, Telefon: 49 - (0)7031 - 16-2247

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Sun Dec 15 2002 - 22:00:15 EST