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 for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Wed,  4 Mar 2015 17:24:10 -0800
From:	"Luis R. Rodriguez" <mcgrof@...not-panic.com>
To:	gregkh@...uxfoundation.org, akpm@...ux-foundation.org,
	tony@...mide.com, tglx@...utronix.de, mingo@...hat.com,
	hpa@...or.com, jgross@...e.com, luto@...capital.net,
	toshi.kani@...com, dave.hansen@...ux.intel.com, JBeulich@...e.com,
	pavel@....cz, qiuxishi@...wei.com, david.vrabel@...rix.com,
	bp@...e.de, vbabka@...e.cz, iamjoonsoo.kim@....com,
	decui@...rosoft.com
Cc:	linux-kernel@...r.kernel.org, x86@...nel.org, julia.lawall@...6.fr,
	"Luis R. Rodriguez" <mcgrof@...e.com>
Subject: [RFC v1 0/4] x86: simpify direct_gbpages setting, add early_param_on_off()

From: "Luis R. Rodriguez" <mcgrof@...e.com>

While reviewing DIRECT_GBPAGES I noticed some inconsistancies
on when its cached "enable" variable is set and when in reality
its full feature is enabled. There's also some code simplification
possible by simply using Kconfig, so decided to take advantage of
that and then generalize this a bit under a new early_param_on_off()
which makes it easier to associate featureas with respective cached
values and their own feature related Kconfig entries.

In this case in order to use early_param_on_off() given that init.o is
shared with both 32-bit and 64-bit and before the early parameters were
only exposed on 64-bit it does mean we're exposing this kernel
parameter to 32-bit as well now but its not possible to enable it on 32-bit
as its real setting is guarded by ENABLE_DIRECT_GBPAGES.

I was tempted to grep around for this sort of grammar use but couldn't
easily find all uses with Coccinelle / grep due to the #ifder'y
and the code being outside of routines. If the generalization is not
desired we can drop the last two, but would ask that the first two patches
to be considered and reviewed.

Luis R. Rodriguez (4):
  x86: mm: use IS_ENABLED() for direct_gbpages
  x86: mm: simplify enabling direct_gbpages
  init.h: add early_param_on_off()
  x86: mm: use early_param_on_off() for direct_gbpages

 arch/x86/Kconfig       | 18 +++++++++++++-----
 arch/x86/mm/init.c     | 24 +++++++++++-------------
 arch/x86/mm/init_64.c  | 14 --------------
 arch/x86/mm/pageattr.c |  2 --
 include/linux/init.h   | 15 +++++++++++++++
 5 files changed, 39 insertions(+), 34 deletions(-)

-- 
2.2.2

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