[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100208065425.GB1290@ucw.cz>
Date: Mon, 8 Feb 2010 07:54:25 +0100
From: Pavel Machek <pavel@....cz>
To: "H. Peter Anvin" <hpa@...or.com>
Cc: rostedt@...dmis.org,
Linus Torvalds <torvalds@...ux-foundation.org>,
Peter Zijlstra <peterz@...radead.org>,
Tom Tromey <tromey@...hat.com>,
Kyle Moffett <kyle@...fetthome.net>,
"Frank Ch. Eigler" <fche@...hat.com>,
Oleg Nesterov <oleg@...hat.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Stephen Rothwell <sfr@...b.auug.org.au>,
Fr??d??ric Weisbecker <fweisbec@...il.com>,
LKML <linux-kernel@...r.kernel.org>,
Arnaldo Carvalho de Melo <acme@...hat.com>,
linux-next@...r.kernel.org, utrace-devel@...hat.com,
Thomas Gleixner <tglx@...utronix.de>,
JimKeniston <jkenisto@...ibm.com>,
Arjan van de Ven <arjan@...radead.org>
Subject: Re: linux-next: add utrace tree
Hi!
> >>> Right, so you're going to love uprobes, which does exactly that. The
> >>> current proposal is overwriting the target instruction with an INT3 and
> >>> injecting an extra vma into the target process's address space
> >>> containing the original instruction(s) and possible jumps back to the
> >>> old code stream.
> >>
> >> Just out of interest, how does it handle the threading issue?
> >>
> >> Last I saw, at least some CPU people were _very_ nervous about overwriting
> >> instructions if another CPU might be just about to execute them.
> >
> > I think the issue was that ring 0 was never meant to do that, where as,
> > ring 3 does it all the time. Doesn't the dynamic library modify its
> > text?
>
> No, it has nothing to do with ring. It has to do with modifying code
> that another CPU could be executing at the same time, and with modifying
> code on the same processor through another virtual alias (they are
> different issues.) The same issues apply regardless of the CPL of the
> processor.
...but these are always 'there could be cpu bugs around' issues,
right? Like amd k6. AFAICT x86 always supported self-modifying code
without any extra barriers needed...
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists