2 * linux/arch/arm/mach-footbridge/cats-hw.c
6 * Copyright (C) 1998, 1999 Russell King, Phil Blundell
8 #include <linux/ioport.h>
9 #include <linux/kernel.h>
10 #include <linux/init.h>
12 #include <asm/hardware/dec21285.h>
14 #include <asm/mach-types.h>
15 #include <asm/setup.h>
17 #include <asm/mach/arch.h>
21 #define CFG_PORT 0x370
22 #define INDEX_PORT (CFG_PORT)
23 #define DATA_PORT (CFG_PORT + 1)
25 static int __init cats_hw_init(void)
27 if (machine_is_cats()) {
28 /* Set Aladdin to CONFIGURE mode */
32 /* Select logical device 3 */
33 outb(0x07, INDEX_PORT);
34 outb(0x03, DATA_PORT);
36 /* Set parallel port to DMA channel 3, ECP+EPP1.9,
38 outb(0x74, INDEX_PORT);
39 outb(0x03, DATA_PORT);
41 outb(0xf0, INDEX_PORT);
42 outb(0x0f, DATA_PORT);
44 outb(0xf1, INDEX_PORT);
45 outb(0x07, DATA_PORT);
47 /* Select logical device 4 */
48 outb(0x07, INDEX_PORT);
49 outb(0x04, DATA_PORT);
51 /* UART1 high speed mode */
52 outb(0xf0, INDEX_PORT);
53 outb(0x02, DATA_PORT);
55 /* Select logical device 5 */
56 outb(0x07, INDEX_PORT);
57 outb(0x05, DATA_PORT);
59 /* UART2 high speed mode */
60 outb(0xf0, INDEX_PORT);
61 outb(0x02, DATA_PORT);
63 /* Set Aladdin to RUN mode */
70 __initcall(cats_hw_init);
73 * CATS uses soft-reboot by default, since
74 * hard reboots fail on early boards.
77 fixup_cats(struct machine_desc *desc, struct tag *tags,
78 char **cmdline, struct meminfo *mi)
80 ORIG_VIDEO_LINES = 25;
81 ORIG_VIDEO_POINTS = 16;
85 MACHINE_START(CATS, "Chalice-CATS")
86 MAINTAINER("Philip Blundell")
87 BOOT_MEM(0x00000000, DC21285_ARMCSR_BASE, 0xfe000000)
88 BOOT_PARAMS(0x00000100)
91 MAPIO(footbridge_map_io)
92 INITIRQ(footbridge_init_irq)