From: Randy Dunlap <randy.dunlap@oracle.com>
To: Fabio Comolli <fabio.comolli@gmail.com>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>,
x86@kernel.org, Suresh Siddha <suresh.b.siddha@intel.com>,
Yinghai Lu <yinghai@kernel.org>
Subject: [PATCH] dmar: use function stubs when CONFIG_INTR_REMAP is disabled
Date: Mon, 22 Nov 2010 12:48:34 -0800 [thread overview]
Message-ID: <20101122124834.74429004.randy.dunlap@oracle.com> (raw)
In-Reply-To: <AANLkTikKAO7TMhYgGU=ggWCTXbvABsgjhmQUPRQB35kL@mail.gmail.com>
From: Randy Dunlap <randy.dunlap@oracle.com>
The stubs for CONFIG_INTR_REMAP disabled need to be functions
instead of values to eliminate build warnings.
arch/x86/kernel/apic/apic.c: In function 'lapic_suspend':
arch/x86/kernel/apic/apic.c:2060:3: warning: statement with no effect
arch/x86/kernel/apic/apic.c: In function 'lapic_resume':
arch/x86/kernel/apic/apic.c:2137:3: warning: statement with no effect
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Reported-by: Fabio Comolli <fabio.comolli@gmail.com>
---
include/linux/dmar.h | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)
--- lnx-2637-rc3.orig/include/linux/dmar.h
+++ lnx-2637-rc3/include/linux/dmar.h
@@ -175,10 +175,21 @@ static inline int set_msi_sid(struct irt
return 0;
}
-#define enable_intr_remapping(mode) (-1)
-#define disable_intr_remapping() (0)
-#define reenable_intr_remapping(mode) (0)
#define intr_remapping_enabled (0)
+
+static inline int enable_intr_remapping(int eim)
+{
+ return -1;
+}
+
+static inline void disable_intr_remapping(void)
+{
+}
+
+static inline int reenable_intr_remapping(int eim)
+{
+ return 0;
+}
#endif
/* Can't use the common MSI interrupt functions
next prev parent reply other threads:[~2010-11-22 20:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-22 19:40 2.6.37-rc3 - io-apic.c and apic.c warnings Fabio Comolli
2010-11-22 20:48 ` Randy Dunlap [this message]
2010-11-22 21:36 ` [PATCH] dmar: use function stubs when CONFIG_INTR_REMAP is disabled Fabio Comolli
2010-11-26 10:31 ` [tip:x86/urgent] dmar, x86: Use " tip-bot for Randy Dunlap
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=20101122124834.74429004.randy.dunlap@oracle.com \
--to=randy.dunlap@oracle.com \
--cc=fabio.comolli@gmail.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=suresh.b.siddha@intel.com \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
--cc=yinghai@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®