Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8e6dafd6 authored by Ingo Molnar's avatar Ingo Molnar
Browse files

x86: refactor x86_quirks support



Impact: cleanup

Make x86_quirks support more transparent. The highlevel
methods are now named:

  extern void x86_quirk_pre_intr_init(void);
  extern void x86_quirk_intr_init(void);

  extern void x86_quirk_trap_init(void);

  extern void x86_quirk_pre_time_init(void);
  extern void x86_quirk_time_init(void);

This makes it clear that if some platform extension has to
do something here that it is considered ... weird, and is
discouraged.

Also remove arch_hooks.h and move it into setup.h (and other
header files where appropriate).

Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent d85a881d
Loading
Loading
Loading
Loading

arch/x86/include/asm/arch_hooks.h

deleted100644 → 0
+0 −26
Original line number Diff line number Diff line
#ifndef _ASM_X86_ARCH_HOOKS_H
#define _ASM_X86_ARCH_HOOKS_H

#include <linux/interrupt.h>

/*
 *	linux/include/asm/arch_hooks.h
 *
 *	define the architecture specific hooks
 */

/* these aren't arch hooks, they are generic routines
 * that can be used by the hooks */
extern void init_ISA_irqs(void);
extern irqreturn_t timer_interrupt(int irq, void *dev_id);

/* these are the defined hooks */
extern void pre_intr_init_hook(void);
extern void intr_init_hook(void);

extern void trap_init_hook(void);

extern void pre_time_init_hook(void);
extern void time_init_hook(void);

#endif /* _ASM_X86_ARCH_HOOKS_H */
+4 −0
Original line number Diff line number Diff line
@@ -60,4 +60,8 @@ extern struct irq_chip i8259A_chip;
extern void mask_8259A(void);
extern void unmask_8259A(void);

#ifdef CONFIG_X86_32
extern void init_ISA_irqs(void);
#endif

#endif /* _ASM_X86_I8259_H */
+9 −0
Original line number Diff line number Diff line
@@ -13,6 +13,7 @@
struct mpc_cpu;
struct mpc_bus;
struct mpc_oemtable;

struct x86_quirks {
	int (*arch_pre_time_init)(void);
	int (*arch_time_init)(void);
@@ -33,6 +34,14 @@ struct x86_quirks {
	int (*update_apic)(void);
};

extern void x86_quirk_pre_intr_init(void);
extern void x86_quirk_intr_init(void);

extern void x86_quirk_trap_init(void);

extern void x86_quirk_pre_time_init(void);
extern void x86_quirk_time_init(void);

#endif /* __ASSEMBLY__ */

#ifdef __i386__
+2 −0
Original line number Diff line number Diff line
@@ -3,6 +3,7 @@
#include <linux/init.h>
#include <linux/pm.h>
#include <linux/percpu.h>
#include <linux/interrupt.h>

#define TICK_SIZE (tick_nsec / 1000)

@@ -12,6 +13,7 @@ unsigned long native_calibrate_tsc(void);
#ifdef CONFIG_X86_32
extern int timer_ack;
extern int recalibrate_cpu_khz(void);
extern irqreturn_t timer_interrupt(int irq, void *dev_id);
#endif /* CONFIG_X86_32 */

extern int no_timer_check;
+0 −1
Original line number Diff line number Diff line
@@ -34,7 +34,6 @@
#include <linux/smp.h>
#include <linux/mm.h>

#include <asm/arch_hooks.h>
#include <asm/pgalloc.h>
#include <asm/atomic.h>
#include <asm/mpspec.h>
Loading