lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64.0805061700390.13699@blonde.site>
Date:	Tue, 6 May 2008 17:12:31 +0100 (BST)
From:	Hugh Dickins <hugh@...itas.com>
To:	Jeremy Fitzhardinge <jeremy@...p.org>
cc:	Linus Torvalds <torvalds@...ux-foundation.org>,
	Ingo Molnar <mingo@...e.hu>,
	Jeff Chua <jeff.chua.linux@...il.com>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Thomas Gleixner <tglx@...utronix.de>,
	"H. Peter Anvin" <hpa@...or.com>,
	Gabriel C <nix.or.die@...glemail.com>
Subject: Re: Linux 2.6.26-rc1 - pgtable_32.c:178 pmd_bad

On Tue, 6 May 2008, Jeremy Fitzhardinge wrote:
> Linus Torvalds wrote:
> > You should have used a pagetable-specific macro, becuse PAGE_MASK is simply
> > fundamentally WRONG, and has absolutely nothing to do with the PFN bits,
> > whether sign-extended or not!
> >
> > The fact is, the page frane number bits are *not* ~PAGE_MASK or anything
> > like that. They share only the low bits - not the high bits.
> 
> Yes.  There's already a PTE_MASK for masking out the PFN vs the flags in a
> pte, but it isn't used consistently (perhaps at all).

My patch sidesteps this issue by simply restoring most things to how
they were in 2.6.25 (using PTE_MASK in x86_64 but PAGE_MASK in x86_32).
We've contentedly used PAGE_MASK there for many many years.

Seeing the PTE_MASK discussion I did briefly consider using PTE_MASK
at the x86_32 end (it would have the nice effect of testing for lots
of badly set bits it the upper PAE half?), but I wasn't sure it has
the right type at present (there seems to be a "long" type in there
which I'd have expected to need to be long long for PAE), and it was
all even more of a maze than the last time I looked.

I decided it's safer to go back to what we had before to fix the
current warning, together with the original point which got us
into this, and leave any PTE_MASK-ification to some other patch.

I've more to say on it when commenting the patch.

Hugh
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ