Commit 972b4a74 authored by Matthew Wilcox's avatar Matthew Wilcox Committed by Linus Torvalds

[PATCH] Move EISA_bus

When I change the setting of CONFIG_EISA, everything rebuilds.  This is
because EISA_bus is declared in <asm/processor.h> which is implicitly
included by just about everything.  This is a silly place to declare it,
so this patch moves it to include/linux/eisa.h.

While I'm at it, I also move the variable definition to
drivers/eisa/eisa-bus.c.  The rest of this patch is fixing up the fallout
from having to include <linux/eisa.h> if you use EISA_bus.
parent 87a6ea5a
...@@ -484,6 +484,9 @@ config EISA ...@@ -484,6 +484,9 @@ config EISA
Otherwise, say N. Otherwise, say N.
config EISA_ALWAYS
def_bool EISA
config SMP config SMP
bool "Symmetric multi-processing support" bool "Symmetric multi-processing support"
depends on ALPHA_SABLE || ALPHA_LYNX || ALPHA_RAWHIDE || ALPHA_DP264 || ALPHA_WILDFIRE || ALPHA_TITAN || ALPHA_GENERIC || ALPHA_SHARK || ALPHA_MARVEL depends on ALPHA_SABLE || ALPHA_LYNX || ALPHA_RAWHIDE || ALPHA_DP264 || ALPHA_WILDFIRE || ALPHA_TITAN || ALPHA_GENERIC || ALPHA_SHARK || ALPHA_MARVEL
......
...@@ -63,9 +63,6 @@ extern unsigned long get_cmos_time(void); ...@@ -63,9 +63,6 @@ extern unsigned long get_cmos_time(void);
/* platform dependent support */ /* platform dependent support */
EXPORT_SYMBOL(boot_cpu_data); EXPORT_SYMBOL(boot_cpu_data);
#ifdef CONFIG_EISA
EXPORT_SYMBOL(EISA_bus);
#endif
EXPORT_SYMBOL(MCA_bus); EXPORT_SYMBOL(MCA_bus);
#ifdef CONFIG_DISCONTIGMEM #ifdef CONFIG_DISCONTIGMEM
EXPORT_SYMBOL(node_data); EXPORT_SYMBOL(node_data);
......
...@@ -28,6 +28,7 @@ ...@@ -28,6 +28,7 @@
#ifdef CONFIG_EISA #ifdef CONFIG_EISA
#include <linux/ioport.h> #include <linux/ioport.h>
#include <linux/eisa.h>
#endif #endif
#ifdef CONFIG_MCA #ifdef CONFIG_MCA
...@@ -832,10 +833,6 @@ static void __init set_task_gate(unsigned int n, unsigned int gdt_entry) ...@@ -832,10 +833,6 @@ static void __init set_task_gate(unsigned int n, unsigned int gdt_entry)
} }
#ifdef CONFIG_EISA
int EISA_bus;
#endif
void __init trap_init(void) void __init trap_init(void)
{ {
#ifdef CONFIG_EISA #ifdef CONFIG_EISA
......
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
* Copyright (C) 2001 MIPS Technologies, Inc. * Copyright (C) 2001 MIPS Technologies, Inc.
*/ */
#include <linux/config.h> #include <linux/config.h>
#include <linux/eisa.h>
#include <linux/hdreg.h> #include <linux/hdreg.h>
#include <linux/init.h> #include <linux/init.h>
#include <linux/ioport.h> #include <linux/ioport.h>
......
...@@ -43,10 +43,6 @@ extern long __strnlen_user_asm(const char *s); ...@@ -43,10 +43,6 @@ extern long __strnlen_user_asm(const char *s);
EXPORT_SYMBOL(mips_machtype); EXPORT_SYMBOL(mips_machtype);
#ifdef CONFIG_EISA
EXPORT_SYMBOL(EISA_bus);
#endif
/* /*
* String functions * String functions
*/ */
......
...@@ -44,15 +44,6 @@ struct cpuinfo_mips cpu_data[NR_CPUS]; ...@@ -44,15 +44,6 @@ struct cpuinfo_mips cpu_data[NR_CPUS];
struct screen_info screen_info; struct screen_info screen_info;
#endif #endif
/*
* Set if box has EISA slots.
*/
#ifdef CONFIG_EISA
int EISA_bus;
EXPORT_SYMBOL(EISA_bus);
#endif
#if defined(CONFIG_BLK_DEV_FD) || defined(CONFIG_BLK_DEV_FD_MODULE) #if defined(CONFIG_BLK_DEV_FD) || defined(CONFIG_BLK_DEV_FD_MODULE)
extern struct fd_ops no_fd_ops; extern struct fd_ops no_fd_ops;
struct fd_ops *fd_ops; struct fd_ops *fd_ops;
......
...@@ -20,6 +20,7 @@ ...@@ -20,6 +20,7 @@
*/ */
#include <linux/config.h> #include <linux/config.h>
#include <linux/eisa.h>
#include <linux/types.h> #include <linux/types.h>
#include <linux/init.h> #include <linux/init.h>
#include <linux/irq.h> #include <linux/irq.h>
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
* Copyright (C) 1996, 1997, 1998, 2000, 2003 by Ralf Baechle * Copyright (C) 1996, 1997, 1998, 2000, 2003 by Ralf Baechle
*/ */
#include <linux/config.h> #include <linux/config.h>
#include <linux/eisa.h>
#include <linux/hdreg.h> #include <linux/hdreg.h>
#include <linux/ioport.h> #include <linux/ioport.h>
#include <linux/sched.h> #include <linux/sched.h>
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
*/ */
#include <linux/bitops.h> #include <linux/bitops.h>
#include <linux/config.h> #include <linux/config.h>
#include <asm/pdc.h> #include <linux/eisa.h>
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/init.h> #include <linux/init.h>
#include <linux/signal.h> #include <linux/signal.h>
...@@ -39,6 +39,7 @@ ...@@ -39,6 +39,7 @@
#include <linux/spinlock.h> #include <linux/spinlock.h>
#include <asm/cache.h> #include <asm/cache.h>
#include <asm/pdc.h>
#undef DEBUG_IRQ #undef DEBUG_IRQ
#undef PARISC_IRQ_CR16_COUNTS #undef PARISC_IRQ_CR16_COUNTS
......
...@@ -42,9 +42,6 @@ EXPORT_SYMBOL(probe_irq_mask); ...@@ -42,9 +42,6 @@ EXPORT_SYMBOL(probe_irq_mask);
#include <asm/processor.h> #include <asm/processor.h>
EXPORT_SYMBOL(kernel_thread); EXPORT_SYMBOL(kernel_thread);
EXPORT_SYMBOL(boot_cpu_data); EXPORT_SYMBOL(boot_cpu_data);
#ifdef CONFIG_EISA
EXPORT_SYMBOL(EISA_bus);
#endif
#include <linux/pm.h> #include <linux/pm.h>
EXPORT_SYMBOL(pm_power_off); EXPORT_SYMBOL(pm_power_off);
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
* Copyright (C) 1999-2001 Grant Grundler * Copyright (C) 1999-2001 Grant Grundler
*/ */
#include <linux/config.h> #include <linux/config.h>
#include <linux/eisa.h>
#include <linux/init.h> #include <linux/init.h>
#include <linux/module.h> #include <linux/module.h>
#include <linux/kernel.h> #include <linux/kernel.h>
......
...@@ -52,10 +52,6 @@ char command_line[COMMAND_LINE_SIZE]; ...@@ -52,10 +52,6 @@ char command_line[COMMAND_LINE_SIZE];
struct proc_dir_entry * proc_runway_root = NULL; struct proc_dir_entry * proc_runway_root = NULL;
struct proc_dir_entry * proc_gsc_root = NULL; struct proc_dir_entry * proc_gsc_root = NULL;
#ifdef CONFIG_EISA
int EISA_bus; /* This has to go somewhere in architecture specific code. */
#endif
void __init setup_cmdline(char **cmdline_p) void __init setup_cmdline(char **cmdline_p)
{ {
extern unsigned int boot_args[]; extern unsigned int boot_args[];
......
...@@ -427,6 +427,11 @@ module_param(disable_dev, intarray, 0444); ...@@ -427,6 +427,11 @@ module_param(disable_dev, intarray, 0444);
postcore_initcall (eisa_init); postcore_initcall (eisa_init);
#ifndef CONFIG_EISA_ALWAYS
int EISA_bus;
EXPORT_SYMBOL(EISA_bus);
#endif
EXPORT_SYMBOL (eisa_bus_type); EXPORT_SYMBOL (eisa_bus_type);
EXPORT_SYMBOL (eisa_driver_register); EXPORT_SYMBOL (eisa_driver_register);
EXPORT_SYMBOL (eisa_driver_unregister); EXPORT_SYMBOL (eisa_driver_unregister);
...@@ -25,6 +25,7 @@ static const char version[] = ...@@ -25,6 +25,7 @@ static const char version[] =
"ac3200.c:v1.01 7/1/94 Donald Becker (becker@cesdis.gsfc.nasa.gov)\n"; "ac3200.c:v1.01 7/1/94 Donald Becker (becker@cesdis.gsfc.nasa.gov)\n";
#include <linux/module.h> #include <linux/module.h>
#include <linux/eisa.h>
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/string.h> #include <linux/string.h>
......
...@@ -84,6 +84,7 @@ ...@@ -84,6 +84,7 @@
*/ */
#include <linux/module.h> #include <linux/module.h>
#include <linux/eisa.h>
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/string.h> #include <linux/string.h>
#include <linux/delay.h> #include <linux/delay.h>
......
...@@ -49,6 +49,7 @@ static const char version[] = ...@@ -49,6 +49,7 @@ static const char version[] =
"es3210.c: Driver revision v0.03, 14/09/96\n"; "es3210.c: Driver revision v0.03, 14/09/96\n";
#include <linux/module.h> #include <linux/module.h>
#include <linux/eisa.h>
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/string.h> #include <linux/string.h>
......
...@@ -104,6 +104,7 @@ ...@@ -104,6 +104,7 @@
#include <linux/ioport.h> #include <linux/ioport.h>
#include <linux/slab.h> #include <linux/slab.h>
#include <linux/interrupt.h> #include <linux/interrupt.h>
#include <linux/eisa.h>
#include <linux/pci.h> #include <linux/pci.h>
#include <linux/spinlock.h> #include <linux/spinlock.h>
#include <linux/netdevice.h> #include <linux/netdevice.h>
......
...@@ -35,6 +35,7 @@ static const char *version = ...@@ -35,6 +35,7 @@ static const char *version =
"lne390.c: Driver revision v0.99.1, 01/09/2000\n"; "lne390.c: Driver revision v0.99.1, 01/09/2000\n";
#include <linux/module.h> #include <linux/module.h>
#include <linux/eisa.h>
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/string.h> #include <linux/string.h>
......
...@@ -29,6 +29,7 @@ static const char *version = ...@@ -29,6 +29,7 @@ static const char *version =
"ne3210.c: Driver revision v0.03, 30/09/98\n"; "ne3210.c: Driver revision v0.03, 30/09/98\n";
#include <linux/module.h> #include <linux/module.h>
#include <linux/eisa.h>
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/string.h> #include <linux/string.h>
......
...@@ -47,6 +47,7 @@ static const char *version = "smc-ultra32.c: 06/97 v1.00\n"; ...@@ -47,6 +47,7 @@ static const char *version = "smc-ultra32.c: 06/97 v1.00\n";
#include <linux/module.h> #include <linux/module.h>
#include <linux/eisa.h>
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/string.h> #include <linux/string.h>
......
...@@ -169,6 +169,7 @@ ...@@ -169,6 +169,7 @@
#include <linux/module.h> #include <linux/module.h>
#include <linux/init.h> #include <linux/init.h>
#include <linux/ioport.h> #include <linux/ioport.h>
#include <linux/eisa.h>
#include <linux/pci.h> #include <linux/pci.h>
#include <linux/netdevice.h> #include <linux/netdevice.h>
#include <linux/etherdevice.h> #include <linux/etherdevice.h>
......
...@@ -29,7 +29,6 @@ ...@@ -29,7 +29,6 @@
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 1
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#ifdef __KERNEL__ #ifdef __KERNEL__
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro #define MCA_bus__is_a_macro
......
...@@ -20,7 +20,6 @@ ...@@ -20,7 +20,6 @@
#ifdef __KERNEL__ #ifdef __KERNEL__
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro #define MCA_bus__is_a_macro
......
...@@ -48,7 +48,6 @@ extern inline void wrusp(unsigned long usp) { ...@@ -48,7 +48,6 @@ extern inline void wrusp(unsigned long usp) {
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
struct thread_struct { struct thread_struct {
......
...@@ -260,11 +260,6 @@ static inline void clear_in_cr4 (unsigned long mask) ...@@ -260,11 +260,6 @@ static inline void clear_in_cr4 (unsigned long mask)
* Bus types (default is ISA, but people can check others with these..) * Bus types (default is ISA, but people can check others with these..)
* pc98 indicates PC98 systems (CBUS) * pc98 indicates PC98 systems (CBUS)
*/ */
#ifdef CONFIG_EISA
extern int EISA_bus;
#else
#define EISA_bus (0)
#endif
extern int MCA_bus; extern int MCA_bus;
#ifdef CONFIG_X86_PC9800 #ifdef CONFIG_X86_PC9800
#define pc98 1 #define pc98 1
......
...@@ -56,7 +56,6 @@ ...@@ -56,7 +56,6 @@
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -56,7 +56,6 @@ extern inline void wrusp(unsigned long usp) { ...@@ -56,7 +56,6 @@ extern inline void wrusp(unsigned long usp) {
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
struct task_work { struct task_work {
......
...@@ -58,7 +58,6 @@ extern inline void wrusp(unsigned long usp) ...@@ -58,7 +58,6 @@ extern inline void wrusp(unsigned long usp)
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
/* /*
......
...@@ -135,12 +135,6 @@ extern unsigned int vced_count, vcei_count; ...@@ -135,12 +135,6 @@ extern unsigned int vced_count, vcei_count;
/* /*
* Bus types (default is ISA, but people can check others with these..) * Bus types (default is ISA, but people can check others with these..)
*/ */
#ifdef CONFIG_EISA
extern int EISA_bus;
#else
#define EISA_bus (0)
#endif
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -101,12 +101,6 @@ extern struct cpuinfo_parisc cpu_data[NR_CPUS]; ...@@ -101,12 +101,6 @@ extern struct cpuinfo_parisc cpu_data[NR_CPUS];
#define CPU_HVERSION ((boot_cpu_data.hversion >> 4) & 0x0FFF) #define CPU_HVERSION ((boot_cpu_data.hversion >> 4) & 0x0FFF)
#ifdef CONFIG_EISA
extern int EISA_bus;
#else
#define EISA_bus 0
#endif
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -803,7 +803,6 @@ extern long kernel_thread(int (*fn)(void *), void *arg, unsigned long flags); ...@@ -803,7 +803,6 @@ extern long kernel_thread(int (*fn)(void *), void *arg, unsigned long flags);
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro #define MCA_bus__is_a_macro
......
...@@ -612,8 +612,6 @@ extern long kernel_thread(int (*fn)(void *), void *arg, unsigned long flags); ...@@ -612,8 +612,6 @@ extern long kernel_thread(int (*fn)(void *), void *arg, unsigned long flags);
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define EISA_bus__is_a_macro /* for versions in ksyms.c */
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -169,8 +169,6 @@ extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags); ...@@ -169,8 +169,6 @@ extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags);
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define EISA_bus__is_a_macro /* for versions in ksyms.c */
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -27,7 +27,6 @@ ...@@ -27,7 +27,6 @@
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -22,7 +22,6 @@ ...@@ -22,7 +22,6 @@
#include <asm/page.h> #include <asm/page.h>
/* Bus types */ /* Bus types */
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -52,8 +52,6 @@ ...@@ -52,8 +52,6 @@
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define EISA_bus__is_a_macro /* for versions in ksyms.c */
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */ #define MCA_bus__is_a_macro /* for versions in ksyms.c */
......
...@@ -160,7 +160,6 @@ static inline void clear_in_cr4 (unsigned long mask) ...@@ -160,7 +160,6 @@ static inline void clear_in_cr4 (unsigned long mask)
/* /*
* Bus types * Bus types
*/ */
#define EISA_bus 0
#define MCA_bus 0 #define MCA_bus 0
#define MCA_bus__is_a_macro #define MCA_bus__is_a_macro
......
#ifndef _LINUX_EISA_H #ifndef _LINUX_EISA_H
#define _LINUX_EISA_H #define _LINUX_EISA_H
#include <linux/ioport.h>
#include <linux/device.h>
#ifdef CONFIG_EISA
# ifdef CONFIG_EISA_ALWAYS
# define EISA_bus 1
# else
extern int EISA_bus;
# endif
#else
# define EISA_bus 0
#endif
#define EISA_SIG_LEN 8 #define EISA_SIG_LEN 8
#define EISA_MAX_SLOTS 8 #define EISA_MAX_SLOTS 8
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment