lkml.org 
[lkml]   [2003]   [Jul]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 2.5.73] Signal stack fixes #1 introduce PF_SS_ACTIVE
From
Date
Linus Torvalds <torvalds@osdl.org> writes:

> On Fri, 4 Jul 2003, Jörn Engel wrote:
> >
> > So some application has it's signal handler on the signal stack and
> > instead of returning to the kernel, it detect where it left off before
> > the signal, mangles the last two stack frames, and goes back directly?
>
> Yeah, basically a lot of old threading stuff did the equivalent of
> longjump by hand.
>
> It is entirely possible that they do not do this out of signal handlers,
> since that has its own set of problems anyway, and one of the reasons for
> doing co-operative user level threading is to not need locking, and thus
> you never want to do any thread switching asynchronously (eg from a signal
> context).
>
> So I'm not saying that your patch will necessarily break stuff, I'm just
> pointing out that it was actually done the way it is done on purpose.

I would have to double check but I am pretty certain dosemu does
this when running dpmi applications. An alternative stack is setup
for signals so we get a stack we can control, and if we want to
return to dosemu instead of the dpmi application we must change the
stack we return to.

Eric
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:46    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site