The type of the field ucontext::uc_sigmask isn't k_rtsigset_t
if the struct ucontext is imported from system headers
rather than provided by an architecture-specific header.
Signed-off-by: Alexander Kartashov <alekskartashov@parallels.com>
Cc: Andrey Vagin <avagin@openvz.org>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
An fpu_state_t instance shouldn't be stored in an ARM sigframe
that makes it necessary to generalize the way the FPU state is
accessed in the routine construct_sigframe()
Signed-off-by: Alexander Kartashov <alekskartashov@parallels.com>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
To restore SAS we have two ways:
- call for sigaltstack explicitly in restorer.c right before we call for sigreturn
- pass stack value to sigreturn call and allow the kernel to restore stack for us
Since second way is a simplier one -- we stick with it.
[alekskartashov@: use RT_SIGFRAME_UC]
Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
CC: Alexander Kartashov <alekskartashov@parallels.com>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
A struct sigframe* instead of fpu_state_t should be passed
to the routine restore_fpu() since FPU registers are stored
in different fields of the sigframe in different architectures.
An architecture-specific implementation of the routine restore_fpu()
should know details of this layout instead of construct_sigframe().
This change makes it possible to move ARM FPU restoration
from sigreturn_prep_fpu_frame() (where it caused a segfault
since the pointer fpu_stat has become invalid in the dumper
address space) to restore_fpu()
Signed-off-by: Alexander Kartashov <alekskartashov@parallels.com>
Acked-by: Andrey Vagin <avagin@openvz.org>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
The names of these functions should be swapped to avoid confusion.
Signed-off-by: Alexander Kartashov <alekskartashov@parallels.com>
Acked-by: Andrey Vagin <avagin@openvz.org>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
Before this patch sigframes were constructed in restorer. We are going
to construct sigframes for parasites. Both parasite and restorer should
be as thing as posible.
Signed-off-by: Andrey Vagin <avagin@openvz.org>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>