aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/scsi/aha1542.c25
1 files changed, 0 insertions, 25 deletions
diff --git a/drivers/scsi/aha1542.c b/drivers/scsi/aha1542.c
index 2a8cf137f609..4f785f254c1f 100644
--- a/drivers/scsi/aha1542.c
+++ b/drivers/scsi/aha1542.c
@@ -52,22 +52,6 @@
52#define SCSI_BUF_PA(address) isa_virt_to_bus(address) 52#define SCSI_BUF_PA(address) isa_virt_to_bus(address)
53#define SCSI_SG_PA(sgent) (isa_page_to_bus(sg_page((sgent))) + (sgent)->offset) 53#define SCSI_SG_PA(sgent) (isa_page_to_bus(sg_page((sgent))) + (sgent)->offset)
54 54
55static void BAD_SG_DMA(Scsi_Cmnd * SCpnt,
56 struct scatterlist *sgp,
57 int nseg,
58 int badseg)
59{
60 printk(KERN_CRIT "sgpnt[%d:%d] page %p/0x%llx length %u\n",
61 badseg, nseg, sg_virt(sgp),
62 (unsigned long long)SCSI_SG_PA(sgp),
63 sgp->length);
64
65 /*
66 * Not safe to continue.
67 */
68 panic("Buffer at physical address > 16Mb used for aha1542");
69}
70
71#include<linux/stat.h> 55#include<linux/stat.h>
72 56
73#ifdef DEBUG 57#ifdef DEBUG
@@ -691,8 +675,6 @@ static int aha1542_queuecommand(Scsi_Cmnd * SCpnt, void (*done) (Scsi_Cmnd *))
691 } 675 }
692 scsi_for_each_sg(SCpnt, sg, sg_count, i) { 676 scsi_for_each_sg(SCpnt, sg, sg_count, i) {
693 any2scsi(cptr[i].dataptr, SCSI_SG_PA(sg)); 677 any2scsi(cptr[i].dataptr, SCSI_SG_PA(sg));
694 if (SCSI_SG_PA(sg) + sg->length - 1 > ISA_DMA_THRESHOLD)
695 BAD_SG_DMA(SCpnt, scsi_sglist(SCpnt), sg_count, i);
696 any2scsi(cptr[i].datalen, sg->length); 678 any2scsi(cptr[i].datalen, sg->length);
697 }; 679 };
698 any2scsi(ccb[mbo].datalen, sg_count * sizeof(struct chain)); 680 any2scsi(ccb[mbo].datalen, sg_count * sizeof(struct chain));
@@ -1133,16 +1115,9 @@ static int __init aha1542_detect(struct scsi_host_template * tpnt)
1133 release_region(bases[indx], 4); 1115 release_region(bases[indx], 4);
1134 continue; 1116 continue;
1135 } 1117 }
1136 /* For now we do this - until kmalloc is more intelligent
1137 we are resigned to stupid hacks like this */
1138 if (SCSI_BUF_PA(shpnt) >= ISA_DMA_THRESHOLD) {
1139 printk(KERN_ERR "Invalid address for shpnt with 1542.\n");
1140 goto unregister;
1141 }
1142 if (!aha1542_test_port(bases[indx], shpnt)) 1118 if (!aha1542_test_port(bases[indx], shpnt))
1143 goto unregister; 1119 goto unregister;
1144 1120
1145
1146 base_io = bases[indx]; 1121 base_io = bases[indx];
1147 1122
1148 /* Set the Bus on/off-times as not to ruin floppy performance */ 1123 /* Set the Bus on/off-times as not to ruin floppy performance */