This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] PPC64 Add ucontext.h and *context functions


Paul Mackerras writes:

> All we need is the setcontext syscall number assigned, then current
> kernels will give us an ENOSYS and we go do things exactly as in your
> patch.  I was trying to say that the whole point of the rt_sigreturn
> hack is to cope with older kernels (including current kernels :)
> and that doing it in a way which is incompatible with older kernels
> therefore makes no sense.

I eagerly await the number. When we know which kernel version implements
NR_setcontext, I'll add __ASSUME_SETCONTEXT_SYSCALL to kernel_features.h
and avoid the ENOSYS.

> I think a getcontext syscall is a good idea, although I don't know
> what userspace needs to know the MSR value for.  The FE0/1 bits can be
> obtained through the prctl syscall in 2.5 (at least for ppc32) and
> that will hopefully go into 2.4 shortly (/me pokes himself to submit
> the patch to Marcelo).

If the user can change the FEx bits but we reset them on the next
get/setcontext that's a bug. I would like to avoid multiple syscalls to
obtain what a single getcontext syscall can. The getcontext/setcontext pair
is functionally complete. And I need them in a 2.4.xx kernel.



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]