RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Joe Buck
On Wed, 5 Mar 2008, Jan Hubicka wrote: > > Linux kernel is disabling red zone and use kernel code model, yet the > > ABI is not going to be adjusted for that. > > > > This is resonably easy to fix on kernel side in signal handling, or by > > removing std usage completely On Wed, Mar 05, 2008 a

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Richard Guenther
On Wed, Mar 5, 2008 at 10:20 PM, Joe Buck <[EMAIL PROTECTED]> wrote: > > > On Wed, 5 Mar 2008, Jan Hubicka wrote: > > > Linux kernel is disabling red zone and use kernel code model, yet the > > > ABI is not going to be adjusted for that. > > > > > > This is resonably easy to fix on kernel side

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread H. Peter Anvin
Richard Guenther wrote: We didn't yet run into this issue and build openSUSE with 4.3 since more than three month. Well, how often do you take a trap inside an overlapping memmove()? -hpa

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Richard Guenther
On Wed, Mar 5, 2008 at 10:34 PM, H. Peter Anvin <[EMAIL PROTECTED]> wrote: > Richard Guenther wrote: > > > > We didn't yet run into this issue and build openSUSE with 4.3 since more > than > > three month. > > > > Well, how often do you take a trap inside an overlapping memmove()? Right. So

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Joe Buck
On Wed, Mar 05, 2008 at 01:34:14PM -0800, H. Peter Anvin wrote: > Richard Guenther wrote: > > > >We didn't yet run into this issue and build openSUSE with 4.3 since more > >than > >three month. > > > > Well, how often do you take a trap inside an overlapping memmove()? Also, would it be possible

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Andrew Pinski
There are already gcc 4.3.0 packages on the FTP site. Sent from my iPhone On Mar 5, 2008, at 13:20, Joe Buck <[EMAIL PROTECTED]> wrote: On Wed, 5 Mar 2008, Jan Hubicka wrote: Linux kernel is disabling red zone and use kernel code model, yet the ABI is not going to be adjusted for that. T

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Michael Matz
Hi, On Wed, 5 Mar 2008, Joe Buck wrote: > > > On Wed, 5 Mar 2008, Jan Hubicka wrote: > > > Linux kernel is disabling red zone and use kernel code model, yet the > > > ABI is not going to be adjusted for that. > > > > > > This is resonably easy to fix on kernel side in signal handling, or by >

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Richard Guenther
On Wed, Mar 5, 2008 at 10:43 PM, Joe Buck <[EMAIL PROTECTED]> wrote: > > On Wed, Mar 05, 2008 at 01:34:14PM -0800, H. Peter Anvin wrote: > > Richard Guenther wrote: > > > > > >We didn't yet run into this issue and build openSUSE with 4.3 since more > > >than > > >three month. > > > > > > >

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Aurelien Jarno
Richard Guenther a écrit : > On Wed, Mar 5, 2008 at 10:20 PM, Joe Buck <[EMAIL PROTECTED]> wrote: >> >> On Wed, 5 Mar 2008, Jan Hubicka wrote: >> > > Linux kernel is disabling red zone and use kernel code model, yet the >> > > ABI is not going to be adjusted for that. >> > > >> > > This is res

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Chris Lattner
On Mar 5, 2008, at 1:34 PM, H. Peter Anvin wrote: Richard Guenther wrote: We didn't yet run into this issue and build openSUSE with 4.3 since more than three month. Well, how often do you take a trap inside an overlapping memmove()? How hard is it to change the kernel signal entry path f

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Michael Matz
Hi, On Wed, 5 Mar 2008, Chris Lattner wrote: > > On Mar 5, 2008, at 1:34 PM, H. Peter Anvin wrote: > > >Richard Guenther wrote: > > >We didn't yet run into this issue and build openSUSE with 4.3 since more > > >than > > >three month. > > > >Well, how often do you take a trap inside an overlappi

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread H. Peter Anvin
Chris Lattner wrote: On Mar 5, 2008, at 1:34 PM, H. Peter Anvin wrote: Richard Guenther wrote: We didn't yet run into this issue and build openSUSE with 4.3 since more than three month. Well, how often do you take a trap inside an overlapping memmove()? How hard is it to change the kerne

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Joe Buck
On Wed, Mar 05, 2008 at 10:43:33PM +0100, Michael Matz wrote: > Hi, > > On Wed, 5 Mar 2008, Joe Buck wrote: > > > > > > > On Wed, 5 Mar 2008, Jan Hubicka wrote: > > > > Linux kernel is disabling red zone and use kernel code model, yet the > > > > ABI is not going to be adjusted for that. > > >

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Adrian Bunk
On Wed, Mar 05, 2008 at 10:59:21PM +0100, Michael Matz wrote: > Hi, > > On Wed, 5 Mar 2008, Chris Lattner wrote: > > > > > On Mar 5, 2008, at 1:34 PM, H. Peter Anvin wrote: > > > > >Richard Guenther wrote: > > > >We didn't yet run into this issue and build openSUSE with 4.3 since more > > > >th

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread David Miller
From: "Richard Guenther" <[EMAIL PROTECTED]> Date: Wed, 5 Mar 2008 22:40:59 +0100 > Right. So this problem is over-exaggerated. It's not like > "any binary you create on that system will be broken on any > other existing system." I will be sure to hunt you down to help debug when someone report

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread David Miller
From: Michael Matz <[EMAIL PROTECTED]> Date: Wed, 5 Mar 2008 22:43:33 +0100 (CET) > The error is arcane and happens seldomly if at all. And only on > unfixed kernels. Which translates right now into "all kernels."

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread David Miller
From: Adrian Bunk <[EMAIL PROTECTED]> Date: Thu, 6 Mar 2008 00:13:04 +0200 > On Wed, Mar 05, 2008 at 10:59:21PM +0100, Michael Matz wrote: > > The problem is with old kernels, which by definition stay unfixed. > > Compiling older kernels with new gcc versions has never been supported. Adrian we'

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Joe Buck
On Wed, Mar 05, 2008 at 02:16:22PM -0800, David Miller wrote: > From: "Richard Guenther" <[EMAIL PROTECTED]> > Date: Wed, 5 Mar 2008 22:40:59 +0100 > > > Right. So this problem is over-exaggerated. It's not like > > "any binary you create on that system will be broken on any > > other existing s

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Michael Matz
Hi, On Wed, 5 Mar 2008, David Miller wrote: > I will be sure to hunt you down to help debug when someone reports that > once every few weeks their multi-day simulation gives incorrect results > :-) Give them a LD_PRELOADable DSO that intercepts signal() and sig_action(), installing a trampoli

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread H. Peter Anvin
Michael Matz wrote: Many bugs are a big issue to people who actually hit them, and we had (and probably still have) far nastier corner case miscompilations here and there and nevertheless released. It never was the end of the world :) This is the sort of stuff that security holes are made

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Michael Matz
Hi, On Wed, 5 Mar 2008, H. Peter Anvin wrote: > Michael Matz wrote: > > > > Many bugs are a big issue to people who actually hit them, and we had (and > > probably still have) far nastier corner case miscompilations here and there > > and nevertheless released. It never was the end of the world

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread David Miller
From: Michael Matz <[EMAIL PROTECTED]> Date: Thu, 6 Mar 2008 00:07:39 +0100 (CET) > The fix lies in the kernel, the work-around in gcc. This depends upon how you interpret this ABI situation. There is at least some agreement that how things have actually been implemented by these kernels for mor

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Olivier Galibert
On Thu, Mar 06, 2008 at 12:07:39AM +0100, Michael Matz wrote: > For security problems I prefer fixes over work-arounds. The fix lies in > the kernel, the work-around in gcc. Incorrect. The bugs are in the ABI documentation and in gcc, and the fixes should be done there. Doing it in the kernel

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Olivier Galibert
On Thu, Mar 06, 2008 at 12:13:04AM +0200, Adrian Bunk wrote: > Compiling older kernels with new gcc versions has never been supported. You read the thread too fast. It's not at all about compiling the kernel. OG.

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Joe Buck
On Wed, Mar 05, 2008 at 03:10:12PM -0800, David Miller wrote: > From: Michael Matz <[EMAIL PROTECTED]> > Date: Thu, 6 Mar 2008 00:07:39 +0100 (CET) > > > The fix lies in the kernel, the work-around in gcc. > > This depends upon how you interpret this ABI situation. > > There is at least some agr

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Olivier Galibert
On Wed, Mar 05, 2008 at 10:43:33PM +0100, Michael Matz wrote: > FWIW I don't think it's a release blocker for 4.3.0. The error is arcane > and happens seldomly if at all. And only on unfixed kernels. A program > needs to do std explicitely, which most don't do _and_ get hit by a signal > whil

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread David Daney
Olivier Galibert wrote: On Wed, Mar 05, 2008 at 10:43:33PM +0100, Michael Matz wrote: FWIW I don't think it's a release blocker for 4.3.0. The error is arcane and happens seldomly if at all. And only on unfixed kernels. A program needs to do std explicitely, which most don't do _and_ get hit

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Chris Lattner
Richard Guenther wrote: We didn't yet run into this issue and build openSUSE with 4.3 since more than three month. Well, how often do you take a trap inside an overlapping memmove()? How hard is it to change the kernel signal entry path from "pushf" to "pushf;cld"? Problem solved, no? Th

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Aurelien Jarno
Chris Lattner a écrit : Richard Guenther wrote: > We didn't yet run into this issue and build openSUSE with 4.3 since > more > than > three month. Well, how often do you take a trap inside an overlapping memmove()? >>> >>> How hard is it to change the kernel signal en

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread H. Peter Anvin
Chris Lattner wrote: Richard Guenther wrote: We didn't yet run into this issue and build openSUSE with 4.3 since more than three month. Well, how often do you take a trap inside an overlapping memmove()? How hard is it to change the kernel signal entry path from "pushf" to "pushf;cld"? Pro

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Chris Lattner
On Mar 5, 2008, at 4:47 PM, H. Peter Anvin wrote: Chris Lattner wrote: Richard Guenther wrote: We didn't yet run into this issue and build openSUSE with 4.3 since more than three month. Well, how often do you take a trap inside an overlapping memmove()? How hard is it to change the ke

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread H. Peter Anvin
Chris Lattner wrote: Upon return to userspace, the modified state kicks in. Thus the signal handler is entered with DF from userspace at trap time, not DF=0. So it's an asynchronous state leak from one piece of userspace to another. Fine, it can happen either way. In either case, the dis

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-05 Thread Krzysztof Halasa
"H. Peter Anvin" <[EMAIL PROTECTED]> writes: > Not quite, but fixing it in the kernel is easy. > > Still breaks for running on all old kernels. Many more things break on old kernels. I guess it's not worse than a (local) root exploit, is it? *-stable and distributions should take care of it, as

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Andi Kleen
"H. Peter Anvin" <[EMAIL PROTECTED]> writes: > Richard Guenther wrote: > > We didn't yet run into this issue and build openSUSE with 4.3 since > > more than > > three month. > > > > Well, how often do you take a trap inside an overlapping memmove()? That was the state with older gcc, but with ne

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Jakub Jelinek
On Thu, Mar 06, 2008 at 09:44:05AM +0100, Andi Kleen wrote: > "H. Peter Anvin" <[EMAIL PROTECTED]> writes: > > > Richard Guenther wrote: > > > We didn't yet run into this issue and build openSUSE with 4.3 since > > > more than > > > three month. > > > > > > > Well, how often do you take a trap in

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Jakub Jelinek
On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: > It's a kernel bug, and it needs to be fixed. The discussion is about > what to do in the meantime. While it is known that 32-bit glibc memmove and also inlines for memmove and memrchr use std; some string op; cld;, 64-bit glibc d

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Olivier Galibert
On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: > It's a kernel bug, and it needs to be fixed. I'm not convinced. It's been that way for 15 years, it's that way in the BSD kernels, at that point it's a feature. The bug is in the documentation, nowhere else. And in gcc for blindl

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Andrew Haley
Olivier Galibert wrote: > On Thu, Mar 06, 2008 at 03:03:15PM +0100, Paolo Bonzini wrote: >> Olivier Galibert wrote: >>> On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: It's a kernel bug, and it needs to be fixed. >>> I'm not convinced. It's been that way for 15 years, it's tha

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Paolo Bonzini
Olivier Galibert wrote: On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: It's a kernel bug, and it needs to be fixed. I'm not convinced. It's been that way for 15 years, it's that way in the BSD kernels, at that point it's a feature. The bug is in the documentation, nowhere el

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Olivier Galibert
On Thu, Mar 06, 2008 at 03:03:15PM +0100, Paolo Bonzini wrote: > Olivier Galibert wrote: > >On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: > >>It's a kernel bug, and it needs to be fixed. > > > >I'm not convinced. It's been that way for 15 years, it's that way in > >the BSD kernel

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Olivier Galibert
On Wed, Mar 05, 2008 at 03:21:43PM -0800, David Daney wrote: > Olivier Galibert wrote: > >On Wed, Mar 05, 2008 at 10:43:33PM +0100, Michael Matz wrote: > >>FWIW I don't think it's a release blocker for 4.3.0. The error is arcane > >>and happens seldomly if at all. And only on unfixed kernels. A

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Robert Dewar
Olivier Galibert wrote: On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: It's a kernel bug, and it needs to be fixed. I'm not convinced. It's been that way for 15 years, it's that way in the BSD kernels, at that point it's a feature. The bug is in the documentation, nowhere el

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H. Peter Anvin
Jakub Jelinek wrote: On Thu, Mar 06, 2008 at 09:44:05AM +0100, Andi Kleen wrote: "H. Peter Anvin" <[EMAIL PROTECTED]> writes: Richard Guenther wrote: We didn't yet run into this issue and build openSUSE with 4.3 since more than three month. Well, how often do you take a trap inside an overl

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread NightStrike
On 3/6/08, Olivier Galibert <[EMAIL PROTECTED]> wrote: > On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: > > It's a kernel bug, and it needs to be fixed. > > I'm not convinced. It's been that way for 15 years, it's that way in > the BSD kernels, at that point it's a feature. The b

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H.J. Lu
I agree with it. There is no right or wrong here Let's start from scratch and figure out what is the best way to handle this, assuming we are defining a new psABI. H.J. On Thu, Mar 6, 2008 at 7:37 AM, NightStrike <[EMAIL PROTECTED]> wrote: > > On 3/6/08, Olivier Galibert <[EMAIL PROTECTED]> wrote

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H. Peter Anvin
H.J. Lu wrote: I agree with it. There is no right or wrong here Let's start from scratch and figure out what is the best way to handle this, assuming we are defining a new psABI. No, I believe the right way to approach this is by applying the good old-fashioned principle from Ask Mr. Protocol

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Robert Dewar
NightStrike wrote: On 3/6/08, Olivier Galibert <[EMAIL PROTECTED]> wrote: On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: It's a kernel bug, and it needs to be fixed. I'm not convinced. It's been that way for 15 years, it's that way in the BSD kernels, at that point it's a fea

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Artur Skawina
Olivier Galibert wrote: > On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: >> It's a kernel bug, and it needs to be fixed. > > I'm not convinced. It's been that way for 15 years, it's that way in > the BSD kernels, at that point it's a feature. The bug is in the > documentation, n

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Jakub Jelinek
On Thu, Mar 06, 2008 at 07:50:12AM -0800, H. Peter Anvin wrote: > H.J. Lu wrote: > >I agree with it. There is no right or wrong here Let's start from > >scratch and figure out > >what is the best way to handle this, assuming we are defining a new psABI. BTW, just tested icc and icc doesn't genera

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread İsmail Dönmez
Hi, On Thu, Mar 6, 2008 at 6:23 PM, Jakub Jelinek <[EMAIL PROTECTED]> wrote: > On Thu, Mar 06, 2008 at 07:50:12AM -0800, H. Peter Anvin wrote: > > H.J. Lu wrote: > > >I agree with it. There is no right or wrong here Let's start from > > >scratch and figure out > > >what is the best way to han

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Paolo Bonzini
Another story, the sad story of the intel chip (I think it was the 80188) where Intel made use of Int 5, which was documented as reserved. Unfortunately, Microsoft/IBM had used this for print screen or some such. Intel was absolutely right that their documentation was clear and it was wrong to h

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H.J. Lu
On Thu, Mar 6, 2008 at 8:23 AM, Jakub Jelinek <[EMAIL PROTECTED]> wrote: > On Thu, Mar 06, 2008 at 07:50:12AM -0800, H. Peter Anvin wrote: > > H.J. Lu wrote: > > >I agree with it. There is no right or wrong here Let's start from > > >scratch and figure out > > >what is the best way to handle t

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H. Peter Anvin
H.J. Lu wrote: On Thu, Mar 6, 2008 at 8:23 AM, Jakub Jelinek <[EMAIL PROTECTED]> wrote: On Thu, Mar 06, 2008 at 07:50:12AM -0800, H. Peter Anvin wrote: > H.J. Lu wrote: > >I agree with it. There is no right or wrong here Let's start from > >scratch and figure out > >what is the best way to

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H.J. Lu
On Thu, Mar 6, 2008 at 9:06 AM, H. Peter Anvin <[EMAIL PROTECTED]> wrote: > > H.J. Lu wrote: > > On Thu, Mar 6, 2008 at 8:23 AM, Jakub Jelinek <[EMAIL PROTECTED]> wrote: > >> On Thu, Mar 06, 2008 at 07:50:12AM -0800, H. Peter Anvin wrote: > >> > H.J. Lu wrote: > >> > >I agree with it. There i

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Robert Dewar
H.J. Lu wrote: So that is the bug in the Linux kernel. Since fixing kernel is much easier than providing a workaround in compilers, I think kernel should be fixed and no need for icc/gcc fix. Fixing a bug in the Linux kernel is not "much easier". You are taking a purely engineering viewpoint,

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H. Peter Anvin
Robert Dewar wrote: H.J. Lu wrote: So that is the bug in the Linux kernel. Since fixing kernel is much easier than providing a workaround in compilers, I think kernel should be fixed and no need for icc/gcc fix. Fixing a bug in the Linux kernel is not "much easier". You are taking a purely e

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H. Peter Anvin
H.J. Lu wrote: Not a fix, an (optional) workaround for a system bug. So that is the bug in the Linux kernel. Since fixing kernel is much easier than providing a workaround in compilers, I think kernel should be fixed and no need for icc/gcc fix. The problem is, you're going to have to be a

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H.J. Lu
On Thu, Mar 6, 2008 at 9:17 AM, H. Peter Anvin <[EMAIL PROTECTED]> wrote: > H.J. Lu wrote: > >> > >> Not a fix, an (optional) workaround for a system bug. > > > > So that is the bug in the Linux kernel. Since fixing kernel is much easier > > than providing a workaround in compilers, I think k

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H. Peter Anvin
Robert Dewar wrote: Sounds good, but has almost nothing to do with the real world. I remember back in Realia COBOL days, we had to carefully copy IBM bugs in the IBM mainframe COBOL compiler. Doing things right and fixing the bug would have been the right thing to do, but no one would have use

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Joe Buck
On Thu, Mar 06, 2008 at 03:12:21PM +0100, Olivier Galibert wrote: > On Thu, Mar 06, 2008 at 03:03:15PM +0100, Paolo Bonzini wrote: > > Olivier Galibert wrote: > > >On Wed, Mar 05, 2008 at 05:12:07PM -0800, H. Peter Anvin wrote: > > >>It's a kernel bug, and it needs to be fixed. > > > > > >I'm not c

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Olivier Galibert
On Thu, Mar 06, 2008 at 09:58:41AM -0800, Joe Buck wrote: > If the kernel allows state to leak from one process to another, > for example from a process running as root to a process running as an > ordinary user, it's a bug, with possible security implications. I don't think that it is relevant in

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Paolo Bonzini
Olivier Galibert wrote: On Thu, Mar 06, 2008 at 09:58:41AM -0800, Joe Buck wrote: If the kernel allows state to leak from one process to another, for example from a process running as root to a process running as an ordinary user, it's a bug, with possible security implications. I don't think

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Jack Lloyd
On Thu, Mar 06, 2008 at 07:13:20PM +0100, Paolo Bonzini wrote: > A process can send a signal via kill. IOW, a malicious process can > *control when the process would be interrupted* in order to get it into > the signal handler with DF=1. If the malicious process can send a signal to another pro

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Andrew Pinski
On 3/6/08, Jack Lloyd <[EMAIL PROTECTED]> wrote: > On Thu, Mar 06, 2008 at 07:13:20PM +0100, Paolo Bonzini wrote: > > A process can send a signal via kill. IOW, a malicious process can > > *control when the process would be interrupted* in order to get it into > > the signal handler with DF=1.

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Robert Dewar
H. Peter Anvin wrote: Robert Dewar wrote: H.J. Lu wrote: So that is the bug in the Linux kernel. Since fixing kernel is much easier than providing a workaround in compilers, I think kernel should be fixed and no need for icc/gcc fix. Fixing a bug in the Linux kernel is not "much easier". You

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Robert Dewar
H.J. Lu wrote: Icc has been following psABI for years on Linux and it doesn't stop people using icc on Linux. On the other hand, it may be a good idea to provide a workaround in gcc and enables it by default. OSVs can fix thekernel and disable it by default. How widely is icc used? I ask bec

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Paolo Bonzini
Jack Lloyd wrote: On Thu, Mar 06, 2008 at 07:13:20PM +0100, Paolo Bonzini wrote: A process can send a signal via kill. IOW, a malicious process can *control when the process would be interrupted* in order to get it into the signal handler with DF=1. If the malicious process can send a signal

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Paolo Bonzini
If the malicious process can send a signal to another process, it could also ptrace() it. Which is more useful, if you wanted to be malicious? And more to the point, it can happen before GCC 4.3.0. Yes, and that's why the kernel should just fix it, and the fix should be backported and trea

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Jack Lloyd
On Thu, Mar 06, 2008 at 08:43:27PM +0100, Paolo Bonzini wrote: > Jack Lloyd wrote: > >On Thu, Mar 06, 2008 at 07:13:20PM +0100, Paolo Bonzini wrote: > >>A process can send a signal via kill. IOW, a malicious process can > >>*control when the process would be interrupted* in order to get it into

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread H. Peter Anvin
Robert Dewar wrote: Not really, it's just a matter of time. Typical distro cycles are on the order of 3 years. -hpa again, in the real world, there are MANY projects that are nothing like this interactive when it comes to moving to new versions of operating systems. This is true, but

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-06 Thread Artur Skawina
Jack Lloyd wrote: > But still: so the threat here is of a malicious process with the > ability to send arbitrary signals to any process using CAP_KILL (since > in any other case when a process can send a signal, it can do much > more damage in other ways), which could leverage that into > (potentia

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-07 Thread Andreas Jaeger
"H. Peter Anvin" <[EMAIL PROTECTED]> writes: > Robert Dewar wrote: >> H.J. Lu wrote: >> >>> So that is the bug in the Linux kernel. Since fixing kernel is much >>> easier >>> than providing a workaround in compilers, I think kernel should be fixed >>> and no need for icc/gcc fix. >> >> Fixing a bu

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-07 Thread Florian Weimer
* Robert Dewar: > again, in the real world, there are MANY projects that are nothing > like this interactive when it comes to moving to new versions of > operating systems. Sure, but how many of those get to see software compiled with GCC 4.3? If this has any real impact, it's more likely to sho

Re: RELEASE BLOCKER: Linux doesn't follow x86/x86-64 ABI wrt direction flag

2008-03-08 Thread Alexandre Oliva
On Mar 6, 2008, Olivier Galibert <[EMAIL PROTECTED]> wrote: > It's extremely rare, no doubt about it. It's just that it *yells* > security issue in the making. It's not a source bug, i.e. not easily > reviewable. It's related to signal handlers which are the mark of a > server and/or more fail