lkml.org 
[lkml]   [2010]   [Feb]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [tip:x86/apic] x86: Fix out of order gsi -- add remap_ioapic_gsi_to_irq()
On 02/27/2010 05:01 AM, Ingo Molnar wrote:
> arch/x86/kernel/apic/io_apic.c:1042: error: implicit declaration of function ?remap_ioapic_gsi_to_irq?
>
please check

[PATCH] x86: fix warning with remap_ioapic_gsi_to_irq when !CONFIG_ACPI

Ingo found:
| x86: Fix out of order gsi -- add remap_ioapic_gsi_to_irq()
cause:
arch/x86/kernel/apic/io_apic.c:1042: error: implicit declaration of function ?remap_ioapic_gsi_to_irq?

actually when !CONFIG_ACPI, we have
#define acpi_ioapic 0

somehow we still get warning for
#if (!0) {
...
} else {
...
remap_ioapic_gsi_to_irq...
}

gcc bug?

Signed-off-by: Yinghai Lu <yinghai@kernel.org>

---
arch/x86/include/asm/mpspec.h | 8 ++++++++
1 file changed, 8 insertions(+)

Index: linux-2.6/arch/x86/include/asm/mpspec.h
===================================================================
--- linux-2.6.orig/arch/x86/include/asm/mpspec.h
+++ linux-2.6/arch/x86/include/asm/mpspec.h
@@ -116,6 +116,14 @@ static inline int acpi_probe_gsi(void)
{
return 0;
}
+static inline int remap_ioapic_gsi_to_irq(int ioapic, u32 gsi)
+{
+ return gsi;
+}
+static inline int remap_ioapic_irq_to_gsi(int irq)
+{
+ return irq;
+}
#endif /* CONFIG_ACPI */

#define PHYSID_ARRAY_SIZE BITS_TO_LONGS(MAX_APICS)

\
 
 \ /
  Last update: 2010-02-27 19:57    [W:0.233 / U:0.684 seconds]
©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site