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]
Date:	Tue, 22 Jul 2008 17:33:36 +0200
From:	Ingo Molnar <mingo@...e.hu>
To:	Johannes Weiner <hannes@...urebad.de>
Cc:	Jeremy Fitzhardinge <jeremy@...p.org>,
	Rusty Russell <rusty@...tcorp.com.au>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] x86: rename PTE_MASK to PTE_PFN_MASK


* Johannes Weiner <hannes@...urebad.de> wrote:

> Johannes Weiner <hannes@...urebad.de> writes:
> 
> > Hi,
> >
> > Jeremy Fitzhardinge <jeremy@...p.org> writes:
> >
> >> Johannes Weiner wrote:
> >>> PTE_PFN_MASK is not symmetric to PAGE_MASK.
> >>
> >> No, it isn't.  Is there anything about the name that suggests that it
> >> should be?  PTE_PFN_MASK is for operating on pteval_t-typed values
> >> extracted from ptes; PAGE_MASK is for operating on addresses.
> >
> > I meant the naming scheme, not the functionality.
> >
> > The thing PAGE_MASK and PTE_MASK have in common is that they are masks
> > and their names indicate what is masked away when applied.
> >
> > So PAGE_MASK suggests that it masks out page details.  And PTE_MASK
> > suggests that it masks out PTE details.
> >
> > PTE_PFN_MASK masks suggests that it masks out the flags, according 
> > to the existing naming convention.  But it does the opposite.
> 
> As you explained me how PAGE_MASK was meant, scratch the above ;)

btw., feel free to send a patch that adds more comments that makes it 
obvious at first sight if someone takes a look at the defines.

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