sys_dp264.c 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702
  1. /*
  2. * linux/arch/alpha/kernel/sys_dp264.c
  3. *
  4. * Copyright (C) 1995 David A Rusling
  5. * Copyright (C) 1996, 1999 Jay A Estabrook
  6. * Copyright (C) 1998, 1999 Richard Henderson
  7. *
  8. * Modified by Christopher C. Chimelis, 2001 to
  9. * add support for the addition of Shark to the
  10. * Tsunami family.
  11. *
  12. * Code supporting the DP264 (EV6+TSUNAMI).
  13. */
  14. #include <linux/kernel.h>
  15. #include <linux/types.h>
  16. #include <linux/mm.h>
  17. #include <linux/sched.h>
  18. #include <linux/pci.h>
  19. #include <linux/init.h>
  20. #include <linux/bitops.h>
  21. #include <asm/ptrace.h>
  22. #include <asm/system.h>
  23. #include <asm/dma.h>
  24. #include <asm/irq.h>
  25. #include <asm/mmu_context.h>
  26. #include <asm/io.h>
  27. #include <asm/pgtable.h>
  28. #include <asm/core_tsunami.h>
  29. #include <asm/hwrpb.h>
  30. #include <asm/tlbflush.h>
  31. #include "proto.h"
  32. #include "irq_impl.h"
  33. #include "pci_impl.h"
  34. #include "machvec_impl.h"
  35. /* Note mask bit is true for ENABLED irqs. */
  36. static unsigned long cached_irq_mask;
  37. /* dp264 boards handle at max four CPUs */
  38. static unsigned long cpu_irq_affinity[4] = { 0UL, 0UL, 0UL, 0UL };
  39. DEFINE_SPINLOCK(dp264_irq_lock);
  40. static void
  41. tsunami_update_irq_hw(unsigned long mask)
  42. {
  43. register tsunami_cchip *cchip = TSUNAMI_cchip;
  44. unsigned long isa_enable = 1UL << 55;
  45. register int bcpu = boot_cpuid;
  46. #ifdef CONFIG_SMP
  47. volatile unsigned long *dim0, *dim1, *dim2, *dim3;
  48. unsigned long mask0, mask1, mask2, mask3, dummy;
  49. mask &= ~isa_enable;
  50. mask0 = mask & cpu_irq_affinity[0];
  51. mask1 = mask & cpu_irq_affinity[1];
  52. mask2 = mask & cpu_irq_affinity[2];
  53. mask3 = mask & cpu_irq_affinity[3];
  54. if (bcpu == 0) mask0 |= isa_enable;
  55. else if (bcpu == 1) mask1 |= isa_enable;
  56. else if (bcpu == 2) mask2 |= isa_enable;
  57. else mask3 |= isa_enable;
  58. dim0 = &cchip->dim0.csr;
  59. dim1 = &cchip->dim1.csr;
  60. dim2 = &cchip->dim2.csr;
  61. dim3 = &cchip->dim3.csr;
  62. if (!cpu_possible(0)) dim0 = &dummy;
  63. if (!cpu_possible(1)) dim1 = &dummy;
  64. if (!cpu_possible(2)) dim2 = &dummy;
  65. if (!cpu_possible(3)) dim3 = &dummy;
  66. *dim0 = mask0;
  67. *dim1 = mask1;
  68. *dim2 = mask2;
  69. *dim3 = mask3;
  70. mb();
  71. *dim0;
  72. *dim1;
  73. *dim2;
  74. *dim3;
  75. #else
  76. volatile unsigned long *dimB;
  77. if (bcpu == 0) dimB = &cchip->dim0.csr;
  78. else if (bcpu == 1) dimB = &cchip->dim1.csr;
  79. else if (bcpu == 2) dimB = &cchip->dim2.csr;
  80. else dimB = &cchip->dim3.csr;
  81. *dimB = mask | isa_enable;
  82. mb();
  83. *dimB;
  84. #endif
  85. }
  86. static void
  87. dp264_enable_irq(unsigned int irq)
  88. {
  89. spin_lock(&dp264_irq_lock);
  90. cached_irq_mask |= 1UL << irq;
  91. tsunami_update_irq_hw(cached_irq_mask);
  92. spin_unlock(&dp264_irq_lock);
  93. }
  94. static void
  95. dp264_disable_irq(unsigned int irq)
  96. {
  97. spin_lock(&dp264_irq_lock);
  98. cached_irq_mask &= ~(1UL << irq);
  99. tsunami_update_irq_hw(cached_irq_mask);
  100. spin_unlock(&dp264_irq_lock);
  101. }
  102. static unsigned int
  103. dp264_startup_irq(unsigned int irq)
  104. {
  105. dp264_enable_irq(irq);
  106. return 0; /* never anything pending */
  107. }
  108. static void
  109. dp264_end_irq(unsigned int irq)
  110. {
  111. if (!(irq_desc[irq].status & (IRQ_DISABLED|IRQ_INPROGRESS)))
  112. dp264_enable_irq(irq);
  113. }
  114. static void
  115. clipper_enable_irq(unsigned int irq)
  116. {
  117. spin_lock(&dp264_irq_lock);
  118. cached_irq_mask |= 1UL << (irq - 16);
  119. tsunami_update_irq_hw(cached_irq_mask);
  120. spin_unlock(&dp264_irq_lock);
  121. }
  122. static void
  123. clipper_disable_irq(unsigned int irq)
  124. {
  125. spin_lock(&dp264_irq_lock);
  126. cached_irq_mask &= ~(1UL << (irq - 16));
  127. tsunami_update_irq_hw(cached_irq_mask);
  128. spin_unlock(&dp264_irq_lock);
  129. }
  130. static unsigned int
  131. clipper_startup_irq(unsigned int irq)
  132. {
  133. clipper_enable_irq(irq);
  134. return 0; /* never anything pending */
  135. }
  136. static void
  137. clipper_end_irq(unsigned int irq)
  138. {
  139. if (!(irq_desc[irq].status & (IRQ_DISABLED|IRQ_INPROGRESS)))
  140. clipper_enable_irq(irq);
  141. }
  142. static void
  143. cpu_set_irq_affinity(unsigned int irq, cpumask_t affinity)
  144. {
  145. int cpu;
  146. for (cpu = 0; cpu < 4; cpu++) {
  147. unsigned long aff = cpu_irq_affinity[cpu];
  148. if (cpu_isset(cpu, affinity))
  149. aff |= 1UL << irq;
  150. else
  151. aff &= ~(1UL << irq);
  152. cpu_irq_affinity[cpu] = aff;
  153. }
  154. }
  155. static void
  156. dp264_set_affinity(unsigned int irq, const struct cpumask *affinity)
  157. {
  158. spin_lock(&dp264_irq_lock);
  159. cpu_set_irq_affinity(irq, *affinity);
  160. tsunami_update_irq_hw(cached_irq_mask);
  161. spin_unlock(&dp264_irq_lock);
  162. }
  163. static void
  164. clipper_set_affinity(unsigned int irq, const struct cpumask *affinity)
  165. {
  166. spin_lock(&dp264_irq_lock);
  167. cpu_set_irq_affinity(irq - 16, *affinity);
  168. tsunami_update_irq_hw(cached_irq_mask);
  169. spin_unlock(&dp264_irq_lock);
  170. }
  171. static struct hw_interrupt_type dp264_irq_type = {
  172. .typename = "DP264",
  173. .startup = dp264_startup_irq,
  174. .shutdown = dp264_disable_irq,
  175. .enable = dp264_enable_irq,
  176. .disable = dp264_disable_irq,
  177. .ack = dp264_disable_irq,
  178. .end = dp264_end_irq,
  179. .set_affinity = dp264_set_affinity,
  180. };
  181. static struct hw_interrupt_type clipper_irq_type = {
  182. .typename = "CLIPPER",
  183. .startup = clipper_startup_irq,
  184. .shutdown = clipper_disable_irq,
  185. .enable = clipper_enable_irq,
  186. .disable = clipper_disable_irq,
  187. .ack = clipper_disable_irq,
  188. .end = clipper_end_irq,
  189. .set_affinity = clipper_set_affinity,
  190. };
  191. static void
  192. dp264_device_interrupt(unsigned long vector)
  193. {
  194. #if 1
  195. printk("dp264_device_interrupt: NOT IMPLEMENTED YET!! \n");
  196. #else
  197. unsigned long pld;
  198. unsigned int i;
  199. /* Read the interrupt summary register of TSUNAMI */
  200. pld = TSUNAMI_cchip->dir0.csr;
  201. /*
  202. * Now for every possible bit set, work through them and call
  203. * the appropriate interrupt handler.
  204. */
  205. while (pld) {
  206. i = ffz(~pld);
  207. pld &= pld - 1; /* clear least bit set */
  208. if (i == 55)
  209. isa_device_interrupt(vector);
  210. else
  211. handle_irq(16 + i);
  212. #if 0
  213. TSUNAMI_cchip->dir0.csr = 1UL << i; mb();
  214. tmp = TSUNAMI_cchip->dir0.csr;
  215. #endif
  216. }
  217. #endif
  218. }
  219. static void
  220. dp264_srm_device_interrupt(unsigned long vector)
  221. {
  222. int irq;
  223. irq = (vector - 0x800) >> 4;
  224. /*
  225. * The SRM console reports PCI interrupts with a vector calculated by:
  226. *
  227. * 0x900 + (0x10 * DRIR-bit)
  228. *
  229. * So bit 16 shows up as IRQ 32, etc.
  230. *
  231. * On DP264/BRICK/MONET, we adjust it down by 16 because at least
  232. * that many of the low order bits of the DRIR are not used, and
  233. * so we don't count them.
  234. */
  235. if (irq >= 32)
  236. irq -= 16;
  237. handle_irq(irq);
  238. }
  239. static void
  240. clipper_srm_device_interrupt(unsigned long vector)
  241. {
  242. int irq;
  243. irq = (vector - 0x800) >> 4;
  244. /*
  245. * The SRM console reports PCI interrupts with a vector calculated by:
  246. *
  247. * 0x900 + (0x10 * DRIR-bit)
  248. *
  249. * So bit 16 shows up as IRQ 32, etc.
  250. *
  251. * CLIPPER uses bits 8-47 for PCI interrupts, so we do not need
  252. * to scale down the vector reported, we just use it.
  253. *
  254. * Eg IRQ 24 is DRIR bit 8, etc, etc
  255. */
  256. handle_irq(irq);
  257. }
  258. static void __init
  259. init_tsunami_irqs(struct hw_interrupt_type * ops, int imin, int imax)
  260. {
  261. long i;
  262. for (i = imin; i <= imax; ++i) {
  263. irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
  264. irq_desc[i].chip = ops;
  265. }
  266. }
  267. static void __init
  268. dp264_init_irq(void)
  269. {
  270. outb(0, DMA1_RESET_REG);
  271. outb(0, DMA2_RESET_REG);
  272. outb(DMA_MODE_CASCADE, DMA2_MODE_REG);
  273. outb(0, DMA2_MASK_REG);
  274. if (alpha_using_srm)
  275. alpha_mv.device_interrupt = dp264_srm_device_interrupt;
  276. tsunami_update_irq_hw(0);
  277. init_i8259a_irqs();
  278. init_tsunami_irqs(&dp264_irq_type, 16, 47);
  279. }
  280. static void __init
  281. clipper_init_irq(void)
  282. {
  283. outb(0, DMA1_RESET_REG);
  284. outb(0, DMA2_RESET_REG);
  285. outb(DMA_MODE_CASCADE, DMA2_MODE_REG);
  286. outb(0, DMA2_MASK_REG);
  287. if (alpha_using_srm)
  288. alpha_mv.device_interrupt = clipper_srm_device_interrupt;
  289. tsunami_update_irq_hw(0);
  290. init_i8259a_irqs();
  291. init_tsunami_irqs(&clipper_irq_type, 24, 63);
  292. }
  293. /*
  294. * PCI Fixup configuration.
  295. *
  296. * Summary @ TSUNAMI_CSR_DIM0:
  297. * Bit Meaning
  298. * 0-17 Unused
  299. *18 Interrupt SCSI B (Adaptec 7895 builtin)
  300. *19 Interrupt SCSI A (Adaptec 7895 builtin)
  301. *20 Interrupt Line D from slot 2 PCI0
  302. *21 Interrupt Line C from slot 2 PCI0
  303. *22 Interrupt Line B from slot 2 PCI0
  304. *23 Interrupt Line A from slot 2 PCI0
  305. *24 Interrupt Line D from slot 1 PCI0
  306. *25 Interrupt Line C from slot 1 PCI0
  307. *26 Interrupt Line B from slot 1 PCI0
  308. *27 Interrupt Line A from slot 1 PCI0
  309. *28 Interrupt Line D from slot 0 PCI0
  310. *29 Interrupt Line C from slot 0 PCI0
  311. *30 Interrupt Line B from slot 0 PCI0
  312. *31 Interrupt Line A from slot 0 PCI0
  313. *
  314. *32 Interrupt Line D from slot 3 PCI1
  315. *33 Interrupt Line C from slot 3 PCI1
  316. *34 Interrupt Line B from slot 3 PCI1
  317. *35 Interrupt Line A from slot 3 PCI1
  318. *36 Interrupt Line D from slot 2 PCI1
  319. *37 Interrupt Line C from slot 2 PCI1
  320. *38 Interrupt Line B from slot 2 PCI1
  321. *39 Interrupt Line A from slot 2 PCI1
  322. *40 Interrupt Line D from slot 1 PCI1
  323. *41 Interrupt Line C from slot 1 PCI1
  324. *42 Interrupt Line B from slot 1 PCI1
  325. *43 Interrupt Line A from slot 1 PCI1
  326. *44 Interrupt Line D from slot 0 PCI1
  327. *45 Interrupt Line C from slot 0 PCI1
  328. *46 Interrupt Line B from slot 0 PCI1
  329. *47 Interrupt Line A from slot 0 PCI1
  330. *48-52 Unused
  331. *53 PCI0 NMI (from Cypress)
  332. *54 PCI0 SMI INT (from Cypress)
  333. *55 PCI0 ISA Interrupt (from Cypress)
  334. *56-60 Unused
  335. *61 PCI1 Bus Error
  336. *62 PCI0 Bus Error
  337. *63 Reserved
  338. *
  339. * IdSel
  340. * 5 Cypress Bridge I/O
  341. * 6 SCSI Adaptec builtin
  342. * 7 64 bit PCI option slot 0 (all busses)
  343. * 8 64 bit PCI option slot 1 (all busses)
  344. * 9 64 bit PCI option slot 2 (all busses)
  345. * 10 64 bit PCI option slot 3 (not bus 0)
  346. */
  347. static int __init
  348. isa_irq_fixup(struct pci_dev *dev, int irq)
  349. {
  350. u8 irq8;
  351. if (irq > 0)
  352. return irq;
  353. /* This interrupt is routed via ISA bridge, so we'll
  354. just have to trust whatever value the console might
  355. have assigned. */
  356. pci_read_config_byte(dev, PCI_INTERRUPT_LINE, &irq8);
  357. return irq8 & 0xf;
  358. }
  359. static int __init
  360. dp264_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
  361. {
  362. static char irq_tab[6][5] __initdata = {
  363. /*INT INTA INTB INTC INTD */
  364. { -1, -1, -1, -1, -1}, /* IdSel 5 ISA Bridge */
  365. { 16+ 3, 16+ 3, 16+ 2, 16+ 2, 16+ 2}, /* IdSel 6 SCSI builtin*/
  366. { 16+15, 16+15, 16+14, 16+13, 16+12}, /* IdSel 7 slot 0 */
  367. { 16+11, 16+11, 16+10, 16+ 9, 16+ 8}, /* IdSel 8 slot 1 */
  368. { 16+ 7, 16+ 7, 16+ 6, 16+ 5, 16+ 4}, /* IdSel 9 slot 2 */
  369. { 16+ 3, 16+ 3, 16+ 2, 16+ 1, 16+ 0} /* IdSel 10 slot 3 */
  370. };
  371. const long min_idsel = 5, max_idsel = 10, irqs_per_slot = 5;
  372. struct pci_controller *hose = dev->sysdata;
  373. int irq = COMMON_TABLE_LOOKUP;
  374. if (irq > 0)
  375. irq += 16 * hose->index;
  376. return isa_irq_fixup(dev, irq);
  377. }
  378. static int __init
  379. monet_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
  380. {
  381. static char irq_tab[13][5] __initdata = {
  382. /*INT INTA INTB INTC INTD */
  383. { 45, 45, 45, 45, 45}, /* IdSel 3 21143 PCI1 */
  384. { -1, -1, -1, -1, -1}, /* IdSel 4 unused */
  385. { -1, -1, -1, -1, -1}, /* IdSel 5 unused */
  386. { 47, 47, 47, 47, 47}, /* IdSel 6 SCSI PCI1 */
  387. { -1, -1, -1, -1, -1}, /* IdSel 7 ISA Bridge */
  388. { -1, -1, -1, -1, -1}, /* IdSel 8 P2P PCI1 */
  389. #if 1
  390. { 28, 28, 29, 30, 31}, /* IdSel 14 slot 4 PCI2*/
  391. { 24, 24, 25, 26, 27}, /* IdSel 15 slot 5 PCI2*/
  392. #else
  393. { -1, -1, -1, -1, -1}, /* IdSel 9 unused */
  394. { -1, -1, -1, -1, -1}, /* IdSel 10 unused */
  395. #endif
  396. { 40, 40, 41, 42, 43}, /* IdSel 11 slot 1 PCI0*/
  397. { 36, 36, 37, 38, 39}, /* IdSel 12 slot 2 PCI0*/
  398. { 32, 32, 33, 34, 35}, /* IdSel 13 slot 3 PCI0*/
  399. { 28, 28, 29, 30, 31}, /* IdSel 14 slot 4 PCI2*/
  400. { 24, 24, 25, 26, 27} /* IdSel 15 slot 5 PCI2*/
  401. };
  402. const long min_idsel = 3, max_idsel = 15, irqs_per_slot = 5;
  403. return isa_irq_fixup(dev, COMMON_TABLE_LOOKUP);
  404. }
  405. static u8 __init
  406. monet_swizzle(struct pci_dev *dev, u8 *pinp)
  407. {
  408. struct pci_controller *hose = dev->sysdata;
  409. int slot, pin = *pinp;
  410. if (!dev->bus->parent) {
  411. slot = PCI_SLOT(dev->devfn);
  412. }
  413. /* Check for the built-in bridge on hose 1. */
  414. else if (hose->index == 1 && PCI_SLOT(dev->bus->self->devfn) == 8) {
  415. slot = PCI_SLOT(dev->devfn);
  416. } else {
  417. /* Must be a card-based bridge. */
  418. do {
  419. /* Check for built-in bridge on hose 1. */
  420. if (hose->index == 1 &&
  421. PCI_SLOT(dev->bus->self->devfn) == 8) {
  422. slot = PCI_SLOT(dev->devfn);
  423. break;
  424. }
  425. pin = pci_swizzle_interrupt_pin(dev, pin);
  426. /* Move up the chain of bridges. */
  427. dev = dev->bus->self;
  428. /* Slot of the next bridge. */
  429. slot = PCI_SLOT(dev->devfn);
  430. } while (dev->bus->self);
  431. }
  432. *pinp = pin;
  433. return slot;
  434. }
  435. static int __init
  436. webbrick_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
  437. {
  438. static char irq_tab[13][5] __initdata = {
  439. /*INT INTA INTB INTC INTD */
  440. { -1, -1, -1, -1, -1}, /* IdSel 7 ISA Bridge */
  441. { -1, -1, -1, -1, -1}, /* IdSel 8 unused */
  442. { 29, 29, 29, 29, 29}, /* IdSel 9 21143 #1 */
  443. { -1, -1, -1, -1, -1}, /* IdSel 10 unused */
  444. { 30, 30, 30, 30, 30}, /* IdSel 11 21143 #2 */
  445. { -1, -1, -1, -1, -1}, /* IdSel 12 unused */
  446. { -1, -1, -1, -1, -1}, /* IdSel 13 unused */
  447. { 35, 35, 34, 33, 32}, /* IdSel 14 slot 0 */
  448. { 39, 39, 38, 37, 36}, /* IdSel 15 slot 1 */
  449. { 43, 43, 42, 41, 40}, /* IdSel 16 slot 2 */
  450. { 47, 47, 46, 45, 44}, /* IdSel 17 slot 3 */
  451. };
  452. const long min_idsel = 7, max_idsel = 17, irqs_per_slot = 5;
  453. return isa_irq_fixup(dev, COMMON_TABLE_LOOKUP);
  454. }
  455. static int __init
  456. clipper_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
  457. {
  458. static char irq_tab[7][5] __initdata = {
  459. /*INT INTA INTB INTC INTD */
  460. { 16+ 8, 16+ 8, 16+ 9, 16+10, 16+11}, /* IdSel 1 slot 1 */
  461. { 16+12, 16+12, 16+13, 16+14, 16+15}, /* IdSel 2 slot 2 */
  462. { 16+16, 16+16, 16+17, 16+18, 16+19}, /* IdSel 3 slot 3 */
  463. { 16+20, 16+20, 16+21, 16+22, 16+23}, /* IdSel 4 slot 4 */
  464. { 16+24, 16+24, 16+25, 16+26, 16+27}, /* IdSel 5 slot 5 */
  465. { 16+28, 16+28, 16+29, 16+30, 16+31}, /* IdSel 6 slot 6 */
  466. { -1, -1, -1, -1, -1} /* IdSel 7 ISA Bridge */
  467. };
  468. const long min_idsel = 1, max_idsel = 7, irqs_per_slot = 5;
  469. struct pci_controller *hose = dev->sysdata;
  470. int irq = COMMON_TABLE_LOOKUP;
  471. if (irq > 0)
  472. irq += 16 * hose->index;
  473. return isa_irq_fixup(dev, irq);
  474. }
  475. static void __init
  476. dp264_init_pci(void)
  477. {
  478. common_init_pci();
  479. SMC669_Init(0);
  480. locate_and_init_vga(NULL);
  481. }
  482. static void __init
  483. monet_init_pci(void)
  484. {
  485. common_init_pci();
  486. SMC669_Init(1);
  487. es1888_init();
  488. locate_and_init_vga(NULL);
  489. }
  490. static void __init
  491. clipper_init_pci(void)
  492. {
  493. common_init_pci();
  494. locate_and_init_vga(NULL);
  495. }
  496. static void __init
  497. webbrick_init_arch(void)
  498. {
  499. tsunami_init_arch();
  500. /* Tsunami caches 4 PTEs at a time; DS10 has only 1 hose. */
  501. hose_head->sg_isa->align_entry = 4;
  502. hose_head->sg_pci->align_entry = 4;
  503. }
  504. /*
  505. * The System Vectors
  506. */
  507. struct alpha_machine_vector dp264_mv __initmv = {
  508. .vector_name = "DP264",
  509. DO_EV6_MMU,
  510. DO_DEFAULT_RTC,
  511. DO_TSUNAMI_IO,
  512. .machine_check = tsunami_machine_check,
  513. .max_isa_dma_address = ALPHA_MAX_ISA_DMA_ADDRESS,
  514. .min_io_address = DEFAULT_IO_BASE,
  515. .min_mem_address = DEFAULT_MEM_BASE,
  516. .pci_dac_offset = TSUNAMI_DAC_OFFSET,
  517. .nr_irqs = 64,
  518. .device_interrupt = dp264_device_interrupt,
  519. .init_arch = tsunami_init_arch,
  520. .init_irq = dp264_init_irq,
  521. .init_rtc = common_init_rtc,
  522. .init_pci = dp264_init_pci,
  523. .kill_arch = tsunami_kill_arch,
  524. .pci_map_irq = dp264_map_irq,
  525. .pci_swizzle = common_swizzle,
  526. };
  527. ALIAS_MV(dp264)
  528. struct alpha_machine_vector monet_mv __initmv = {
  529. .vector_name = "Monet",
  530. DO_EV6_MMU,
  531. DO_DEFAULT_RTC,
  532. DO_TSUNAMI_IO,
  533. .machine_check = tsunami_machine_check,
  534. .max_isa_dma_address = ALPHA_MAX_ISA_DMA_ADDRESS,
  535. .min_io_address = DEFAULT_IO_BASE,
  536. .min_mem_address = DEFAULT_MEM_BASE,
  537. .pci_dac_offset = TSUNAMI_DAC_OFFSET,
  538. .nr_irqs = 64,
  539. .device_interrupt = dp264_device_interrupt,
  540. .init_arch = tsunami_init_arch,
  541. .init_irq = dp264_init_irq,
  542. .init_rtc = common_init_rtc,
  543. .init_pci = monet_init_pci,
  544. .kill_arch = tsunami_kill_arch,
  545. .pci_map_irq = monet_map_irq,
  546. .pci_swizzle = monet_swizzle,
  547. };
  548. struct alpha_machine_vector webbrick_mv __initmv = {
  549. .vector_name = "Webbrick",
  550. DO_EV6_MMU,
  551. DO_DEFAULT_RTC,
  552. DO_TSUNAMI_IO,
  553. .machine_check = tsunami_machine_check,
  554. .max_isa_dma_address = ALPHA_MAX_ISA_DMA_ADDRESS,
  555. .min_io_address = DEFAULT_IO_BASE,
  556. .min_mem_address = DEFAULT_MEM_BASE,
  557. .pci_dac_offset = TSUNAMI_DAC_OFFSET,
  558. .nr_irqs = 64,
  559. .device_interrupt = dp264_device_interrupt,
  560. .init_arch = webbrick_init_arch,
  561. .init_irq = dp264_init_irq,
  562. .init_rtc = common_init_rtc,
  563. .init_pci = common_init_pci,
  564. .kill_arch = tsunami_kill_arch,
  565. .pci_map_irq = webbrick_map_irq,
  566. .pci_swizzle = common_swizzle,
  567. };
  568. struct alpha_machine_vector clipper_mv __initmv = {
  569. .vector_name = "Clipper",
  570. DO_EV6_MMU,
  571. DO_DEFAULT_RTC,
  572. DO_TSUNAMI_IO,
  573. .machine_check = tsunami_machine_check,
  574. .max_isa_dma_address = ALPHA_MAX_ISA_DMA_ADDRESS,
  575. .min_io_address = DEFAULT_IO_BASE,
  576. .min_mem_address = DEFAULT_MEM_BASE,
  577. .pci_dac_offset = TSUNAMI_DAC_OFFSET,
  578. .nr_irqs = 64,
  579. .device_interrupt = dp264_device_interrupt,
  580. .init_arch = tsunami_init_arch,
  581. .init_irq = clipper_init_irq,
  582. .init_rtc = common_init_rtc,
  583. .init_pci = clipper_init_pci,
  584. .kill_arch = tsunami_kill_arch,
  585. .pci_map_irq = clipper_map_irq,
  586. .pci_swizzle = common_swizzle,
  587. };
  588. /* Sharks strongly resemble Clipper, at least as far
  589. * as interrupt routing, etc, so we're using the
  590. * same functions as Clipper does
  591. */
  592. struct alpha_machine_vector shark_mv __initmv = {
  593. .vector_name = "Shark",
  594. DO_EV6_MMU,
  595. DO_DEFAULT_RTC,
  596. DO_TSUNAMI_IO,
  597. .machine_check = tsunami_machine_check,
  598. .max_isa_dma_address = ALPHA_MAX_ISA_DMA_ADDRESS,
  599. .min_io_address = DEFAULT_IO_BASE,
  600. .min_mem_address = DEFAULT_MEM_BASE,
  601. .pci_dac_offset = TSUNAMI_DAC_OFFSET,
  602. .nr_irqs = 64,
  603. .device_interrupt = dp264_device_interrupt,
  604. .init_arch = tsunami_init_arch,
  605. .init_irq = clipper_init_irq,
  606. .init_rtc = common_init_rtc,
  607. .init_pci = common_init_pci,
  608. .kill_arch = tsunami_kill_arch,
  609. .pci_map_irq = clipper_map_irq,
  610. .pci_swizzle = common_swizzle,
  611. };
  612. /* No alpha_mv alias for webbrick/monet/clipper, since we compile them
  613. in unconditionally with DP264; setup_arch knows how to cope. */