On Mon, Feb 1, 2016 at 10:16 AM, Stas Sergeev <stsp@xxxxxxx> wrote:Whatever was saved there by save_altstack_ex() I guess.
01.02.2016 21:04, Oleg Nesterov ÐÐÑÐÑ:More detail please. What context are you returning to with
Yes, and SS_FORCE means "I know what I do", looks very simple.But to me its not because I don't know what to do with
uc_stack after SS_FORCE is applied.
I won't argue, but to me it would be better to keep this EPERM if !force.Ok then. Lets implement SS_FORCE.
Just because we should avoid the incompatible changes if possible.
What semantic should it have wrt uc_stack?
sigaltstack(SS_DISABLE | SS_FORCE);
swapcontext();
sigaltstack(set up new_sas);
rt_sigreturn();
What's at the end? Do we want a surprise for the user
that he's new_sas got ignored?
rt_sigreturn? What's in uc_stack?
Presumably we should continue to honor uc_stack in rt_sigreturn.In this case, the above sigaltstack(set up new_sas) just
I'mThis is obscure and is likely outside of the scope of the
less clear on whether we should have an implicit SS_FORCE when
restoring uc_stack.
I'm also not clear on why uc_stack exists in theHow would you then evaluate oss->ss_flags?
first place.
If I were designing this from scratch, I'd have signal delivery for an
SA_ONSTACK signal save away the altstack information and clear it so
that nested signals work without checking sp during signal delivery.