Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 2 Oct 2002 04:23:57 +1000 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        Jake Burkholder <jake@locore.ca>
Cc:        Daniel Eischen <eischen@pcnet1.pcnet.com>, Peter Wemm <peter@wemm.org>, <current@FreeBSD.ORG>
Subject:   Re: Longer term fix for sigreturn ABI breaking
Message-ID:  <20021002034827.S2440-100000@gamplex.bde.org>
In-Reply-To: <20021001112510.G218@locore.ca>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 1 Oct 2002, Jake Burkholder wrote:

> Apparently, On Tue, Oct 01, 2002 at 11:12:02AM -0400,
> 	Daniel Eischen said words to the effect of;
>
> > On Mon, 30 Sep 2002, Peter Wemm wrote:
> > > Longer term, I was thining that we could/should do what sparc64 does, ie:
> > > libc provides the trampoline and it can then call the correct sigreturn
> > > syscall.  That means we add a new sigreturn syscall each time we
> > > significantly break the sigreturn ABI (as in this case) and applications
> > > will be able to use the correct one.  Paired with a new sigaction syscall
> > > which would specify the "new" context format we can then be future proof.
> >
> > Sounds good.  If we added a new sigaction and sigreturn now, we can
> > still do the same thing, without having the trampoline in libc.
> > I thought the point of having the trampoline in libc would prevent
> > having to create new syscalls...
>
> The point is that the signal trampoline automatically uses the new or
> old system calls because its linked with libc.  Otherwise you need
> a different signal trampoline in the kernel for each version of sigreturn,
> and some way to determine the right one.  The 0x01ds16 hack only works
> for so long.

Actually, for the "Otherwise" case you need a different signal trampoline
in the kernel for each version of sendsig(), and this is not much
harder than having different versions of sendsig() and sigreturn().
The 0x01d516 hack never really worked.  It was essentially just to
recover from foot-shooting (not putting SYS_osigreturn in syscalls.h
so that the old signal trampoline can use it just like an old library
version would (except it would be named SYS_sigreturn in old versions
of syscalls.h)).  I removed the hack on i386's.

Bruce


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021002034827.S2440-100000>