aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aha1542.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/aha1542.c')
-rw-r--r--drivers/scsi/aha1542.c66
1 files changed, 2 insertions, 64 deletions
diff --git a/drivers/scsi/aha1542.c b/drivers/scsi/aha1542.c
index ede91f37800..f79c8f9e33a 100644
--- a/drivers/scsi/aha1542.c
+++ b/drivers/scsi/aha1542.c
@@ -22,7 +22,7 @@
22 * Added module command-line options 22 * Added module command-line options
23 * 19-Jul-99 23 * 19-Jul-99
24 * Modified by Adam Fritzler 24 * Modified by Adam Fritzler
25 * Added proper detection of the AHA-1640 (MCA version of AHA-1540) 25 * Added proper detection of the AHA-1640 (MCA, now deleted)
26 */ 26 */
27 27
28#include <linux/module.h> 28#include <linux/module.h>
@@ -37,8 +37,6 @@
37#include <linux/spinlock.h> 37#include <linux/spinlock.h>
38#include <linux/isapnp.h> 38#include <linux/isapnp.h>
39#include <linux/blkdev.h> 39#include <linux/blkdev.h>
40#include <linux/mca.h>
41#include <linux/mca-legacy.h>
42#include <linux/slab.h> 40#include <linux/slab.h>
43 41
44#include <asm/dma.h> 42#include <asm/dma.h>
@@ -71,7 +69,7 @@
71#define MAXBOARDS 4 /* Increase this and the sizes of the 69#define MAXBOARDS 4 /* Increase this and the sizes of the
72 arrays below, if you need more.. */ 70 arrays below, if you need more.. */
73 71
74/* Boards 3,4 slots are reserved for ISAPnP/MCA scans */ 72/* Boards 3,4 slots are reserved for ISAPnP scans */
75 73
76static unsigned int bases[MAXBOARDS] __initdata = {0x330, 0x334, 0, 0}; 74static unsigned int bases[MAXBOARDS] __initdata = {0x330, 0x334, 0, 0};
77 75
@@ -1009,66 +1007,6 @@ static int __init aha1542_detect(struct scsi_host_template * tpnt)
1009#endif 1007#endif
1010 1008
1011 /* 1009 /*
1012 * Find MicroChannel cards (AHA1640)
1013 */
1014#ifdef CONFIG_MCA_LEGACY
1015 if(MCA_bus) {
1016 int slot = 0;
1017 int pos = 0;
1018
1019 for (indx = 0; (slot != MCA_NOTFOUND) && (indx < ARRAY_SIZE(bases)); indx++) {
1020
1021 if (bases[indx])
1022 continue;
1023
1024 /* Detect only AHA-1640 cards -- MCA ID 0F1F */
1025 slot = mca_find_unused_adapter(0x0f1f, slot);
1026 if (slot == MCA_NOTFOUND)
1027 break;
1028
1029 /* Found one */
1030 pos = mca_read_stored_pos(slot, 3);
1031
1032 /* Decode address */
1033 if (pos & 0x80) {
1034 if (pos & 0x02) {
1035 if (pos & 0x01)
1036 bases[indx] = 0x334;
1037 else
1038 bases[indx] = 0x234;
1039 } else {
1040 if (pos & 0x01)
1041 bases[indx] = 0x134;
1042 }
1043 } else {
1044 if (pos & 0x02) {
1045 if (pos & 0x01)
1046 bases[indx] = 0x330;
1047 else
1048 bases[indx] = 0x230;
1049 } else {
1050 if (pos & 0x01)
1051 bases[indx] = 0x130;
1052 }
1053 }
1054
1055 /* No need to decode IRQ and Arb level -- those are
1056 * read off the card later.
1057 */
1058 printk(KERN_INFO "Found an AHA-1640 in MCA slot %d, I/O 0x%04x\n", slot, bases[indx]);
1059
1060 mca_set_adapter_name(slot, "Adapter AHA-1640");
1061 mca_set_adapter_procfn(slot, NULL, NULL);
1062 mca_mark_as_used(slot);
1063
1064 /* Go on */
1065 slot++;
1066 }
1067
1068 }
1069#endif
1070
1071 /*
1072 * Hunt for ISA Plug'n'Pray Adaptecs (AHA1535) 1010 * Hunt for ISA Plug'n'Pray Adaptecs (AHA1535)
1073 */ 1011 */
1074 1012