Commit 1972ddad authored by Linus Torvalds's avatar Linus Torvalds

Merge bk://linux-voyager.bkbits.net/mca-2.6

into ppc970.osdl.org:/home/torvalds/v2.6/linux
parents 0812e18a d334942b
......@@ -61,7 +61,6 @@ extern unsigned long get_cmos_time(void);
/* platform dependent support */
EXPORT_SYMBOL(boot_cpu_data);
EXPORT_SYMBOL(MCA_bus);
#ifdef CONFIG_DISCONTIGMEM
EXPORT_SYMBOL(node_data);
EXPORT_SYMBOL(physnode_map);
......
......@@ -56,13 +56,16 @@
static unsigned char which_scsi = 0;
int MCA_bus = 0;
EXPORT_SYMBOL(MCA_bus);
/*
* Motherboard register spinlock. Untested on SMP at the moment, but
* are there any MCA SMP boxes?
*
* Yes - Alan
*/
spinlock_t mca_lock = SPIN_LOCK_UNLOCKED;
static spinlock_t mca_lock = SPIN_LOCK_UNLOCKED;
/* Build the status info for the adapter */
......@@ -119,7 +122,7 @@ static void mca_configure_adapter_status(struct mca_device *mca_dev) {
/*--------------------------------------------------------------------*/
struct resource mca_standard_resources[] = {
static struct resource mca_standard_resources[] = {
{ "system control port B (MCA)", 0x60, 0x60 },
{ "arbitration (MCA)", 0x90, 0x90 },
{ "card Select Feedback (MCA)", 0x91, 0x91 },
......
......@@ -33,6 +33,7 @@
#include <linux/bootmem.h>
#include <linux/seq_file.h>
#include <linux/console.h>
#include <linux/mca.h>
#include <linux/root_dev.h>
#include <linux/highmem.h>
#include <linux/module.h>
......@@ -87,7 +88,6 @@ int __initdata acpi_force = 0;
extern acpi_interrupt_flags acpi_sci_flags;
#endif
int MCA_bus;
/* for MCA, but anyone else can use it if they want */
unsigned int machine_id;
unsigned int machine_submodel_id;
......@@ -1288,6 +1288,15 @@ __setup("noreplacement", noreplacement_setup);
static char * __init machine_specific_memory_setup(void);
#ifdef CONFIG_MCA
static void set_mca_bus(int x)
{
MCA_bus = x;
}
#else
static void set_mca_bus(int x) { }
#endif
/*
* Determine if we were loaded by an EFI loader. If so, then we have also been
* passed the efi memmap, systab, etc., so we should use these data structures
......@@ -1323,7 +1332,7 @@ void __init setup_arch(char **cmdline_p)
ist_info = IST_INFO;
saved_videomode = VIDEO_MODE;
if( SYS_DESC_TABLE.length != 0 ) {
MCA_bus = SYS_DESC_TABLE.table[3] &0x2;
set_mca_bus(SYS_DESC_TABLE.table[3] & 0x2);
machine_id = SYS_DESC_TABLE.table[0];
machine_submodel_id = SYS_DESC_TABLE.table[1];
BIOS_revision = SYS_DESC_TABLE.table[2];
......
......@@ -45,6 +45,7 @@
#include <linux/sysdev.h>
#include <linux/bcd.h>
#include <linux/efi.h>
#include <linux/mca.h>
#include <asm/io.h>
#include <asm/smp.h>
......@@ -261,8 +262,7 @@ static inline void do_timer_interrupt(int irq, void *dev_id,
last_rtc_update = xtime.tv_sec - 600; /* do it again in 60 s */
}
#ifdef CONFIG_MCA
if( MCA_bus ) {
if (MCA_bus) {
/* The PS/2 uses level-triggered interrupts. You can't
turn them off, nor would you want to (any attempt to
enable edge-triggered interrupts usually gets intercepted by a
......@@ -275,7 +275,6 @@ static inline void do_timer_interrupt(int irq, void *dev_id,
irq = inb_p( 0x61 ); /* read the current state */
outb_p( irq|0x80, 0x61 ); /* reset the IRQ */
}
#endif
}
/*
......
......@@ -31,6 +31,7 @@
#include <linux/init.h>
#include <linux/console.h>
#include <linux/sysrq.h>
#include <linux/mca.h>
#include <linux/delay.h>
#include <linux/device.h>
#include <linux/tty.h>
......@@ -1861,13 +1862,11 @@ static void serial8250_config_port(struct uart_port *port, int flags)
int probeflags = PROBE_ANY;
int ret;
#ifdef CONFIG_MCA
/*
* Don't probe for MCA ports on non-MCA machines.
*/
if (up->port.flags & UPF_BOOT_ONLYMCA && !MCA_bus)
return;
#endif
/*
* Find the region that we can probe for. This in turn
......
......@@ -26,12 +26,6 @@
#define TASK_UNMAPPED_BASE \
((current->personality & ADDR_LIMIT_32BIT) ? 0x40000000 : TASK_SIZE / 2)
/*
* Bus types
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
typedef struct {
unsigned long seg;
} mm_segment_t;
......
......@@ -19,9 +19,6 @@
#ifdef __KERNEL__
#define MCA_bus 0
#define MCA_bus__is_a_macro
#include <asm/atomic.h>
#include <asm/ptrace.h>
#include <asm/procinfo.h>
......
......@@ -20,9 +20,6 @@
#ifdef __KERNEL__
#define MCA_bus 0
#define MCA_bus__is_a_macro
#include <asm/atomic.h>
#include <asm/ptrace.h>
#include <linux/string.h>
......
......@@ -45,11 +45,6 @@ static inline void wrusp(unsigned long usp) {
*/
#define TASK_UNMAPPED_BASE 0
/*
* Bus types
*/
#define MCA_bus 0
struct thread_struct {
unsigned long ksp; /* kernel stack pointer */
unsigned long usp; /* user stack pointer */
......
......@@ -40,7 +40,4 @@
*/
#define MCA_NUMADAPTERS (MCA_MAX_SLOT_NR+3)
/* lock to protect access to the MCA registers */
extern spinlock_t mca_lock;
#endif
......@@ -259,11 +259,6 @@ static inline void clear_in_cr4 (unsigned long mask)
outb((data), 0x23); \
} while (0)
/*
* Bus types (default is ISA, but people can check others with these..)
*/
extern int MCA_bus;
static inline void __monitor(const void *eax, unsigned long ecx,
unsigned long edx)
{
......
......@@ -55,11 +55,6 @@ extern inline void wrusp(unsigned long usp)
*/
#define TASK_UNMAPPED_BASE 0
/*
* Bus types
*/
#define MCA_bus 0
/*
* if you change this structure, you must change the code and offsets
* in m68k/machasm.S
......
......@@ -33,12 +33,6 @@ extern void (*cpu_wait)(void);
extern unsigned int vced_count, vcei_count;
/*
* Bus types (default is ISA, but people can check others with these..)
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
#ifdef CONFIG_MIPS32
/*
* User space process size: 2GB. This is hardcoded into a few places,
......
......@@ -107,9 +107,6 @@ extern struct cpuinfo_parisc cpu_data[NR_CPUS];
#define CPU_HVERSION ((boot_cpu_data.hversion >> 4) & 0x0FFF)
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
typedef struct {
int seg;
} mm_segment_t;
......
......@@ -78,12 +78,6 @@ extern void prepare_to_copy(struct task_struct *tsk);
*/
extern long kernel_thread(int (*fn)(void *), void *arg, unsigned long flags);
/*
* Bus types
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro
/* Lazy FPU handling on uni-processor */
extern struct task_struct *last_task_used_math;
extern struct task_struct *last_task_used_altivec;
......
......@@ -494,12 +494,6 @@ extern void prepare_to_copy(struct task_struct *tsk);
/* Create a new kernel thread. */
extern long kernel_thread(int (*fn)(void *), void *arg, unsigned long flags);
/*
* Bus types
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
/* Lazy FPU handling on uni-processor */
extern struct task_struct *last_task_used_math;
extern struct task_struct *last_task_used_altivec;
......
......@@ -191,12 +191,6 @@ extern void release_thread(struct task_struct *);
*/
extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags);
/*
* Bus types
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
/* Copy and release all segment info associated with a VM */
#define copy_segments(p, mm) do { } while(0)
#define release_segments(mm) do { } while(0)
......
......@@ -218,12 +218,6 @@ extern void release_thread(struct task_struct *);
*/
extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags);
/*
* Bus types
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
/* Copy and release all segment info associated with a VM */
#define copy_segments(p, mm) do { } while (0)
......
......@@ -23,12 +23,6 @@
#include <asm/btfixup.h>
#include <asm/page.h>
/*
* Bus types
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
/*
* The sparc has no problems with write protection
*/
......
......@@ -21,10 +21,6 @@
#include <asm/segment.h>
#include <asm/page.h>
/* Bus types */
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
/* The sparc has no problems with write protection */
#define wp_works_ok 1
#define wp_works_ok__is_a_macro /* for versions in ksyms.c */
......
......@@ -48,13 +48,6 @@
*/
#define current_text_addr() ({ __label__ _l; _l: &&_l;})
/*
* Bus types
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro /* for versions in ksyms.c */
/* If you change this, you must change the associated assembly-languages
constants defined below, THREAD_*. */
struct thread_struct {
......
......@@ -157,12 +157,6 @@ static inline void clear_in_cr4 (unsigned long mask)
:"ax");
}
/*
* Bus types
*/
#define MCA_bus 0
#define MCA_bus__is_a_macro
/*
* User space process size: 512GB - 1GB (default).
......
......@@ -6,22 +6,14 @@
#ifndef _LINUX_MCA_H
#define _LINUX_MCA_H
/* FIXME: This shouldn't happen, but we need everything that previously
* included mca.h to compile. Take it out later when the MCA #includes
* are sorted out */
#include <linux/device.h>
/* get the platform specific defines */
#ifdef CONFIG_MCA
#include <asm/mca.h>
#endif
/* The detection of MCA bus is done in the real mode (using BIOS).
* The information is exported to the protected code, where this
* variable is set to one in case MCA bus was detected.
*/
#ifndef MCA_bus__is_a_macro
extern int MCA_bus;
extern int MCA_bus;
#else
#define MCA_bus 0
#endif
/* This sets up an information callback for /proc/mca/slot?. The
......
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