aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-19 16:38:42 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-19 16:38:42 -0500
commitcb553c480078759014096bc766dc76400e1d8397 (patch)
tree97262cd9252a7dc68f8701f8435b0d10b9e79536 /include
parent42eaf0d8f2e7b8201afc00b0ebe1bd89ea51d42d (diff)
parent040cf8cfe5f0674ddf256f98366137a7b90d421f (diff)
Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus: [MIPS] Update defconfigs [MIPS] Support for several more SNI RM models. [MIPS] Include <asm/bugs> to for declaration of check_bugs32. [MIPS] Add external declaration of pagetable_init() to pgalloc.h [MIPS] Make kernel_thread_helper() static [MIPS] Make __declare_dbe_table static and avoid it getting optimized away [MIPS] Use MIPS R2 instructions for bitops. [MIPS] signals: Share even more code. [MIPS] Fix CONFIG_MIPS32_N32=y CONFIG_MIPS32_O32=n build [MIPS] Iomap implementation. [MIPS] <asm/compat-signal.h> needs to include <asm/uaccess.h>. [MIPS] IP27: Fix warning. [MIPS] Fix sigset_t endianess swapping issues in 32-bit compat code.
Diffstat (limited to 'include')
-rw-r--r--include/asm-mips/abi.h2
-rw-r--r--include/asm-mips/bitops.h52
-rw-r--r--include/asm-mips/compat-signal.h8
-rw-r--r--include/asm-mips/ds1216.h31
-rw-r--r--include/asm-mips/io.h29
-rw-r--r--include/asm-mips/mach-rm/cpu-feature-overrides.h5
-rw-r--r--include/asm-mips/pci.h1
-rw-r--r--include/asm-mips/pgalloc.h2
-rw-r--r--include/asm-mips/signal.h17
-rw-r--r--include/asm-mips/sni.h132
10 files changed, 216 insertions, 63 deletions
diff --git a/include/asm-mips/abi.h b/include/asm-mips/abi.h
index 1ce0518ace2e..1dd74fbdc09b 100644
--- a/include/asm-mips/abi.h
+++ b/include/asm-mips/abi.h
@@ -13,13 +13,13 @@
13#include <asm/siginfo.h> 13#include <asm/siginfo.h>
14 14
15struct mips_abi { 15struct mips_abi {
16 void (* const do_signal)(struct pt_regs *regs);
17 int (* const setup_frame)(struct k_sigaction * ka, 16 int (* const setup_frame)(struct k_sigaction * ka,
18 struct pt_regs *regs, int signr, 17 struct pt_regs *regs, int signr,
19 sigset_t *set); 18 sigset_t *set);
20 int (* const setup_rt_frame)(struct k_sigaction * ka, 19 int (* const setup_rt_frame)(struct k_sigaction * ka,
21 struct pt_regs *regs, int signr, 20 struct pt_regs *regs, int signr,
22 sigset_t *set, siginfo_t *info); 21 sigset_t *set, siginfo_t *info);
22 const unsigned long restart;
23}; 23};
24 24
25#endif /* _ASM_ABI_H */ 25#endif /* _ASM_ABI_H */
diff --git a/include/asm-mips/bitops.h b/include/asm-mips/bitops.h
index 06c08228a525..89436b96ad66 100644
--- a/include/asm-mips/bitops.h
+++ b/include/asm-mips/bitops.h
@@ -3,7 +3,7 @@
3 * License. See the file "COPYING" in the main directory of this archive 3 * License. See the file "COPYING" in the main directory of this archive
4 * for more details. 4 * for more details.
5 * 5 *
6 * Copyright (c) 1994 - 1997, 1999, 2000, 06 Ralf Baechle (ralf@linux-mips.org) 6 * Copyright (c) 1994 - 1997, 99, 2000, 06, 07 Ralf Baechle (ralf@linux-mips.org)
7 * Copyright (c) 1999, 2000 Silicon Graphics, Inc. 7 * Copyright (c) 1999, 2000 Silicon Graphics, Inc.
8 */ 8 */
9#ifndef _ASM_BITOPS_H 9#ifndef _ASM_BITOPS_H
@@ -24,11 +24,15 @@
24#define SZLONG_MASK 31UL 24#define SZLONG_MASK 31UL
25#define __LL "ll " 25#define __LL "ll "
26#define __SC "sc " 26#define __SC "sc "
27#define __INS "ins "
28#define __EXT "ext "
27#elif (_MIPS_SZLONG == 64) 29#elif (_MIPS_SZLONG == 64)
28#define SZLONG_LOG 6 30#define SZLONG_LOG 6
29#define SZLONG_MASK 63UL 31#define SZLONG_MASK 63UL
30#define __LL "lld " 32#define __LL "lld "
31#define __SC "scd " 33#define __SC "scd "
34#define __INS "dins "
35#define __EXT "dext "
32#endif 36#endif
33 37
34/* 38/*
@@ -62,6 +66,19 @@ static inline void set_bit(unsigned long nr, volatile unsigned long *addr)
62 " .set mips0 \n" 66 " .set mips0 \n"
63 : "=&r" (temp), "=m" (*m) 67 : "=&r" (temp), "=m" (*m)
64 : "ir" (1UL << (nr & SZLONG_MASK)), "m" (*m)); 68 : "ir" (1UL << (nr & SZLONG_MASK)), "m" (*m));
69#ifdef CONFIG_CPU_MIPSR2
70 } else if (__builtin_constant_p(nr)) {
71 __asm__ __volatile__(
72 "1: " __LL "%0, %1 # set_bit \n"
73 " " __INS "%0, %4, %2, 1 \n"
74 " " __SC "%0, %1 \n"
75 " beqz %0, 2f \n"
76 " .subsection 2 \n"
77 "2: b 1b \n"
78 " .previous \n"
79 : "=&r" (temp), "=m" (*m)
80 : "ir" (nr & SZLONG_MASK), "m" (*m), "r" (~0));
81#endif /* CONFIG_CPU_MIPSR2 */
65 } else if (cpu_has_llsc) { 82 } else if (cpu_has_llsc) {
66 __asm__ __volatile__( 83 __asm__ __volatile__(
67 " .set mips3 \n" 84 " .set mips3 \n"
@@ -113,6 +130,19 @@ static inline void clear_bit(unsigned long nr, volatile unsigned long *addr)
113 " .set mips0 \n" 130 " .set mips0 \n"
114 : "=&r" (temp), "=m" (*m) 131 : "=&r" (temp), "=m" (*m)
115 : "ir" (~(1UL << (nr & SZLONG_MASK))), "m" (*m)); 132 : "ir" (~(1UL << (nr & SZLONG_MASK))), "m" (*m));
133#ifdef CONFIG_CPU_MIPSR2
134 } else if (__builtin_constant_p(nr)) {
135 __asm__ __volatile__(
136 "1: " __LL "%0, %1 # clear_bit \n"
137 " " __INS "%0, $0, %2, 1 \n"
138 " " __SC "%0, %1 \n"
139 " beqz %0, 2f \n"
140 " .subsection 2 \n"
141 "2: b 1b \n"
142 " .previous \n"
143 : "=&r" (temp), "=m" (*m)
144 : "ir" (nr & SZLONG_MASK), "m" (*m));
145#endif /* CONFIG_CPU_MIPSR2 */
116 } else if (cpu_has_llsc) { 146 } else if (cpu_has_llsc) {
117 __asm__ __volatile__( 147 __asm__ __volatile__(
118 " .set mips3 \n" 148 " .set mips3 \n"
@@ -291,6 +321,26 @@ static inline int test_and_clear_bit(unsigned long nr,
291 : "memory"); 321 : "memory");
292 322
293 return res != 0; 323 return res != 0;
324#ifdef CONFIG_CPU_MIPSR2
325 } else if (__builtin_constant_p(nr)) {
326 unsigned long *m = ((unsigned long *) addr) + (nr >> SZLONG_LOG);
327 unsigned long temp, res;
328
329 __asm__ __volatile__(
330 "1: " __LL "%0, %1 # test_and_clear_bit \n"
331 " " __EXT "%2, %0, %3, 1 \n"
332 " " __INS "%0, $0, %3, 1 \n"
333 " " __SC "%0, %1 \n"
334 " beqz %0, 2f \n"
335 " .subsection 2 \n"
336 "2: b 1b \n"
337 " .previous \n"
338 : "=&r" (temp), "=m" (*m), "=&r" (res)
339 : "ri" (nr & SZLONG_MASK), "m" (*m)
340 : "memory");
341
342 return res;
343#endif
294 } else if (cpu_has_llsc) { 344 } else if (cpu_has_llsc) {
295 unsigned long *m = ((unsigned long *) addr) + (nr >> SZLONG_LOG); 345 unsigned long *m = ((unsigned long *) addr) + (nr >> SZLONG_LOG);
296 unsigned long temp, res; 346 unsigned long temp, res;
diff --git a/include/asm-mips/compat-signal.h b/include/asm-mips/compat-signal.h
index 672077084aa1..6599a901b63e 100644
--- a/include/asm-mips/compat-signal.h
+++ b/include/asm-mips/compat-signal.h
@@ -5,6 +5,11 @@
5#include <linux/compat.h> 5#include <linux/compat.h>
6#include <linux/compiler.h> 6#include <linux/compiler.h>
7 7
8#include <asm/signal.h>
9#include <asm/siginfo.h>
10
11#include <asm/uaccess.h>
12
8static inline int __copy_conv_sigset_to_user(compat_sigset_t __user *d, 13static inline int __copy_conv_sigset_to_user(compat_sigset_t __user *d,
9 const sigset_t *s) 14 const sigset_t *s)
10{ 15{
@@ -33,9 +38,6 @@ static inline int __copy_conv_sigset_from_user(sigset_t *d,
33 BUG_ON(sizeof(*d) != sizeof(*s)); 38 BUG_ON(sizeof(*d) != sizeof(*s));
34 BUG_ON(_NSIG_WORDS != 2); 39 BUG_ON(_NSIG_WORDS != 2);
35 40
36 if (unlikely(!access_ok(VERIFY_READ, d, sizeof(*d))))
37 return -EFAULT;
38
39#ifdef CONFIG_CPU_BIG_ENDIAN 41#ifdef CONFIG_CPU_BIG_ENDIAN
40 err = __get_user(u->c.sig[1], &s->sig[0]); 42 err = __get_user(u->c.sig[1], &s->sig[0]);
41 err |= __get_user(u->c.sig[0], &s->sig[1]); 43 err |= __get_user(u->c.sig[0], &s->sig[1]);
diff --git a/include/asm-mips/ds1216.h b/include/asm-mips/ds1216.h
new file mode 100644
index 000000000000..1ff8b73f7a6a
--- /dev/null
+++ b/include/asm-mips/ds1216.h
@@ -0,0 +1,31 @@
1#ifndef _DS1216_H
2#define _DS1216_H
3
4extern volatile unsigned char *ds1216_base;
5unsigned long ds1216_get_cmos_time(void);
6int ds1216_set_rtc_mmss(unsigned long nowtime);
7
8#define DS1216_SEC_BYTE 1
9#define DS1216_MIN_BYTE 2
10#define DS1216_HOUR_BYTE 3
11#define DS1216_HOUR_MASK (0x1f)
12#define DS1216_AMPM_MASK (1<<5)
13#define DS1216_1224_MASK (1<<7)
14#define DS1216_DAY_BYTE 4
15#define DS1216_DAY_MASK (0x7)
16#define DS1216_DATE_BYTE 5
17#define DS1216_DATE_MASK (0x3f)
18#define DS1216_MONTH_BYTE 6
19#define DS1216_MONTH_MASK (0x1f)
20#define DS1216_YEAR_BYTE 7
21
22#define DS1216_SEC(buf) (buf[DS1216_SEC_BYTE])
23#define DS1216_MIN(buf) (buf[DS1216_MIN_BYTE])
24#define DS1216_HOUR(buf) (buf[DS1216_HOUR_BYTE] & DS1216_HOUR_MASK)
25#define DS1216_AMPM(buf) (buf[DS1216_HOUR_BYTE] & DS1216_AMPM_MASK)
26#define DS1216_1224(buf) (buf[DS1216_HOUR_BYTE] & DS1216_1224_MASK)
27#define DS1216_DATE(buf) (buf[DS1216_DATE_BYTE] & DS1216_DATE_MASK)
28#define DS1216_MONTH(buf) (buf[DS1216_MONTH_BYTE] & DS1216_MONTH_MASK)
29#define DS1216_YEAR(buf) (buf[DS1216_YEAR_BYTE])
30
31#endif
diff --git a/include/asm-mips/io.h b/include/asm-mips/io.h
index b6a2eb816628..92ec2618560c 100644
--- a/include/asm-mips/io.h
+++ b/include/asm-mips/io.h
@@ -20,6 +20,7 @@
20#include <asm/byteorder.h> 20#include <asm/byteorder.h>
21#include <asm/cpu.h> 21#include <asm/cpu.h>
22#include <asm/cpu-features.h> 22#include <asm/cpu-features.h>
23#include <asm-generic/iomap.h>
23#include <asm/page.h> 24#include <asm/page.h>
24#include <asm/pgtable-bits.h> 25#include <asm/pgtable-bits.h>
25#include <asm/processor.h> 26#include <asm/processor.h>
@@ -518,34 +519,6 @@ static inline void memcpy_toio(volatile void __iomem *dst, const void *src, int
518} 519}
519 520
520/* 521/*
521 * Memory Mapped I/O
522 */
523#define ioread8(addr) readb(addr)
524#define ioread16(addr) readw(addr)
525#define ioread32(addr) readl(addr)
526
527#define iowrite8(b,addr) writeb(b,addr)
528#define iowrite16(w,addr) writew(w,addr)
529#define iowrite32(l,addr) writel(l,addr)
530
531#define ioread8_rep(a,b,c) readsb(a,b,c)
532#define ioread16_rep(a,b,c) readsw(a,b,c)
533#define ioread32_rep(a,b,c) readsl(a,b,c)
534
535#define iowrite8_rep(a,b,c) writesb(a,b,c)
536#define iowrite16_rep(a,b,c) writesw(a,b,c)
537#define iowrite32_rep(a,b,c) writesl(a,b,c)
538
539/* Create a virtual mapping cookie for an IO port range */
540extern void __iomem *ioport_map(unsigned long port, unsigned int nr);
541extern void ioport_unmap(void __iomem *);
542
543/* Create a virtual mapping cookie for a PCI BAR (memory or IO) */
544struct pci_dev;
545extern void __iomem *pci_iomap(struct pci_dev *dev, int bar, unsigned long max);
546extern void pci_iounmap(struct pci_dev *dev, void __iomem *);
547
548/*
549 * ISA space is 'always mapped' on currently supported MIPS systems, no need 522 * ISA space is 'always mapped' on currently supported MIPS systems, no need
550 * to explicitly ioremap() it. The fact that the ISA IO space is mapped 523 * to explicitly ioremap() it. The fact that the ISA IO space is mapped
551 * to PAGE_OFFSET is pure coincidence - it does not mean ISA values 524 * to PAGE_OFFSET is pure coincidence - it does not mean ISA values
diff --git a/include/asm-mips/mach-rm/cpu-feature-overrides.h b/include/asm-mips/mach-rm/cpu-feature-overrides.h
index 11410ae10d36..7e07283140a3 100644
--- a/include/asm-mips/mach-rm/cpu-feature-overrides.h
+++ b/include/asm-mips/mach-rm/cpu-feature-overrides.h
@@ -21,9 +21,7 @@
21#define cpu_has_watch 0 21#define cpu_has_watch 0
22#define cpu_has_mips16 0 22#define cpu_has_mips16 0
23#define cpu_has_divec 0 23#define cpu_has_divec 0
24#define cpu_has_vce 0
25#define cpu_has_cache_cdex_p 1 24#define cpu_has_cache_cdex_p 1
26#define cpu_has_cache_cdex_s 0
27#define cpu_has_prefetch 0 25#define cpu_has_prefetch 0
28#define cpu_has_mcheck 0 26#define cpu_has_mcheck 0
29#define cpu_has_ejtag 0 27#define cpu_has_ejtag 0
@@ -35,9 +33,6 @@
35#define cpu_has_nofpuex 0 33#define cpu_has_nofpuex 0
36#define cpu_has_64bits 1 34#define cpu_has_64bits 1
37 35
38#define cpu_dcache_line_size() 32
39#define cpu_icache_line_size() 32
40
41#define cpu_has_mips32r1 0 36#define cpu_has_mips32r1 0
42#define cpu_has_mips32r2 0 37#define cpu_has_mips32r2 0
43#define cpu_has_mips64r1 0 38#define cpu_has_mips64r1 0
diff --git a/include/asm-mips/pci.h b/include/asm-mips/pci.h
index 7f0f120ca07c..3eea3ba0fca5 100644
--- a/include/asm-mips/pci.h
+++ b/include/asm-mips/pci.h
@@ -32,6 +32,7 @@ struct pci_controller {
32 unsigned long mem_offset; 32 unsigned long mem_offset;
33 struct resource *io_resource; 33 struct resource *io_resource;
34 unsigned long io_offset; 34 unsigned long io_offset;
35 unsigned long io_map_base;
35 36
36 unsigned int index; 37 unsigned int index;
37 /* For compatibility with current (as of July 2003) pciutils 38 /* For compatibility with current (as of July 2003) pciutils
diff --git a/include/asm-mips/pgalloc.h b/include/asm-mips/pgalloc.h
index af121c67dc71..5685d4fc7881 100644
--- a/include/asm-mips/pgalloc.h
+++ b/include/asm-mips/pgalloc.h
@@ -130,4 +130,6 @@ static inline void pmd_free(pmd_t *pmd)
130 130
131#define check_pgt_cache() do { } while (0) 131#define check_pgt_cache() do { } while (0)
132 132
133extern void pagetable_init(void);
134
133#endif /* _ASM_PGALLOC_H */ 135#endif /* _ASM_PGALLOC_H */
diff --git a/include/asm-mips/signal.h b/include/asm-mips/signal.h
index 8b391a2f0814..7a28989f7ee3 100644
--- a/include/asm-mips/signal.h
+++ b/include/asm-mips/signal.h
@@ -137,23 +137,6 @@ typedef struct sigaltstack {
137 137
138#define ptrace_signal_deliver(regs, cookie) do { } while (0) 138#define ptrace_signal_deliver(regs, cookie) do { } while (0)
139 139
140struct pt_regs;
141extern void do_signal(struct pt_regs *regs);
142extern void do_signal32(struct pt_regs *regs);
143
144extern int setup_frame(struct k_sigaction * ka, struct pt_regs *regs,
145 int signr, sigset_t *set);
146extern int setup_rt_frame(struct k_sigaction * ka, struct pt_regs *regs,
147 int signr, sigset_t *set, siginfo_t *info);
148
149extern int setup_frame_32(struct k_sigaction * ka, struct pt_regs *regs,
150 int signr, sigset_t *set);
151extern int setup_rt_frame_32(struct k_sigaction * ka, struct pt_regs *regs,
152 int signr, sigset_t *set, siginfo_t *info);
153
154extern int setup_rt_frame_n32(struct k_sigaction * ka, struct pt_regs *regs,
155 int signr, sigset_t *set, siginfo_t *info);
156
157#endif /* __KERNEL__ */ 140#endif /* __KERNEL__ */
158 141
159#endif /* _ASM_SIGNAL_H */ 142#endif /* _ASM_SIGNAL_H */
diff --git a/include/asm-mips/sni.h b/include/asm-mips/sni.h
index b9ba54d0dd35..62f9be6f7320 100644
--- a/include/asm-mips/sni.h
+++ b/include/asm-mips/sni.h
@@ -6,12 +6,72 @@
6 * for more details. 6 * for more details.
7 * 7 *
8 * Copyright (C) 1997, 1998 by Ralf Baechle 8 * Copyright (C) 1997, 1998 by Ralf Baechle
9 * Copyright (C) 2006 Thomas Bogendoerfer (tsbogend@alpha.franken.de)
9 */ 10 */
10#ifndef __ASM_SNI_H 11#ifndef __ASM_SNI_H
11#define __ASM_SNI_H 12#define __ASM_SNI_H
12 13
14extern unsigned int sni_brd_type;
15
16#define SNI_BRD_10 2
17#define SNI_BRD_10NEW 3
18#define SNI_BRD_TOWER_OASIC 4
19#define SNI_BRD_MINITOWER 5
20#define SNI_BRD_PCI_TOWER 6
21#define SNI_BRD_RM200 7
22#define SNI_BRD_PCI_MTOWER 8
23#define SNI_BRD_PCI_DESKTOP 9
24#define SNI_BRD_PCI_TOWER_CPLUS 10
25#define SNI_BRD_PCI_MTOWER_CPLUS 11
26
27/* RM400 cpu types */
28#define SNI_CPU_M8021 0x01
29#define SNI_CPU_M8030 0x04
30#define SNI_CPU_M8031 0x06
31#define SNI_CPU_M8034 0x0f
32#define SNI_CPU_M8037 0x07
33#define SNI_CPU_M8040 0x05
34#define SNI_CPU_M8043 0x09
35#define SNI_CPU_M8050 0x0b
36#define SNI_CPU_M8053 0x0d
37
13#define SNI_PORT_BASE 0xb4000000 38#define SNI_PORT_BASE 0xb4000000
14 39
40#ifndef __MIPSEL__
41/*
42 * ASIC PCI registers for big endian configuration.
43 */
44#define PCIMT_UCONF 0xbfff0004
45#define PCIMT_IOADTIMEOUT2 0xbfff000c
46#define PCIMT_IOMEMCONF 0xbfff0014
47#define PCIMT_IOMMU 0xbfff001c
48#define PCIMT_IOADTIMEOUT1 0xbfff0024
49#define PCIMT_DMAACCESS 0xbfff002c
50#define PCIMT_DMAHIT 0xbfff0034
51#define PCIMT_ERRSTATUS 0xbfff003c
52#define PCIMT_ERRADDR 0xbfff0044
53#define PCIMT_SYNDROME 0xbfff004c
54#define PCIMT_ITPEND 0xbfff0054
55#define IT_INT2 0x01
56#define IT_INTD 0x02
57#define IT_INTC 0x04
58#define IT_INTB 0x08
59#define IT_INTA 0x10
60#define IT_EISA 0x20
61#define IT_SCSI 0x40
62#define IT_ETH 0x80
63#define PCIMT_IRQSEL 0xbfff005c
64#define PCIMT_TESTMEM 0xbfff0064
65#define PCIMT_ECCREG 0xbfff006c
66#define PCIMT_CONFIG_ADDRESS 0xbfff0074
67#define PCIMT_ASIC_ID 0xbfff007c /* read */
68#define PCIMT_SOFT_RESET 0xbfff007c /* write */
69#define PCIMT_PIA_OE 0xbfff0084
70#define PCIMT_PIA_DATAOUT 0xbfff008c
71#define PCIMT_PIA_DATAIN 0xbfff0094
72#define PCIMT_CACHECONF 0xbfff009c
73#define PCIMT_INVSPACE 0xbfff00a4
74#else
15/* 75/*
16 * ASIC PCI registers for little endian configuration. 76 * ASIC PCI registers for little endian configuration.
17 */ 77 */
@@ -45,6 +105,8 @@
45#define PCIMT_PIA_DATAIN 0xbfff0090 105#define PCIMT_PIA_DATAIN 0xbfff0090
46#define PCIMT_CACHECONF 0xbfff0098 106#define PCIMT_CACHECONF 0xbfff0098
47#define PCIMT_INVSPACE 0xbfff00a0 107#define PCIMT_INVSPACE 0xbfff00a0
108#endif
109
48#define PCIMT_PCI_CONF 0xbfff0100 110#define PCIMT_PCI_CONF 0xbfff0100
49 111
50/* 112/*
@@ -73,6 +135,36 @@
73#define PCIMT_PWDN 0xbfdf0000 135#define PCIMT_PWDN 0xbfdf0000
74 136
75/* 137/*
138 * A20R based boards
139 */
140#define A20R_PT_CLOCK_BASE 0xbc040000
141#define A20R_PT_TIM0_ACK 0xbc050000
142#define A20R_PT_TIM1_ACK 0xbc060000
143
144#define SNI_MIPS_IRQ_CPU_BASE 16
145#define SNI_MIPS_IRQ_CPU_TIMER (SNI_MIPS_IRQ_CPU_BASE+7)
146
147#define SNI_A20R_IRQ_BASE SNI_MIPS_IRQ_CPU_BASE
148#define SNI_A20R_IRQ_TIMER (SNI_A20R_IRQ_BASE+5)
149
150#define SNI_DS1216_A20R_BASE 0xbc081ffc
151#define SNI_DS1216_RM200_BASE 0xbcd41ffc
152
153#define SNI_PCIT_INT_REG 0xbfff000c
154
155#define SNI_PCIT_INT_START 24
156#define SNI_PCIT_INT_END 30
157
158#define PCIT_IRQ_ETHERNET (SNI_MIPS_IRQ_CPU_BASE + 5)
159#define PCIT_IRQ_INTA (SNI_PCIT_INT_START + 0)
160#define PCIT_IRQ_INTB (SNI_PCIT_INT_START + 1)
161#define PCIT_IRQ_INTC (SNI_PCIT_INT_START + 2)
162#define PCIT_IRQ_INTD (SNI_PCIT_INT_START + 3)
163#define PCIT_IRQ_SCSI0 (SNI_PCIT_INT_START + 4)
164#define PCIT_IRQ_SCSI1 (SNI_PCIT_INT_START + 5)
165
166
167/*
76 * Interrupt 0-16 are EISA interrupts. Interrupts from 16 on are assigned 168 * Interrupt 0-16 are EISA interrupts. Interrupts from 16 on are assigned
77 * to the other interrupts generated by ASIC PCI. 169 * to the other interrupts generated by ASIC PCI.
78 * 170 *
@@ -80,18 +172,22 @@
80 * ASIC PCI interrupt. 172 * ASIC PCI interrupt.
81 */ 173 */
82#define PCIMT_KEYBOARD_IRQ 1 174#define PCIMT_KEYBOARD_IRQ 1
83#define PCIMT_IRQ_INT2 16 175#define PCIMT_IRQ_INT2 24
84#define PCIMT_IRQ_INTD 17 176#define PCIMT_IRQ_INTD 25
85#define PCIMT_IRQ_INTC 18 177#define PCIMT_IRQ_INTC 26
86#define PCIMT_IRQ_INTB 19 178#define PCIMT_IRQ_INTB 27
87#define PCIMT_IRQ_INTA 20 179#define PCIMT_IRQ_INTA 28
88#define PCIMT_IRQ_EISA 21 180#define PCIMT_IRQ_EISA 29
89#define PCIMT_IRQ_SCSI 22 181#define PCIMT_IRQ_SCSI 30
90#define PCIMT_IRQ_ETHERNET 23 182
183#define PCIMT_IRQ_ETHERNET (SNI_MIPS_IRQ_CPU_BASE+6)
184
185#if 0
91#define PCIMT_IRQ_TEMPERATURE 24 186#define PCIMT_IRQ_TEMPERATURE 24
92#define PCIMT_IRQ_EISA_NMI 25 187#define PCIMT_IRQ_EISA_NMI 25
93#define PCIMT_IRQ_POWER_OFF 26 188#define PCIMT_IRQ_POWER_OFF 26
94#define PCIMT_IRQ_BUTTON 27 189#define PCIMT_IRQ_BUTTON 27
190#endif
95 191
96/* 192/*
97 * Base address for the mapped 16mb EISA bus segment. 193 * Base address for the mapped 16mb EISA bus segment.
@@ -101,4 +197,24 @@
101/* PCI EISA Interrupt acknowledge */ 197/* PCI EISA Interrupt acknowledge */
102#define PCIMT_INT_ACKNOWLEDGE 0xba000000 198#define PCIMT_INT_ACKNOWLEDGE 0xba000000
103 199
200/* board specific init functions */
201extern void sni_a20r_init (void);
202extern void sni_pcit_init (void);
203extern void sni_rm200_init (void);
204extern void sni_pcimt_init (void);
205
206/* board specific irq init functions */
207extern void sni_a20r_irq_init (void);
208extern void sni_pcit_irq_init (void);
209extern void sni_pcit_cplus_irq_init (void);
210extern void sni_rm200_irq_init (void);
211extern void sni_pcimt_irq_init (void);
212
213/* timer inits */
214extern void sni_cpu_time_init(void);
215
216/* common irq stuff */
217extern void (*sni_hwint)(void);
218extern struct irqaction sni_isa_irq;
219
104#endif /* __ASM_SNI_H */ 220#endif /* __ASM_SNI_H */