patch-2.3.11 linux/arch/arm/kernel/hw-footbridge.c
Next file: linux/arch/arm/kernel/isa.c
Previous file: linux/arch/arm/kernel/head-armv.S
Back to the patch index
Back to the overall index
- Lines: 74
- Date:
Mon Jul 19 09:52:57 1999
- Orig file:
v2.3.10/linux/arch/arm/kernel/hw-footbridge.c
- Orig date:
Thu Jun 17 01:11:35 1999
diff -u --recursive --new-file v2.3.10/linux/arch/arm/kernel/hw-footbridge.c linux/arch/arm/kernel/hw-footbridge.c
@@ -866,8 +866,63 @@
#define DEFAULT_LEDS GPIO_GREEN_LED
#endif
+/*
+ * CATS stuff
+ */
+#ifdef CONFIG_CATS
+
+#define CONFIG_PORT 0x370
+#define INDEX_PORT (CONFIG_PORT)
+#define DATA_PORT (CONFIG_PORT + 1)
+
+static void __init cats_hw_init(void)
+{
+ /* Set Aladdin to CONFIGURE mode */
+ outb(0x51, CONFIG_PORT);
+ outb(0x23, CONFIG_PORT);
+
+ /* Select logical device 3 */
+ outb(0x07, INDEX_PORT);
+ outb(0x03, DATA_PORT);
+
+ /* Set parallel port to DMA channel 3, ECP+EPP1.9,
+ enable EPP timeout */
+ outb(0x74, INDEX_PORT);
+ outb(0x03, DATA_PORT);
+
+ outb(0xf0, INDEX_PORT);
+ outb(0x0f, DATA_PORT);
+
+ outb(0xf1, INDEX_PORT);
+ outb(0x07, DATA_PORT);
+
+ /* Select logical device 4 */
+ outb(0x07, INDEX_PORT);
+ outb(0x04, DATA_PORT);
+
+ /* UART1 high speed mode */
+ outb(0xf0, INDEX_PORT);
+ outb(0x02, DATA_PORT);
+
+ /* Select logical device 5 */
+ outb(0x07, INDEX_PORT);
+ outb(0x05, DATA_PORT);
+
+ /* UART2 high speed mode */
+ outb(0xf0, INDEX_PORT);
+ outb(0x02, DATA_PORT);
+
+ /* Set Aladdin to RUN mode */
+ outb(0xbb, CONFIG_PORT);
+}
+
+#endif
+
__initfunc(void hw_init(void))
{
+ extern void register_isa_ports(unsigned int, unsigned int,
+ unsigned int);
+ register_isa_ports(DC21285_PCI_MEM, DC21285_PCI_IO, 0);
#ifdef CONFIG_ARCH_NETWINDER
/*
* this ought to have a better home...
@@ -888,6 +943,9 @@
spin_unlock_irqrestore(&gpio_lock, flags);
}
#endif
+
+ if (machine_is_cats())
+ cats_hw_init();
leds_event(led_start);
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)