Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | /* |
| 2 | * linux/arch/m68k/mac/config.c |
| 3 | * |
| 4 | * This file is subject to the terms and conditions of the GNU General Public |
| 5 | * License. See the file COPYING in the main directory of this archive |
| 6 | * for more details. |
| 7 | */ |
| 8 | |
| 9 | /* |
| 10 | * Miscellaneous linux stuff |
| 11 | */ |
| 12 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 13 | #include <linux/module.h> |
| 14 | #include <linux/types.h> |
| 15 | #include <linux/mm.h> |
| 16 | #include <linux/tty.h> |
| 17 | #include <linux/console.h> |
| 18 | #include <linux/interrupt.h> |
| 19 | /* keyb */ |
| 20 | #include <linux/random.h> |
| 21 | #include <linux/delay.h> |
| 22 | /* keyb */ |
| 23 | #include <linux/init.h> |
| 24 | #include <linux/vt_kern.h> |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 25 | #include <linux/platform_device.h> |
Finn Thain | 18814ee | 2009-11-17 20:03:05 +1100 | [diff] [blame] | 26 | #include <linux/adb.h> |
| 27 | #include <linux/cuda.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 28 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 29 | #include <asm/setup.h> |
| 30 | #include <asm/bootinfo.h> |
Geert Uytterhoeven | 4c3c522 | 2013-10-02 11:37:33 +0200 | [diff] [blame] | 31 | #include <asm/bootinfo-mac.h> |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 32 | #include <asm/byteorder.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 33 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 34 | #include <asm/io.h> |
| 35 | #include <asm/irq.h> |
| 36 | #include <asm/pgtable.h> |
| 37 | #include <asm/rtc.h> |
| 38 | #include <asm/machdep.h> |
| 39 | |
| 40 | #include <asm/macintosh.h> |
| 41 | #include <asm/macints.h> |
| 42 | #include <asm/machw.h> |
| 43 | |
| 44 | #include <asm/mac_iop.h> |
| 45 | #include <asm/mac_via.h> |
| 46 | #include <asm/mac_oss.h> |
| 47 | #include <asm/mac_psc.h> |
| 48 | |
| 49 | /* Mac bootinfo struct */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 50 | struct mac_booter_data mac_bi_data; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 51 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 52 | /* The phys. video addr. - might be bogus on some machines */ |
Adrian Bunk | 8dfbdf4 | 2008-07-17 21:16:25 +0200 | [diff] [blame] | 53 | static unsigned long mac_orig_videoaddr; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 54 | |
| 55 | /* Mac specific timer functions */ |
Stephen Warren | c8d5ba1 | 2012-11-08 11:34:55 -0700 | [diff] [blame] | 56 | extern u32 mac_gettimeoffset(void); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 57 | extern int mac_hwclk(int, struct rtc_time *); |
| 58 | extern int mac_set_clock_mmss(unsigned long); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 59 | extern void iop_preinit(void); |
| 60 | extern void iop_init(void); |
| 61 | extern void via_init(void); |
David Howells | 40220c1 | 2006-10-09 12:19:47 +0100 | [diff] [blame] | 62 | extern void via_init_clock(irq_handler_t func); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 63 | extern void via_flush_cache(void); |
| 64 | extern void oss_init(void); |
| 65 | extern void psc_init(void); |
| 66 | extern void baboon_init(void); |
| 67 | |
| 68 | extern void mac_mksound(unsigned int, unsigned int); |
| 69 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 70 | static void mac_get_model(char *str); |
Adrian Bunk | 8dfbdf4 | 2008-07-17 21:16:25 +0200 | [diff] [blame] | 71 | static void mac_identify(void); |
| 72 | static void mac_report_hardware(void); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 73 | |
Al Viro | 66a3f82 | 2007-07-20 04:33:28 +0100 | [diff] [blame] | 74 | static void __init mac_sched_init(irq_handler_t vector) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 75 | { |
| 76 | via_init_clock(vector); |
| 77 | } |
| 78 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 79 | /* |
| 80 | * Parse a Macintosh-specific record in the bootinfo |
| 81 | */ |
| 82 | |
| 83 | int __init mac_parse_bootinfo(const struct bi_record *record) |
| 84 | { |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 85 | int unknown = 0; |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 86 | const void *data = record->data; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 87 | |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 88 | switch (be16_to_cpu(record->tag)) { |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 89 | case BI_MAC_MODEL: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 90 | mac_bi_data.id = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 91 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 92 | case BI_MAC_VADDR: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 93 | mac_bi_data.videoaddr = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 94 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 95 | case BI_MAC_VDEPTH: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 96 | mac_bi_data.videodepth = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 97 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 98 | case BI_MAC_VROW: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 99 | mac_bi_data.videorow = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 100 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 101 | case BI_MAC_VDIM: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 102 | mac_bi_data.dimensions = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 103 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 104 | case BI_MAC_VLOGICAL: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 105 | mac_orig_videoaddr = be32_to_cpup(data); |
| 106 | mac_bi_data.videological = |
| 107 | VIDEOMEMBASE + (mac_orig_videoaddr & ~VIDEOMEMMASK); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 108 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 109 | case BI_MAC_SCCBASE: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 110 | mac_bi_data.sccbase = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 111 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 112 | case BI_MAC_BTIME: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 113 | mac_bi_data.boottime = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 114 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 115 | case BI_MAC_GMTBIAS: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 116 | mac_bi_data.gmtbias = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 117 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 118 | case BI_MAC_MEMSIZE: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 119 | mac_bi_data.memsize = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 120 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 121 | case BI_MAC_CPUID: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 122 | mac_bi_data.cpuid = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 123 | break; |
| 124 | case BI_MAC_ROMBASE: |
Geert Uytterhoeven | abe4810 | 2013-10-04 11:41:24 +0200 | [diff] [blame] | 125 | mac_bi_data.rombase = be32_to_cpup(data); |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 126 | break; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 127 | default: |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 128 | unknown = 1; |
| 129 | break; |
| 130 | } |
| 131 | return unknown; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 132 | } |
| 133 | |
| 134 | /* |
| 135 | * Flip into 24bit mode for an instant - flushes the L2 cache card. We |
| 136 | * have to disable interrupts for this. Our IRQ handlers will crap |
| 137 | * themselves if they take an IRQ in 24bit mode! |
| 138 | */ |
| 139 | |
| 140 | static void mac_cache_card_flush(int writeback) |
| 141 | { |
| 142 | unsigned long flags; |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 143 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 144 | local_irq_save(flags); |
| 145 | via_flush_cache(); |
| 146 | local_irq_restore(flags); |
| 147 | } |
| 148 | |
| 149 | void __init config_mac(void) |
| 150 | { |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 151 | if (!MACH_IS_MAC) |
Frans Pop | b9b0d8b | 2010-02-06 18:47:11 +0100 | [diff] [blame] | 152 | printk(KERN_ERR "ERROR: no Mac, but config_mac() called!!\n"); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 153 | |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 154 | mach_sched_init = mac_sched_init; |
| 155 | mach_init_IRQ = mac_init_IRQ; |
| 156 | mach_get_model = mac_get_model; |
Stephen Warren | c8d5ba1 | 2012-11-08 11:34:55 -0700 | [diff] [blame] | 157 | arch_gettimeoffset = mac_gettimeoffset; |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 158 | mach_hwclk = mac_hwclk; |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 159 | mach_set_clock_mmss = mac_set_clock_mmss; |
| 160 | mach_reset = mac_reset; |
| 161 | mach_halt = mac_poweroff; |
| 162 | mach_power_off = mac_poweroff; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 163 | mach_max_dma_address = 0xffffffff; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 164 | #if defined(CONFIG_INPUT_M68K_BEEP) || defined(CONFIG_INPUT_M68K_BEEP_MODULE) |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 165 | mach_beep = mac_mksound; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 166 | #endif |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 167 | |
| 168 | /* |
| 169 | * Determine hardware present |
| 170 | */ |
| 171 | |
| 172 | mac_identify(); |
| 173 | mac_report_hardware(); |
| 174 | |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 175 | /* |
| 176 | * AFAIK only the IIci takes a cache card. The IIfx has onboard |
| 177 | * cache ... someone needs to figure out how to tell if it's on or |
| 178 | * not. |
| 179 | */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 180 | |
| 181 | if (macintosh_config->ident == MAC_MODEL_IICI |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 182 | || macintosh_config->ident == MAC_MODEL_IIFX) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 183 | mach_l2_flush = mac_cache_card_flush; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 184 | } |
| 185 | |
| 186 | |
| 187 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 188 | * Macintosh Table: hardcoded model configuration data. |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 189 | * |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 190 | * Much of this was defined by Alan, based on who knows what docs. |
| 191 | * I've added a lot more, and some of that was pure guesswork based |
| 192 | * on hardware pages present on the Mac web site. Possibly wildly |
| 193 | * inaccurate, so look here if a new Mac model won't run. Example: if |
| 194 | * a Mac crashes immediately after the VIA1 registers have been dumped |
| 195 | * to the screen, it probably died attempting to read DirB on a RBV. |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 196 | * Meaning it should have MAC_VIA_IICI here :-) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 197 | */ |
| 198 | |
| 199 | struct mac_model *macintosh_config; |
| 200 | EXPORT_SYMBOL(macintosh_config); |
| 201 | |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 202 | static struct mac_model mac_data_table[] = { |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 203 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 204 | * We'll pretend to be a Macintosh II, that's pretty safe. |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 205 | */ |
| 206 | |
| 207 | { |
| 208 | .ident = MAC_MODEL_II, |
| 209 | .name = "Unknown", |
| 210 | .adb_type = MAC_ADB_II, |
| 211 | .via_type = MAC_VIA_II, |
| 212 | .scsi_type = MAC_SCSI_OLD, |
| 213 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 214 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 215 | .floppy_type = MAC_FLOPPY_IWM, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 216 | }, |
| 217 | |
| 218 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 219 | * Original Mac II hardware |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 220 | */ |
| 221 | |
| 222 | { |
| 223 | .ident = MAC_MODEL_II, |
| 224 | .name = "II", |
| 225 | .adb_type = MAC_ADB_II, |
| 226 | .via_type = MAC_VIA_II, |
| 227 | .scsi_type = MAC_SCSI_OLD, |
| 228 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 229 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 230 | .floppy_type = MAC_FLOPPY_IWM, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 231 | }, { |
| 232 | .ident = MAC_MODEL_IIX, |
| 233 | .name = "IIx", |
| 234 | .adb_type = MAC_ADB_II, |
| 235 | .via_type = MAC_VIA_II, |
| 236 | .scsi_type = MAC_SCSI_OLD, |
| 237 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 238 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 239 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 240 | }, { |
| 241 | .ident = MAC_MODEL_IICX, |
| 242 | .name = "IIcx", |
| 243 | .adb_type = MAC_ADB_II, |
| 244 | .via_type = MAC_VIA_II, |
| 245 | .scsi_type = MAC_SCSI_OLD, |
| 246 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 247 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 248 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 249 | }, { |
| 250 | .ident = MAC_MODEL_SE30, |
| 251 | .name = "SE/30", |
| 252 | .adb_type = MAC_ADB_II, |
| 253 | .via_type = MAC_VIA_II, |
| 254 | .scsi_type = MAC_SCSI_OLD, |
| 255 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 256 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 257 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 258 | }, |
| 259 | |
| 260 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 261 | * Weirdified Mac II hardware - all subtly different. Gee thanks |
| 262 | * Apple. All these boxes seem to have VIA2 in a different place to |
| 263 | * the Mac II (+1A000 rather than +4000) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 264 | * CSA: see http://developer.apple.com/technotes/hw/hw_09.html |
| 265 | */ |
| 266 | |
| 267 | { |
| 268 | .ident = MAC_MODEL_IICI, |
| 269 | .name = "IIci", |
| 270 | .adb_type = MAC_ADB_II, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 271 | .via_type = MAC_VIA_IICI, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 272 | .scsi_type = MAC_SCSI_OLD, |
| 273 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 274 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 275 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 276 | }, { |
| 277 | .ident = MAC_MODEL_IIFX, |
| 278 | .name = "IIfx", |
| 279 | .adb_type = MAC_ADB_IOP, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 280 | .via_type = MAC_VIA_IICI, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 281 | .scsi_type = MAC_SCSI_IIFX, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 282 | .scc_type = MAC_SCC_IOP, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 283 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 284 | .floppy_type = MAC_FLOPPY_SWIM_IOP, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 285 | }, { |
| 286 | .ident = MAC_MODEL_IISI, |
| 287 | .name = "IIsi", |
| 288 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 289 | .via_type = MAC_VIA_IICI, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 290 | .scsi_type = MAC_SCSI_OLD, |
| 291 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 292 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 293 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 294 | }, { |
| 295 | .ident = MAC_MODEL_IIVI, |
| 296 | .name = "IIvi", |
| 297 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 298 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 299 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 300 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 301 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 302 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 303 | }, { |
| 304 | .ident = MAC_MODEL_IIVX, |
| 305 | .name = "IIvx", |
| 306 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 307 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 308 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 309 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 310 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 311 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 312 | }, |
| 313 | |
| 314 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 315 | * Classic models (guessing: similar to SE/30? Nope, similar to LC...) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 316 | */ |
| 317 | |
| 318 | { |
| 319 | .ident = MAC_MODEL_CLII, |
| 320 | .name = "Classic II", |
| 321 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 322 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 323 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 324 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 325 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 326 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 327 | }, { |
| 328 | .ident = MAC_MODEL_CCL, |
| 329 | .name = "Color Classic", |
| 330 | .adb_type = MAC_ADB_CUDA, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 331 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 332 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 333 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 334 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 335 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Finn Thain | 1b46010 | 2010-05-29 03:27:18 +1000 | [diff] [blame] | 336 | }, { |
| 337 | .ident = MAC_MODEL_CCLII, |
| 338 | .name = "Color Classic II", |
| 339 | .adb_type = MAC_ADB_CUDA, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 340 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 341 | .scsi_type = MAC_SCSI_LC, |
Finn Thain | 1b46010 | 2010-05-29 03:27:18 +1000 | [diff] [blame] | 342 | .scc_type = MAC_SCC_II, |
| 343 | .nubus_type = MAC_NUBUS, |
| 344 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 345 | }, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 346 | |
| 347 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 348 | * Some Mac LC machines. Basically the same as the IIci, ADB like IIsi |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 349 | */ |
| 350 | |
| 351 | { |
| 352 | .ident = MAC_MODEL_LC, |
| 353 | .name = "LC", |
| 354 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 355 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 356 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 357 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 358 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 359 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 360 | }, { |
| 361 | .ident = MAC_MODEL_LCII, |
| 362 | .name = "LC II", |
| 363 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 364 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 365 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 366 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 367 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 368 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 369 | }, { |
| 370 | .ident = MAC_MODEL_LCIII, |
| 371 | .name = "LC III", |
| 372 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 373 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 374 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 375 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 376 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 377 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 378 | }, |
| 379 | |
| 380 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 381 | * Quadra. Video is at 0xF9000000, via is like a MacII. We label it |
| 382 | * differently as some of the stuff connected to VIA2 seems different. |
| 383 | * Better SCSI chip and onboard ethernet using a NatSemi SONIC except |
| 384 | * the 660AV and 840AV which use an AMD 79C940 (MACE). |
| 385 | * The 700, 900 and 950 have some I/O chips in the wrong place to |
| 386 | * confuse us. The 840AV has a SCSI location of its own (same as |
| 387 | * the 660AV). |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 388 | */ |
| 389 | |
| 390 | { |
| 391 | .ident = MAC_MODEL_Q605, |
| 392 | .name = "Quadra 605", |
| 393 | .adb_type = MAC_ADB_CUDA, |
| 394 | .via_type = MAC_VIA_QUADRA, |
| 395 | .scsi_type = MAC_SCSI_QUADRA, |
| 396 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 397 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 398 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 399 | }, { |
| 400 | .ident = MAC_MODEL_Q605_ACC, |
| 401 | .name = "Quadra 605", |
| 402 | .adb_type = MAC_ADB_CUDA, |
| 403 | .via_type = MAC_VIA_QUADRA, |
| 404 | .scsi_type = MAC_SCSI_QUADRA, |
| 405 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 406 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 407 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 408 | }, { |
| 409 | .ident = MAC_MODEL_Q610, |
| 410 | .name = "Quadra 610", |
| 411 | .adb_type = MAC_ADB_II, |
| 412 | .via_type = MAC_VIA_QUADRA, |
| 413 | .scsi_type = MAC_SCSI_QUADRA, |
| 414 | .scc_type = MAC_SCC_QUADRA, |
| 415 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 416 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 417 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 418 | }, { |
| 419 | .ident = MAC_MODEL_Q630, |
| 420 | .name = "Quadra 630", |
| 421 | .adb_type = MAC_ADB_CUDA, |
| 422 | .via_type = MAC_VIA_QUADRA, |
| 423 | .scsi_type = MAC_SCSI_QUADRA, |
| 424 | .ide_type = MAC_IDE_QUADRA, |
| 425 | .scc_type = MAC_SCC_QUADRA, |
| 426 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 427 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 428 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 429 | }, { |
| 430 | .ident = MAC_MODEL_Q650, |
| 431 | .name = "Quadra 650", |
| 432 | .adb_type = MAC_ADB_II, |
| 433 | .via_type = MAC_VIA_QUADRA, |
| 434 | .scsi_type = MAC_SCSI_QUADRA, |
| 435 | .scc_type = MAC_SCC_QUADRA, |
| 436 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 437 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 438 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 439 | }, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 440 | /* The Q700 does have a NS Sonic */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 441 | { |
| 442 | .ident = MAC_MODEL_Q700, |
| 443 | .name = "Quadra 700", |
| 444 | .adb_type = MAC_ADB_II, |
| 445 | .via_type = MAC_VIA_QUADRA, |
| 446 | .scsi_type = MAC_SCSI_QUADRA2, |
| 447 | .scc_type = MAC_SCC_QUADRA, |
| 448 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 449 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 450 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 451 | }, { |
| 452 | .ident = MAC_MODEL_Q800, |
| 453 | .name = "Quadra 800", |
| 454 | .adb_type = MAC_ADB_II, |
| 455 | .via_type = MAC_VIA_QUADRA, |
| 456 | .scsi_type = MAC_SCSI_QUADRA, |
| 457 | .scc_type = MAC_SCC_QUADRA, |
| 458 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 459 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 460 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 461 | }, { |
| 462 | .ident = MAC_MODEL_Q840, |
| 463 | .name = "Quadra 840AV", |
| 464 | .adb_type = MAC_ADB_CUDA, |
| 465 | .via_type = MAC_VIA_QUADRA, |
| 466 | .scsi_type = MAC_SCSI_QUADRA3, |
| 467 | .scc_type = MAC_SCC_PSC, |
| 468 | .ether_type = MAC_ETHER_MACE, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 469 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 470 | .floppy_type = MAC_FLOPPY_AV, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 471 | }, { |
| 472 | .ident = MAC_MODEL_Q900, |
| 473 | .name = "Quadra 900", |
| 474 | .adb_type = MAC_ADB_IOP, |
| 475 | .via_type = MAC_VIA_QUADRA, |
| 476 | .scsi_type = MAC_SCSI_QUADRA2, |
| 477 | .scc_type = MAC_SCC_IOP, |
| 478 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 479 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 480 | .floppy_type = MAC_FLOPPY_SWIM_IOP, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 481 | }, { |
| 482 | .ident = MAC_MODEL_Q950, |
| 483 | .name = "Quadra 950", |
| 484 | .adb_type = MAC_ADB_IOP, |
| 485 | .via_type = MAC_VIA_QUADRA, |
| 486 | .scsi_type = MAC_SCSI_QUADRA2, |
| 487 | .scc_type = MAC_SCC_IOP, |
| 488 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 489 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 490 | .floppy_type = MAC_FLOPPY_SWIM_IOP, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 491 | }, |
| 492 | |
| 493 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 494 | * Performa - more LC type machines |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 495 | */ |
| 496 | |
| 497 | { |
| 498 | .ident = MAC_MODEL_P460, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 499 | .name = "Performa 460", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 500 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 501 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 502 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 503 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 504 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 505 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 506 | }, { |
| 507 | .ident = MAC_MODEL_P475, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 508 | .name = "Performa 475", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 509 | .adb_type = MAC_ADB_CUDA, |
| 510 | .via_type = MAC_VIA_QUADRA, |
| 511 | .scsi_type = MAC_SCSI_QUADRA, |
| 512 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 513 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 514 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 515 | }, { |
| 516 | .ident = MAC_MODEL_P475F, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 517 | .name = "Performa 475", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 518 | .adb_type = MAC_ADB_CUDA, |
| 519 | .via_type = MAC_VIA_QUADRA, |
| 520 | .scsi_type = MAC_SCSI_QUADRA, |
| 521 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 522 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 523 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 524 | }, { |
| 525 | .ident = MAC_MODEL_P520, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 526 | .name = "Performa 520", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 527 | .adb_type = MAC_ADB_CUDA, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 528 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 529 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 530 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 531 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 532 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 533 | }, { |
| 534 | .ident = MAC_MODEL_P550, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 535 | .name = "Performa 550", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 536 | .adb_type = MAC_ADB_CUDA, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 537 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 538 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 539 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 540 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 541 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 542 | }, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 543 | /* These have the comm slot, and therefore possibly SONIC ethernet */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 544 | { |
| 545 | .ident = MAC_MODEL_P575, |
| 546 | .name = "Performa 575", |
| 547 | .adb_type = MAC_ADB_CUDA, |
| 548 | .via_type = MAC_VIA_QUADRA, |
| 549 | .scsi_type = MAC_SCSI_QUADRA, |
| 550 | .scc_type = MAC_SCC_II, |
| 551 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 552 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 553 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 554 | }, { |
| 555 | .ident = MAC_MODEL_P588, |
| 556 | .name = "Performa 588", |
| 557 | .adb_type = MAC_ADB_CUDA, |
| 558 | .via_type = MAC_VIA_QUADRA, |
| 559 | .scsi_type = MAC_SCSI_QUADRA, |
| 560 | .ide_type = MAC_IDE_QUADRA, |
| 561 | .scc_type = MAC_SCC_II, |
| 562 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 563 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 564 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 565 | }, { |
| 566 | .ident = MAC_MODEL_TV, |
| 567 | .name = "TV", |
| 568 | .adb_type = MAC_ADB_CUDA, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 569 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 570 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 571 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 572 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 573 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 574 | }, { |
| 575 | .ident = MAC_MODEL_P600, |
| 576 | .name = "Performa 600", |
| 577 | .adb_type = MAC_ADB_IISI, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 578 | .via_type = MAC_VIA_IICI, |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 579 | .scsi_type = MAC_SCSI_LC, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 580 | .scc_type = MAC_SCC_II, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 581 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 582 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 583 | }, |
| 584 | |
| 585 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 586 | * Centris - just guessing again; maybe like Quadra. |
| 587 | * The C610 may or may not have SONIC. We probe to make sure. |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 588 | */ |
| 589 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 590 | { |
| 591 | .ident = MAC_MODEL_C610, |
| 592 | .name = "Centris 610", |
| 593 | .adb_type = MAC_ADB_II, |
| 594 | .via_type = MAC_VIA_QUADRA, |
| 595 | .scsi_type = MAC_SCSI_QUADRA, |
| 596 | .scc_type = MAC_SCC_QUADRA, |
| 597 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 598 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 599 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 600 | }, { |
| 601 | .ident = MAC_MODEL_C650, |
| 602 | .name = "Centris 650", |
| 603 | .adb_type = MAC_ADB_II, |
| 604 | .via_type = MAC_VIA_QUADRA, |
| 605 | .scsi_type = MAC_SCSI_QUADRA, |
| 606 | .scc_type = MAC_SCC_QUADRA, |
| 607 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 608 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 609 | .floppy_type = MAC_FLOPPY_SWIM_ADDR1, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 610 | }, { |
| 611 | .ident = MAC_MODEL_C660, |
| 612 | .name = "Centris 660AV", |
| 613 | .adb_type = MAC_ADB_CUDA, |
| 614 | .via_type = MAC_VIA_QUADRA, |
| 615 | .scsi_type = MAC_SCSI_QUADRA3, |
| 616 | .scc_type = MAC_SCC_PSC, |
| 617 | .ether_type = MAC_ETHER_MACE, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 618 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 619 | .floppy_type = MAC_FLOPPY_AV, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 620 | }, |
| 621 | |
| 622 | /* |
| 623 | * The PowerBooks all the same "Combo" custom IC for SCSI and SCC |
| 624 | * and a PMU (in two variations?) for ADB. Most of them use the |
| 625 | * Quadra-style VIAs. A few models also have IDE from hell. |
| 626 | */ |
| 627 | |
| 628 | { |
| 629 | .ident = MAC_MODEL_PB140, |
| 630 | .name = "PowerBook 140", |
| 631 | .adb_type = MAC_ADB_PB1, |
| 632 | .via_type = MAC_VIA_QUADRA, |
| 633 | .scsi_type = MAC_SCSI_OLD, |
| 634 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 635 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 636 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 637 | }, { |
| 638 | .ident = MAC_MODEL_PB145, |
| 639 | .name = "PowerBook 145", |
| 640 | .adb_type = MAC_ADB_PB1, |
| 641 | .via_type = MAC_VIA_QUADRA, |
| 642 | .scsi_type = MAC_SCSI_OLD, |
| 643 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 644 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 645 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 646 | }, { |
| 647 | .ident = MAC_MODEL_PB150, |
| 648 | .name = "PowerBook 150", |
Finn Thain | 4107c45 | 2011-10-24 01:11:20 +1100 | [diff] [blame] | 649 | .adb_type = MAC_ADB_PB2, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 650 | .via_type = MAC_VIA_IICI, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 651 | .scsi_type = MAC_SCSI_OLD, |
| 652 | .ide_type = MAC_IDE_PB, |
| 653 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 654 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 655 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 656 | }, { |
| 657 | .ident = MAC_MODEL_PB160, |
| 658 | .name = "PowerBook 160", |
| 659 | .adb_type = MAC_ADB_PB1, |
| 660 | .via_type = MAC_VIA_QUADRA, |
| 661 | .scsi_type = MAC_SCSI_OLD, |
| 662 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 663 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 664 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 665 | }, { |
| 666 | .ident = MAC_MODEL_PB165, |
| 667 | .name = "PowerBook 165", |
| 668 | .adb_type = MAC_ADB_PB1, |
| 669 | .via_type = MAC_VIA_QUADRA, |
| 670 | .scsi_type = MAC_SCSI_OLD, |
| 671 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 672 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 673 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 674 | }, { |
| 675 | .ident = MAC_MODEL_PB165C, |
| 676 | .name = "PowerBook 165c", |
| 677 | .adb_type = MAC_ADB_PB1, |
| 678 | .via_type = MAC_VIA_QUADRA, |
| 679 | .scsi_type = MAC_SCSI_OLD, |
| 680 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 681 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 682 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 683 | }, { |
| 684 | .ident = MAC_MODEL_PB170, |
| 685 | .name = "PowerBook 170", |
| 686 | .adb_type = MAC_ADB_PB1, |
| 687 | .via_type = MAC_VIA_QUADRA, |
| 688 | .scsi_type = MAC_SCSI_OLD, |
| 689 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 690 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 691 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 692 | }, { |
| 693 | .ident = MAC_MODEL_PB180, |
| 694 | .name = "PowerBook 180", |
| 695 | .adb_type = MAC_ADB_PB1, |
| 696 | .via_type = MAC_VIA_QUADRA, |
| 697 | .scsi_type = MAC_SCSI_OLD, |
| 698 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 699 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 700 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 701 | }, { |
| 702 | .ident = MAC_MODEL_PB180C, |
| 703 | .name = "PowerBook 180c", |
| 704 | .adb_type = MAC_ADB_PB1, |
| 705 | .via_type = MAC_VIA_QUADRA, |
| 706 | .scsi_type = MAC_SCSI_OLD, |
| 707 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 708 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 709 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 710 | }, { |
| 711 | .ident = MAC_MODEL_PB190, |
| 712 | .name = "PowerBook 190", |
| 713 | .adb_type = MAC_ADB_PB2, |
| 714 | .via_type = MAC_VIA_QUADRA, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 715 | .scsi_type = MAC_SCSI_LATE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 716 | .ide_type = MAC_IDE_BABOON, |
| 717 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 718 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 719 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 720 | }, { |
| 721 | .ident = MAC_MODEL_PB520, |
| 722 | .name = "PowerBook 520", |
| 723 | .adb_type = MAC_ADB_PB2, |
| 724 | .via_type = MAC_VIA_QUADRA, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 725 | .scsi_type = MAC_SCSI_LATE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 726 | .scc_type = MAC_SCC_QUADRA, |
| 727 | .ether_type = MAC_ETHER_SONIC, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 728 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 729 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 730 | }, |
| 731 | |
| 732 | /* |
| 733 | * PowerBook Duos are pretty much like normal PowerBooks |
| 734 | * All of these probably have onboard SONIC in the Dock which |
| 735 | * means we'll have to probe for it eventually. |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 736 | */ |
| 737 | |
| 738 | { |
| 739 | .ident = MAC_MODEL_PB210, |
| 740 | .name = "PowerBook Duo 210", |
| 741 | .adb_type = MAC_ADB_PB2, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 742 | .via_type = MAC_VIA_IICI, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 743 | .scsi_type = MAC_SCSI_DUO, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 744 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 745 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 746 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 747 | }, { |
| 748 | .ident = MAC_MODEL_PB230, |
| 749 | .name = "PowerBook Duo 230", |
| 750 | .adb_type = MAC_ADB_PB2, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 751 | .via_type = MAC_VIA_IICI, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 752 | .scsi_type = MAC_SCSI_DUO, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 753 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 754 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 755 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 756 | }, { |
| 757 | .ident = MAC_MODEL_PB250, |
| 758 | .name = "PowerBook Duo 250", |
| 759 | .adb_type = MAC_ADB_PB2, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 760 | .via_type = MAC_VIA_IICI, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 761 | .scsi_type = MAC_SCSI_DUO, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 762 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 763 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 764 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 765 | }, { |
| 766 | .ident = MAC_MODEL_PB270C, |
| 767 | .name = "PowerBook Duo 270c", |
| 768 | .adb_type = MAC_ADB_PB2, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 769 | .via_type = MAC_VIA_IICI, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 770 | .scsi_type = MAC_SCSI_DUO, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 771 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 772 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 773 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 774 | }, { |
| 775 | .ident = MAC_MODEL_PB280, |
| 776 | .name = "PowerBook Duo 280", |
| 777 | .adb_type = MAC_ADB_PB2, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 778 | .via_type = MAC_VIA_IICI, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 779 | .scsi_type = MAC_SCSI_DUO, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 780 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 781 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 782 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 783 | }, { |
| 784 | .ident = MAC_MODEL_PB280C, |
| 785 | .name = "PowerBook Duo 280c", |
| 786 | .adb_type = MAC_ADB_PB2, |
Finn Thain | 608e287 | 2011-10-24 01:11:22 +1100 | [diff] [blame] | 787 | .via_type = MAC_VIA_IICI, |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 788 | .scsi_type = MAC_SCSI_DUO, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 789 | .scc_type = MAC_SCC_QUADRA, |
Laurent Vivier | 7ad93b4 | 2008-11-06 20:57:41 +0100 | [diff] [blame] | 790 | .nubus_type = MAC_NUBUS, |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 791 | .floppy_type = MAC_FLOPPY_SWIM_ADDR2, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 792 | }, |
| 793 | |
| 794 | /* |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 795 | * Other stuff? |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 796 | */ |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 797 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 798 | { |
| 799 | .ident = -1 |
| 800 | } |
| 801 | }; |
| 802 | |
Finn Thain | 80614e5 | 2009-11-17 20:06:48 +1100 | [diff] [blame] | 803 | static struct resource scc_a_rsrcs[] = { |
| 804 | { .flags = IORESOURCE_MEM }, |
| 805 | { .flags = IORESOURCE_IRQ }, |
| 806 | }; |
| 807 | |
| 808 | static struct resource scc_b_rsrcs[] = { |
| 809 | { .flags = IORESOURCE_MEM }, |
| 810 | { .flags = IORESOURCE_IRQ }, |
| 811 | }; |
| 812 | |
| 813 | struct platform_device scc_a_pdev = { |
| 814 | .name = "scc", |
| 815 | .id = 0, |
| 816 | .num_resources = ARRAY_SIZE(scc_a_rsrcs), |
| 817 | .resource = scc_a_rsrcs, |
| 818 | }; |
| 819 | EXPORT_SYMBOL(scc_a_pdev); |
| 820 | |
| 821 | struct platform_device scc_b_pdev = { |
| 822 | .name = "scc", |
| 823 | .id = 1, |
| 824 | .num_resources = ARRAY_SIZE(scc_b_rsrcs), |
| 825 | .resource = scc_b_rsrcs, |
| 826 | }; |
| 827 | EXPORT_SYMBOL(scc_b_pdev); |
| 828 | |
Adrian Bunk | 8dfbdf4 | 2008-07-17 21:16:25 +0200 | [diff] [blame] | 829 | static void __init mac_identify(void) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 830 | { |
| 831 | struct mac_model *m; |
| 832 | |
| 833 | /* Penguin data useful? */ |
| 834 | int model = mac_bi_data.id; |
| 835 | if (!model) { |
| 836 | /* no bootinfo model id -> NetBSD booter was used! */ |
| 837 | /* XXX FIXME: breaks for model > 31 */ |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 838 | model = (mac_bi_data.cpuid >> 2) & 63; |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 839 | printk(KERN_WARNING "No bootinfo model ID, using cpuid instead " |
| 840 | "(obsolete bootloader?)\n"); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 841 | } |
| 842 | |
| 843 | macintosh_config = mac_data_table; |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 844 | for (m = macintosh_config; m->ident != -1; m++) { |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 845 | if (m->ident == model) { |
| 846 | macintosh_config = m; |
| 847 | break; |
| 848 | } |
| 849 | } |
| 850 | |
Finn Thain | 80614e5 | 2009-11-17 20:06:48 +1100 | [diff] [blame] | 851 | /* Set up serial port resources for the console initcall. */ |
| 852 | |
| 853 | scc_a_rsrcs[0].start = (resource_size_t) mac_bi_data.sccbase + 2; |
| 854 | scc_a_rsrcs[0].end = scc_a_rsrcs[0].start; |
| 855 | scc_b_rsrcs[0].start = (resource_size_t) mac_bi_data.sccbase; |
| 856 | scc_b_rsrcs[0].end = scc_b_rsrcs[0].start; |
| 857 | |
| 858 | switch (macintosh_config->scc_type) { |
| 859 | case MAC_SCC_PSC: |
| 860 | scc_a_rsrcs[1].start = scc_a_rsrcs[1].end = IRQ_MAC_SCC_A; |
| 861 | scc_b_rsrcs[1].start = scc_b_rsrcs[1].end = IRQ_MAC_SCC_B; |
| 862 | break; |
| 863 | default: |
Finn Thain | da3fb3c | 2011-10-24 01:11:18 +1100 | [diff] [blame] | 864 | /* On non-PSC machines, the serial ports share an IRQ. */ |
| 865 | if (macintosh_config->ident == MAC_MODEL_IIFX) { |
| 866 | scc_a_rsrcs[1].start = scc_a_rsrcs[1].end = IRQ_MAC_SCC; |
| 867 | scc_b_rsrcs[1].start = scc_b_rsrcs[1].end = IRQ_MAC_SCC; |
| 868 | } else { |
| 869 | scc_a_rsrcs[1].start = scc_a_rsrcs[1].end = IRQ_AUTO_4; |
| 870 | scc_b_rsrcs[1].start = scc_b_rsrcs[1].end = IRQ_AUTO_4; |
| 871 | } |
Finn Thain | 80614e5 | 2009-11-17 20:06:48 +1100 | [diff] [blame] | 872 | break; |
| 873 | } |
| 874 | |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 875 | /* |
| 876 | * We need to pre-init the IOPs, if any. Otherwise |
| 877 | * the serial console won't work if the user had |
| 878 | * the serial ports set to "Faster" mode in MacOS. |
| 879 | */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 880 | iop_preinit(); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 881 | |
Frans Pop | b9b0d8b | 2010-02-06 18:47:11 +0100 | [diff] [blame] | 882 | printk(KERN_INFO "Detected Macintosh model: %d\n", model); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 883 | |
| 884 | /* |
| 885 | * Report booter data: |
| 886 | */ |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 887 | printk(KERN_DEBUG " Penguin bootinfo data:\n"); |
Finn Thain | 53aac0a | 2009-11-04 00:39:09 +1100 | [diff] [blame] | 888 | printk(KERN_DEBUG " Video: addr 0x%lx " |
| 889 | "row 0x%lx depth %lx dimensions %ld x %ld\n", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 890 | mac_bi_data.videoaddr, mac_bi_data.videorow, |
| 891 | mac_bi_data.videodepth, mac_bi_data.dimensions & 0xFFFF, |
| 892 | mac_bi_data.dimensions >> 16); |
Frans Pop | b9b0d8b | 2010-02-06 18:47:11 +0100 | [diff] [blame] | 893 | printk(KERN_DEBUG " Videological 0x%lx phys. 0x%lx, SCC at 0x%lx\n", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 894 | mac_bi_data.videological, mac_orig_videoaddr, |
| 895 | mac_bi_data.sccbase); |
Frans Pop | b9b0d8b | 2010-02-06 18:47:11 +0100 | [diff] [blame] | 896 | printk(KERN_DEBUG " Boottime: 0x%lx GMTBias: 0x%lx\n", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 897 | mac_bi_data.boottime, mac_bi_data.gmtbias); |
Frans Pop | b9b0d8b | 2010-02-06 18:47:11 +0100 | [diff] [blame] | 898 | printk(KERN_DEBUG " Machine ID: %ld CPUid: 0x%lx memory size: 0x%lx\n", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 899 | mac_bi_data.id, mac_bi_data.cpuid, mac_bi_data.memsize); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 900 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 901 | iop_init(); |
| 902 | via_init(); |
| 903 | oss_init(); |
| 904 | psc_init(); |
| 905 | baboon_init(); |
Finn Thain | 18814ee | 2009-11-17 20:03:05 +1100 | [diff] [blame] | 906 | |
| 907 | #ifdef CONFIG_ADB_CUDA |
| 908 | find_via_cuda(); |
| 909 | #endif |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 910 | } |
| 911 | |
Adrian Bunk | 8dfbdf4 | 2008-07-17 21:16:25 +0200 | [diff] [blame] | 912 | static void __init mac_report_hardware(void) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 913 | { |
| 914 | printk(KERN_INFO "Apple Macintosh %s\n", macintosh_config->name); |
| 915 | } |
| 916 | |
| 917 | static void mac_get_model(char *str) |
| 918 | { |
Roman Zippel | 6ff5801 | 2007-05-01 22:32:43 +0200 | [diff] [blame] | 919 | strcpy(str, "Macintosh "); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 920 | strcat(str, macintosh_config->name); |
| 921 | } |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 922 | |
Finn Thain | 2724daf | 2009-11-04 00:39:56 +1100 | [diff] [blame] | 923 | static struct resource swim_rsrc = { .flags = IORESOURCE_MEM }; |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 924 | |
Finn Thain | 2724daf | 2009-11-04 00:39:56 +1100 | [diff] [blame] | 925 | static struct platform_device swim_pdev = { |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 926 | .name = "swim", |
| 927 | .id = -1, |
Finn Thain | 2724daf | 2009-11-04 00:39:56 +1100 | [diff] [blame] | 928 | .num_resources = 1, |
| 929 | .resource = &swim_rsrc, |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 930 | }; |
| 931 | |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 932 | static const struct resource mac_scsi_iifx_rsrc[] __initconst = { |
| 933 | { |
| 934 | .flags = IORESOURCE_IRQ, |
| 935 | .start = IRQ_MAC_SCSI, |
| 936 | .end = IRQ_MAC_SCSI, |
| 937 | }, { |
| 938 | .flags = IORESOURCE_MEM, |
| 939 | .start = 0x50008000, |
| 940 | .end = 0x50009FFF, |
| 941 | }, |
| 942 | }; |
| 943 | |
| 944 | static const struct resource mac_scsi_duo_rsrc[] __initconst = { |
| 945 | { |
| 946 | .flags = IORESOURCE_MEM, |
| 947 | .start = 0xFEE02000, |
| 948 | .end = 0xFEE03FFF, |
| 949 | }, |
| 950 | }; |
| 951 | |
| 952 | static const struct resource mac_scsi_old_rsrc[] __initconst = { |
| 953 | { |
| 954 | .flags = IORESOURCE_IRQ, |
| 955 | .start = IRQ_MAC_SCSI, |
| 956 | .end = IRQ_MAC_SCSI, |
| 957 | }, { |
| 958 | .flags = IORESOURCE_MEM, |
| 959 | .start = 0x50010000, |
| 960 | .end = 0x50011FFF, |
| 961 | }, { |
| 962 | .flags = IORESOURCE_MEM, |
| 963 | .start = 0x50006000, |
| 964 | .end = 0x50007FFF, |
| 965 | }, |
| 966 | }; |
| 967 | |
| 968 | static const struct resource mac_scsi_late_rsrc[] __initconst = { |
| 969 | { |
| 970 | .flags = IORESOURCE_IRQ, |
| 971 | .start = IRQ_MAC_SCSI, |
| 972 | .end = IRQ_MAC_SCSI, |
| 973 | }, { |
| 974 | .flags = IORESOURCE_MEM, |
| 975 | .start = 0x50010000, |
| 976 | .end = 0x50011FFF, |
| 977 | }, |
| 978 | }; |
| 979 | |
| 980 | static const struct resource mac_scsi_ccl_rsrc[] __initconst = { |
| 981 | { |
| 982 | .flags = IORESOURCE_IRQ, |
| 983 | .start = IRQ_MAC_SCSI, |
| 984 | .end = IRQ_MAC_SCSI, |
| 985 | }, { |
| 986 | .flags = IORESOURCE_MEM, |
| 987 | .start = 0x50F10000, |
| 988 | .end = 0x50F11FFF, |
| 989 | }, { |
| 990 | .flags = IORESOURCE_MEM, |
| 991 | .start = 0x50F06000, |
| 992 | .end = 0x50F07FFF, |
| 993 | }, |
| 994 | }; |
| 995 | |
Finn Thain | cff75f1 | 2009-11-04 00:41:35 +1100 | [diff] [blame] | 996 | static struct platform_device esp_0_pdev = { |
| 997 | .name = "mac_esp", |
| 998 | .id = 0, |
| 999 | }; |
| 1000 | |
| 1001 | static struct platform_device esp_1_pdev = { |
| 1002 | .name = "mac_esp", |
| 1003 | .id = 1, |
| 1004 | }; |
| 1005 | |
Finn Thain | eeb9c18 | 2009-11-04 00:42:02 +1100 | [diff] [blame] | 1006 | static struct platform_device sonic_pdev = { |
| 1007 | .name = "macsonic", |
| 1008 | .id = -1, |
| 1009 | }; |
| 1010 | |
| 1011 | static struct platform_device mace_pdev = { |
| 1012 | .name = "macmace", |
| 1013 | .id = -1, |
| 1014 | }; |
| 1015 | |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 1016 | int __init mac_platform_init(void) |
| 1017 | { |
| 1018 | u8 *swim_base; |
| 1019 | |
Geert Uytterhoeven | 6cfeba5 | 2012-03-18 13:21:38 +0100 | [diff] [blame] | 1020 | if (!MACH_IS_MAC) |
| 1021 | return -ENODEV; |
| 1022 | |
Finn Thain | 2724daf | 2009-11-04 00:39:56 +1100 | [diff] [blame] | 1023 | /* |
Finn Thain | 80614e5 | 2009-11-17 20:06:48 +1100 | [diff] [blame] | 1024 | * Serial devices |
| 1025 | */ |
| 1026 | |
| 1027 | platform_device_register(&scc_a_pdev); |
| 1028 | platform_device_register(&scc_b_pdev); |
| 1029 | |
| 1030 | /* |
Finn Thain | 2724daf | 2009-11-04 00:39:56 +1100 | [diff] [blame] | 1031 | * Floppy device |
| 1032 | */ |
| 1033 | |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 1034 | switch (macintosh_config->floppy_type) { |
| 1035 | case MAC_FLOPPY_SWIM_ADDR1: |
| 1036 | swim_base = (u8 *)(VIA1_BASE + 0x1E000); |
| 1037 | break; |
| 1038 | case MAC_FLOPPY_SWIM_ADDR2: |
| 1039 | swim_base = (u8 *)(VIA1_BASE + 0x16000); |
| 1040 | break; |
| 1041 | default: |
Finn Thain | 2724daf | 2009-11-04 00:39:56 +1100 | [diff] [blame] | 1042 | swim_base = NULL; |
| 1043 | break; |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 1044 | } |
| 1045 | |
Finn Thain | 2724daf | 2009-11-04 00:39:56 +1100 | [diff] [blame] | 1046 | if (swim_base) { |
| 1047 | swim_rsrc.start = (resource_size_t) swim_base, |
| 1048 | swim_rsrc.end = (resource_size_t) swim_base + 0x2000, |
| 1049 | platform_device_register(&swim_pdev); |
| 1050 | } |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 1051 | |
Finn Thain | cff75f1 | 2009-11-04 00:41:35 +1100 | [diff] [blame] | 1052 | /* |
| 1053 | * SCSI device(s) |
| 1054 | */ |
| 1055 | |
| 1056 | switch (macintosh_config->scsi_type) { |
| 1057 | case MAC_SCSI_QUADRA: |
| 1058 | case MAC_SCSI_QUADRA3: |
| 1059 | platform_device_register(&esp_0_pdev); |
| 1060 | break; |
| 1061 | case MAC_SCSI_QUADRA2: |
| 1062 | platform_device_register(&esp_0_pdev); |
| 1063 | if ((macintosh_config->ident == MAC_MODEL_Q900) || |
| 1064 | (macintosh_config->ident == MAC_MODEL_Q950)) |
| 1065 | platform_device_register(&esp_1_pdev); |
| 1066 | break; |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 1067 | case MAC_SCSI_IIFX: |
| 1068 | /* Addresses from The Guide to Mac Family Hardware. |
| 1069 | * $5000 8000 - $5000 9FFF: SCSI DMA |
| 1070 | * $5000 C000 - $5000 DFFF: Alternate SCSI (DMA) |
| 1071 | * $5000 E000 - $5000 FFFF: Alternate SCSI (Hsk) |
| 1072 | * The SCSI DMA custom IC embeds the 53C80 core. mac_scsi does |
| 1073 | * not make use of its DMA or hardware handshaking logic. |
| 1074 | */ |
| 1075 | platform_device_register_simple("mac_scsi", 0, |
| 1076 | mac_scsi_iifx_rsrc, ARRAY_SIZE(mac_scsi_iifx_rsrc)); |
| 1077 | break; |
| 1078 | case MAC_SCSI_DUO: |
| 1079 | /* Addresses from the Duo Dock II Developer Note. |
| 1080 | * $FEE0 2000 - $FEE0 3FFF: normal mode |
| 1081 | * $FEE0 4000 - $FEE0 5FFF: pseudo DMA without /DRQ |
| 1082 | * $FEE0 6000 - $FEE0 7FFF: pseudo DMA with /DRQ |
| 1083 | * The NetBSD code indicates that both 5380 chips share |
| 1084 | * an IRQ (?) which would need careful handling (see mac_esp). |
| 1085 | */ |
| 1086 | platform_device_register_simple("mac_scsi", 1, |
| 1087 | mac_scsi_duo_rsrc, ARRAY_SIZE(mac_scsi_duo_rsrc)); |
| 1088 | /* fall through */ |
| 1089 | case MAC_SCSI_OLD: |
| 1090 | /* Addresses from Developer Notes for Duo System, |
| 1091 | * PowerBook 180 & 160, 140 & 170, Macintosh IIsi |
| 1092 | * and also from The Guide to Mac Family Hardware for |
| 1093 | * SE/30, II, IIx, IIcx, IIci. |
| 1094 | * $5000 6000 - $5000 7FFF: pseudo-DMA with /DRQ |
| 1095 | * $5001 0000 - $5001 1FFF: normal mode |
| 1096 | * $5001 2000 - $5001 3FFF: pseudo-DMA without /DRQ |
| 1097 | * GMFH says that $5000 0000 - $50FF FFFF "wraps |
| 1098 | * $5000 0000 - $5001 FFFF eight times" (!) |
| 1099 | * mess.org says IIci and Color Classic do not alias |
| 1100 | * I/O address space. |
| 1101 | */ |
| 1102 | platform_device_register_simple("mac_scsi", 0, |
| 1103 | mac_scsi_old_rsrc, ARRAY_SIZE(mac_scsi_old_rsrc)); |
| 1104 | break; |
| 1105 | case MAC_SCSI_LATE: |
| 1106 | /* PDMA logic in 68040 PowerBooks is somehow different to |
| 1107 | * '030 models. It's probably more like Quadras (see mac_esp). |
| 1108 | */ |
| 1109 | platform_device_register_simple("mac_scsi", 0, |
| 1110 | mac_scsi_late_rsrc, ARRAY_SIZE(mac_scsi_late_rsrc)); |
| 1111 | break; |
Finn Thain | 2e874d1 | 2015-01-07 11:17:35 +1100 | [diff] [blame^] | 1112 | case MAC_SCSI_LC: |
| 1113 | /* Addresses from Mac LC data in Designing Cards & Drivers 3ed. |
| 1114 | * Also from the Developer Notes for Classic II, LC III, |
| 1115 | * Color Classic and IIvx. |
Finn Thain | cbad48d | 2014-11-12 16:12:07 +1100 | [diff] [blame] | 1116 | * $50F0 6000 - $50F0 7FFF: SCSI handshake |
| 1117 | * $50F1 0000 - $50F1 1FFF: SCSI |
| 1118 | * $50F1 2000 - $50F1 3FFF: SCSI DMA |
| 1119 | */ |
| 1120 | platform_device_register_simple("mac_scsi", 0, |
| 1121 | mac_scsi_ccl_rsrc, ARRAY_SIZE(mac_scsi_ccl_rsrc)); |
| 1122 | break; |
Finn Thain | cff75f1 | 2009-11-04 00:41:35 +1100 | [diff] [blame] | 1123 | } |
| 1124 | |
Finn Thain | eeb9c18 | 2009-11-04 00:42:02 +1100 | [diff] [blame] | 1125 | /* |
| 1126 | * Ethernet device |
| 1127 | */ |
| 1128 | |
| 1129 | switch (macintosh_config->ether_type) { |
| 1130 | case MAC_ETHER_SONIC: |
| 1131 | platform_device_register(&sonic_pdev); |
| 1132 | break; |
| 1133 | case MAC_ETHER_MACE: |
| 1134 | platform_device_register(&mace_pdev); |
| 1135 | break; |
| 1136 | } |
| 1137 | |
Finn Thain | 2724daf | 2009-11-04 00:39:56 +1100 | [diff] [blame] | 1138 | return 0; |
Laurent Vivier | 8852ecd | 2008-11-15 16:10:10 +0100 | [diff] [blame] | 1139 | } |
| 1140 | |
| 1141 | arch_initcall(mac_platform_init); |