public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86: make apic_* operations inline functions
@ 2008-12-16 20:33 Jeremy Fitzhardinge
  0 siblings, 0 replies; 2+ messages in thread
From: Jeremy Fitzhardinge @ 2008-12-16 20:33 UTC (permalink / raw)
  To: Ingo Molnar; +Cc: the arch/x86 maintainers, Linux Kernel Mailing List

Mainly to get proper type-checking and consistency.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
---
 arch/x86/include/asm/apic.h |   35 +++++++++++++++++++++++++++++------
 1 file changed, 29 insertions(+), 6 deletions(-)

===================================================================
--- a/arch/x86/include/asm/apic.h
+++ b/arch/x86/include/asm/apic.h
@@ -125,12 +125,35 @@
 
 extern struct apic_ops *apic_ops;
 
-#define apic_read (apic_ops->read)
-#define apic_write (apic_ops->write)
-#define apic_icr_read (apic_ops->icr_read)
-#define apic_icr_write (apic_ops->icr_write)
-#define apic_wait_icr_idle (apic_ops->wait_icr_idle)
-#define safe_apic_wait_icr_idle (apic_ops->safe_wait_icr_idle)
+static inline u32 apic_read(u32 reg)
+{
+	return apic_ops->read(reg);
+}
+
+static inline void apic_write(u32 reg, u32 val)
+{
+	apic_ops->write(reg, val);
+}
+
+static inline u64 apic_icr_read(void)
+{
+	return apic_ops->icr_read();
+}
+
+static inline void apic_icr_write(u32 low, u32 high)
+{
+	apic_ops->icr_write(low, high);
+}
+
+static inline void apic_wait_icr_idle(void)
+{
+	apic_ops->wait_icr_idle();
+}
+
+static inline u32 safe_apic_wait_icr_idle(void)
+{
+	return apic_ops->safe_wait_icr_idle();
+}
 
 extern int get_physical_broadcast(void);
 



^ permalink raw reply	[flat|nested] 2+ messages in thread
* [PATCH] *** SUBJECT HERE ***
@ 2009-02-10 20:00 Jeremy Fitzhardinge
  2009-02-09 20:05 ` [PATCH] x86: make apic_* operations inline functions Jeremy Fitzhardinge
  0 siblings, 1 reply; 2+ messages in thread
From: Jeremy Fitzhardinge @ 2009-02-10 20:00 UTC (permalink / raw)
  Cc: Ingo Molnar, x86, Linux Kernel Mailing List, Yinghai Lu

Hi all,

This series of patches (against tip/x86/apic) makes some fairly
uncontroversial changes and cleanups to lay the groundwork for some more
Xen-specific patches (which will no doubt cause more of a discussion).

These changes can also be pulled from
   git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen.git x86/apic

Thanks,
	J

Ian Campbell (1):
  xen: expose enable_IO_APIC for 32-bit

Jeremy Fitzhardinge (4):
  x86: make apic_* operations inline functions
  x86: unstatic mp_find_ioapic so it can be used elsewhere
  x86: add mp_find_ioapic_pin
  x86: unstatic ioapic entry funcs

 arch/x86/include/asm/apic.h    |   35 +++++++++++++++++++++++++++++------
 arch/x86/include/asm/hw_irq.h  |    2 --
 arch/x86/include/asm/io_apic.h |    6 ++++++
 arch/x86/include/asm/mpspec.h  |    2 ++
 arch/x86/kernel/acpi/boot.c    |   18 ++++++++++++++----
 arch/x86/kernel/io_apic.c      |   10 +++++-----
 6 files changed, 56 insertions(+), 17 deletions(-)


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-02-10 20:07 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-12-16 20:33 [PATCH] x86: make apic_* operations inline functions Jeremy Fitzhardinge
  -- strict thread matches above, loose matches on Subject: below --
2009-02-10 20:00 [PATCH] *** SUBJECT HERE *** Jeremy Fitzhardinge
2009-02-09 20:05 ` [PATCH] x86: make apic_* operations inline functions Jeremy Fitzhardinge

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox