diff options
author | Luis R. Rodriguez <mcgrof@suse.com> | 2015-03-04 20:24:14 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2015-03-05 02:02:12 -0500 |
commit | 73c8c861dc5bddf1b24c6aeffee2292c96cf8db2 (patch) | |
tree | 02b025a9eb2d32d59c739657c79853b6fbe6c7eb | |
parent | bfb33bad83f650f265ed65cbfe8352b7c3ce8c76 (diff) |
x86/mm: Use early_param_on_off() for direct_gbpages
The enabler / disabler is pretty simple, just use the
provided wrappers, this lets us easily relate the variable
to the associated Kconfig entry.
Signed-off-by: Luis R. Rodriguez <mcgrof@suse.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Andy Lutomirski <luto@amacapital.net>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Borislav Petkov <bp@suse.de>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: David Vrabel <david.vrabel@citrix.com>
Cc: Dexuan Cui <decui@microsoft.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: JBeulich@suse.com
Cc: Jan Beulich <JBeulich@suse.com>
Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Cc: Juergen Gross <jgross@suse.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Tony Lindgren <tony@atomide.com>
Cc: Toshi Kani <toshi.kani@hp.com>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Xishi Qiu <qiuxishi@huawei.com>
Cc: julia.lawall@lip6.fr
Link: http://lkml.kernel.org/r/1425518654-3403-5-git-send-email-mcgrof@do-not-panic.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
-rw-r--r-- | arch/x86/mm/init.c | 3 | ||||
-rw-r--r-- | arch/x86/mm/init_64.c | 14 |
2 files changed, 2 insertions, 15 deletions
diff --git a/arch/x86/mm/init.c b/arch/x86/mm/init.c index 2ce2c8e8c99c..c35ba8bce7cb 100644 --- a/arch/x86/mm/init.c +++ b/arch/x86/mm/init.c | |||
@@ -133,7 +133,8 @@ int after_bootmem; | |||
133 | 133 | ||
134 | static int page_size_mask; | 134 | static int page_size_mask; |
135 | 135 | ||
136 | int direct_gbpages = IS_ENABLED(CONFIG_DIRECT_GBPAGES); | 136 | early_param_on_off("gbpages", "nogbpages", |
137 | direct_gbpages, CONFIG_DIRECT_GBPAGES); | ||
137 | 138 | ||
138 | static void __init init_gbpages(void) | 139 | static void __init init_gbpages(void) |
139 | { | 140 | { |
diff --git a/arch/x86/mm/init_64.c b/arch/x86/mm/init_64.c index 30eb05ae7061..3fba623e3ba5 100644 --- a/arch/x86/mm/init_64.c +++ b/arch/x86/mm/init_64.c | |||
@@ -130,20 +130,6 @@ int kernel_ident_mapping_init(struct x86_mapping_info *info, pgd_t *pgd_page, | |||
130 | return 0; | 130 | return 0; |
131 | } | 131 | } |
132 | 132 | ||
133 | static int __init parse_direct_gbpages_off(char *arg) | ||
134 | { | ||
135 | direct_gbpages = 0; | ||
136 | return 0; | ||
137 | } | ||
138 | early_param("nogbpages", parse_direct_gbpages_off); | ||
139 | |||
140 | static int __init parse_direct_gbpages_on(char *arg) | ||
141 | { | ||
142 | direct_gbpages = 1; | ||
143 | return 0; | ||
144 | } | ||
145 | early_param("gbpages", parse_direct_gbpages_on); | ||
146 | |||
147 | /* | 133 | /* |
148 | * NOTE: pagetable_init alloc all the fixmap pagetables contiguous on the | 134 | * NOTE: pagetable_init alloc all the fixmap pagetables contiguous on the |
149 | * physical space so we can cache the place of the first one and move | 135 | * physical space so we can cache the place of the first one and move |