From: Dou Liyang <douly.fnst@cn.fujitsu.com>
To: <x86@kernel.org>, <linux-kernel@vger.kernel.org>
Cc: <tglx@linutronix.de>, <mingo@kernel.org>, <hpa@zytor.com>,
<jaswinder@infradead.org>, Dou Liyang <douly.fnst@cn.fujitsu.com>
Subject: [PATCH 2/2] x86/smp: Remove the redundant #ifdef CONFIG_SMP directive
Date: Sun, 9 Apr 2017 18:46:46 +0800 [thread overview]
Message-ID: <1491734806-15413-2-git-send-email-douly.fnst@cn.fujitsu.com> (raw)
In-Reply-To: <1491734806-15413-1-git-send-email-douly.fnst@cn.fujitsu.com>
According to:
...
config X86_LOCAL_APIC
def_bool y
depends on X86_64 || SMP || X86_32_NON_STANDARD ...
...
in arch/x86/Kconfig
If X86_LOCAL_APIC is n, the SMP must be n.
So, Remove the redundant #ifdef CONFIG_SMP directive in the case of
!X86_LOCAL_APIC.
Signed-off-by: Dou Liyang <douly.fnst@cn.fujitsu.com>
---
arch/x86/include/asm/smp.h | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/arch/x86/include/asm/smp.h b/arch/x86/include/asm/smp.h
index f64aaa7..47103ec 100644
--- a/arch/x86/include/asm/smp.h
+++ b/arch/x86/include/asm/smp.h
@@ -188,11 +188,7 @@ static inline int logical_smp_processor_id(void)
extern int hard_smp_processor_id(void);
#else /* CONFIG_X86_LOCAL_APIC */
-
-# ifndef CONFIG_SMP
-# define hard_smp_processor_id() 0
-# endif
-
+#define hard_smp_processor_id() 0
#endif /* CONFIG_X86_LOCAL_APIC */
#ifdef CONFIG_DEBUG_NMI_SELFTEST
--
2.5.5
next prev parent reply other threads:[~2017-04-09 10:47 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-09 10:46 [PATCH 1/2] x86/smp: Refine the code in the case of X86_32_SMP Dou Liyang
2017-04-09 10:46 ` Dou Liyang [this message]
2017-04-14 20:46 ` [tip:x86/cleanups] x86/smp: Remove the redundant #ifdef CONFIG_SMP directive tip-bot for Dou Liyang
2017-04-10 8:05 ` [PATCH 3/3] x86/irq: Remove a redundant #ifdef directive Dou Liyang
2017-04-14 20:46 ` [tip:x86/cleanups] " tip-bot for Dou Liyang
2017-04-14 20:45 ` [tip:x86/cleanups] x86/smp: Reduce code duplication tip-bot for Dou Liyang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1491734806-15413-2-git-send-email-douly.fnst@cn.fujitsu.com \
--to=douly.fnst@cn.fujitsu.com \
--cc=hpa@zytor.com \
--cc=jaswinder@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®