diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2000-02-23 00:40:54 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2000-02-23 00:40:54 +0000 |
commit | 529c593ece216e4aaffd36bd940cb94f1fa63129 (patch) | |
tree | 78f1c0b805f5656aa7b0417a043c5346f700a2cf /arch/ia64/sn | |
parent | 0bd079751d25808d1972baee5c4eaa1db2227257 (diff) |
Merge with 2.3.43. I did ignore all modifications to the qlogicisp.c
driver due to the Origin A64 hacks.
Diffstat (limited to 'arch/ia64/sn')
-rw-r--r-- | arch/ia64/sn/Makefile | 25 | ||||
-rw-r--r-- | arch/ia64/sn/sn1/Makefile | 29 | ||||
-rw-r--r-- | arch/ia64/sn/sn1/irq.c | 50 | ||||
-rw-r--r-- | arch/ia64/sn/sn1/machvec.c | 4 | ||||
-rw-r--r-- | arch/ia64/sn/sn1/setup.c | 77 |
5 files changed, 185 insertions, 0 deletions
diff --git a/arch/ia64/sn/Makefile b/arch/ia64/sn/Makefile new file mode 100644 index 000000000..3c8810967 --- /dev/null +++ b/arch/ia64/sn/Makefile @@ -0,0 +1,25 @@ +# +# ia64/sn/Makefile +# +# Copyright (C) 1999 Silicon Graphics, Inc. +# Copyright (C) Srinivasa Thirumalachar (sprasad@engr.sgi.com) +# + +CFLAGS := $(CFLAGS) -DCONFIG_SGI_SN1 -DSN1 -DSN -DSOFTSDV \ + -DLANGUAGE_C=1 -D_LANGUAGE_C=1 +AFLAGS := $(AFLAGS) -DCONFIG_SGI_SN1 -DSN1 -DSOFTSDV + +.S.s: + $(CC) -D__ASSEMBLY__ $(AFLAGS) -E -o $*.s $< +.S.o: + $(CC) -D__ASSEMBLY__ $(AFLAGS) -c -o $*.o $< + +all: sn.a + +O_TARGET = sn.a +O_HEADERS = +O_OBJS = sn1/sn1.a + +clean:: + +include $(TOPDIR)/Rules.make diff --git a/arch/ia64/sn/sn1/Makefile b/arch/ia64/sn/sn1/Makefile new file mode 100644 index 000000000..23758c473 --- /dev/null +++ b/arch/ia64/sn/sn1/Makefile @@ -0,0 +1,29 @@ +# +# ia64/platform/sn/sn1/Makefile +# +# Copyright (C) 1999 Silicon Graphics, Inc. +# Copyright (C) Srinivasa Thirumalachar (sprasad@engr.sgi.com) +# + +CFLAGS := $(CFLAGS) -DCONFIG_SGI_SN1 -DSN1 -DSN -DSOFTSDV \ + -DLANGUAGE_C=1 -D_LANGUAGE_C=1 +AFLAGS := $(AFLAGS) -DCONFIG_SGI_SN1 -DSN1 -DSOFTSDV + +.S.s: + $(CC) -D__ASSEMBLY__ $(AFLAGS) -E -o $*.s $< +.S.o: + $(CC) -D__ASSEMBLY__ $(AFLAGS) -c -o $*.o $< + +all: sn1.a + +O_TARGET = sn1.a +O_HEADERS = +O_OBJS = irq.o setup.o + +ifeq ($(CONFIG_IA64_GENERIC),y) +O_OBJS += machvec.o +endif + +clean:: + +include $(TOPDIR)/Rules.make diff --git a/arch/ia64/sn/sn1/irq.c b/arch/ia64/sn/sn1/irq.c new file mode 100644 index 000000000..df8e56943 --- /dev/null +++ b/arch/ia64/sn/sn1/irq.c @@ -0,0 +1,50 @@ +#include <linux/kernel.h> + +#include <asm/irq.h> +#include <asm/ptrace.h> + +static int +sn1_startup_irq(unsigned int irq) +{ + return(0); +} + +static void +sn1_shutdown_irq(unsigned int irq) +{ +} + +static void +sn1_disable_irq(unsigned int irq) +{ +} + +static void +sn1_enable_irq(unsigned int irq) +{ +} + +static int +sn1_handle_irq(unsigned int irq, struct pt_regs *regs) +{ + return(0); +} + +struct hw_interrupt_type irq_type_sn1 = { + "sn1_irq", + sn1_startup_irq, + sn1_shutdown_irq, + sn1_handle_irq, + sn1_enable_irq, + sn1_disable_irq +}; + +void +sn1_irq_init (struct irq_desc desc[NR_IRQS]) +{ + int i; + + for (i = IA64_MIN_VECTORED_IRQ; i <= IA64_MAX_VECTORED_IRQ; ++i) { + irq_desc[i].handler = &irq_type_sn1; + } +} diff --git a/arch/ia64/sn/sn1/machvec.c b/arch/ia64/sn/sn1/machvec.c new file mode 100644 index 000000000..2e36b2e08 --- /dev/null +++ b/arch/ia64/sn/sn1/machvec.c @@ -0,0 +1,4 @@ +#include <asm/machvec_init.h> +#include <asm/machvec_sn1.h> + +MACHVEC_DEFINE(sn1) diff --git a/arch/ia64/sn/sn1/setup.c b/arch/ia64/sn/sn1/setup.c new file mode 100644 index 000000000..1e3a39ae3 --- /dev/null +++ b/arch/ia64/sn/sn1/setup.c @@ -0,0 +1,77 @@ +/* + * + * Copyright (C) 1999 Silicon Graphics, Inc. + * Copyright (C) Vijay Chander(vijay@engr.sgi.com) + */ +#include <linux/config.h> +#include <linux/init.h> +#include <linux/delay.h> +#include <linux/kernel.h> +#include <linux/kdev_t.h> +#include <linux/string.h> +#include <linux/tty.h> +#include <linux/console.h> +#include <linux/timex.h> +#include <linux/sched.h> + +#include <asm/io.h> +#include <asm/machvec.h> +#include <asm/system.h> +#include <asm/processor.h> + + +/* + * The format of "screen_info" is strange, and due to early i386-setup + * code. This is just enough to make the console code think we're on a + * VGA color display. + */ +struct screen_info sn1_screen_info = { + orig_x: 0, + orig_y: 0, + orig_video_mode: 3, + orig_video_cols: 80, + orig_video_ega_bx: 3, + orig_video_lines: 25, + orig_video_isVGA: 1, + orig_video_points: 16 +}; + +/* + * This is here so we can use the CMOS detection in ide-probe.c to + * determine what drives are present. In theory, we don't need this + * as the auto-detection could be done via ide-probe.c:do_probe() but + * in practice that would be much slower, which is painful when + * running in the simulator. Note that passing zeroes in DRIVE_INFO + * is sufficient (the IDE driver will autodetect the drive geometry). + */ +char drive_info[4*16]; + +unsigned long +sn1_map_nr (unsigned long addr) +{ + return MAP_NR_SN1(addr); +} + +void +sn1_setup(char **cmdline_p) +{ + + ROOT_DEV = to_kdev_t(0x0301); /* default to first IDE drive */ + +#if !defined (CONFIG_IA64_SOFTSDV_HACKS) + /* + * Program the timer to deliver timer ticks. 0x40 is the I/O port + * address of PIT counter 0, 0x43 is the I/O port address of the + * PIT control word. + */ + request_region(0x40,0x20,"timer"); + outb(0x34, 0x43); /* Control word */ + outb(LATCH & 0xff , 0x40); /* LSB */ + outb(LATCH >> 8, 0x40); /* MSB */ + printk("PIT: LATCH at 0x%x%x for %d HZ\n", LATCH >> 8, LATCH & 0xff, HZ); +#endif +#ifdef __SMP__ + init_smp_config(); +#endif + screen_info = sn1_screen_info; +} |