Commit a5ff1b34 authored by Masahiro Yamada's avatar Masahiro Yamada Committed by Linus Torvalds

treewide: replace config_enabled() with IS_ENABLED() (2nd round)

Commit 97f2645f ("tree-wide: replace config_enabled() with
IS_ENABLED()") mostly killed config_enabled(), but some new users have
appeared for v4.8-rc1.  They are all used for a boolean option, so can
be replaced with IS_ENABLED() safely.

Link: http://lkml.kernel.org/r/1471970749-24867-1-git-send-email-yamada.masahiro@socionext.comSigned-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
Acked-by: default avatarKees Cook <keescook@chromium.org>
Acked-by: default avatarPeter Oberparleiter <oberpar@linux.vnet.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent ae6c33ba
...@@ -164,7 +164,7 @@ typedef struct { unsigned long pgprot; } pgprot_t; ...@@ -164,7 +164,7 @@ typedef struct { unsigned long pgprot; } pgprot_t;
*/ */
static inline unsigned long ___pa(unsigned long x) static inline unsigned long ___pa(unsigned long x)
{ {
if (config_enabled(CONFIG_64BIT)) { if (IS_ENABLED(CONFIG_64BIT)) {
/* /*
* For MIPS64 the virtual address may either be in one of * For MIPS64 the virtual address may either be in one of
* the compatibility segements ckseg0 or ckseg1, or it may * the compatibility segements ckseg0 or ckseg1, or it may
...@@ -173,7 +173,7 @@ static inline unsigned long ___pa(unsigned long x) ...@@ -173,7 +173,7 @@ static inline unsigned long ___pa(unsigned long x)
return x < CKSEG0 ? XPHYSADDR(x) : CPHYSADDR(x); return x < CKSEG0 ? XPHYSADDR(x) : CPHYSADDR(x);
} }
if (!config_enabled(CONFIG_EVA)) { if (!IS_ENABLED(CONFIG_EVA)) {
/* /*
* We're using the standard MIPS32 legacy memory map, ie. * We're using the standard MIPS32 legacy memory map, ie.
* the address x is going to be in kseg0 or kseg1. We can * the address x is going to be in kseg0 or kseg1. We can
......
...@@ -204,11 +204,9 @@ static void __init conmode_default(void) ...@@ -204,11 +204,9 @@ static void __init conmode_default(void)
#endif #endif
} }
} else if (MACHINE_IS_KVM) { } else if (MACHINE_IS_KVM) {
if (sclp.has_vt220 && if (sclp.has_vt220 && IS_ENABLED(CONFIG_SCLP_VT220_CONSOLE))
config_enabled(CONFIG_SCLP_VT220_CONSOLE))
SET_CONSOLE_VT220; SET_CONSOLE_VT220;
else if (sclp.has_linemode && else if (sclp.has_linemode && IS_ENABLED(CONFIG_SCLP_CONSOLE))
config_enabled(CONFIG_SCLP_CONSOLE))
SET_CONSOLE_SCLP; SET_CONSOLE_SCLP;
else else
SET_CONSOLE_HVC; SET_CONSOLE_HVC;
......
...@@ -77,7 +77,7 @@ static inline unsigned long get_padding(struct kaslr_memory_region *region) ...@@ -77,7 +77,7 @@ static inline unsigned long get_padding(struct kaslr_memory_region *region)
*/ */
static inline bool kaslr_memory_enabled(void) static inline bool kaslr_memory_enabled(void)
{ {
return kaslr_enabled() && !config_enabled(CONFIG_KASAN); return kaslr_enabled() && !IS_ENABLED(CONFIG_KASAN);
} }
/* Initialize base and padding for each memory region randomized with KASLR */ /* Initialize base and padding for each memory region randomized with KASLR */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment