Hi,
through the whole issue of the mmu_sglist confusion and the broken
reimplantation of mmu_sglist the dec_esp broke. Here is a fix
to really remove the mmu_sglist and use scatterlist instead. With
this the Decstation on this desk at least finds its partitions
again and does not crash.
I vote for removal of the struct mmu_sglist as at least it now
breaks on compile time and not confusion at runtime.
Flo
Index: drivers/scsi/dec_esp.c
===================================================================
RCS file: /home/cvs/linux/drivers/scsi/dec_esp.c,v
retrieving revision 1.10.2.3
diff -u -r1.10.2.3 dec_esp.c
--- drivers/scsi/dec_esp.c 23 Aug 2002 09:49:51 -0000 1.10.2.3
+++ drivers/scsi/dec_esp.c 28 Sep 2002 01:57:16 -0000
@@ -443,13 +443,13 @@
static void dma_mmu_get_scsi_sgl(struct NCR_ESP *esp, Scsi_Cmnd * sp)
{
- int sz = sp->SCp.buffers_residual;
- struct mmu_sglist *sg = (struct mmu_sglist *) sp->SCp.buffer;
+ int sz = sp->SCp.buffers_residual;
+ struct scatterlist *sg = sp->SCp.buffer;
- while (sz >= 0) {
- sg[sz].dvma_addr = PHYSADDR(sg[sz].addr);
- sz--;
- }
+ while (sz >= 0) {
+ sg[sz].dma_address = PHYSADDR(sg[sz].address);
+ sz--;
+ }
sp->SCp.ptr = (char *) ((unsigned long) sp->SCp.buffer->dma_address);
}
Index: include/asm-mips/scatterlist.h
===================================================================
RCS file: /home/cvs/linux/include/asm-mips/scatterlist.h,v
retrieving revision 1.4.2.3
diff -u -r1.4.2.3 scatterlist.h
--- include/asm-mips/scatterlist.h 23 Aug 2002 09:50:00 -0000 1.4.2.3
+++ include/asm-mips/scatterlist.h 28 Sep 2002 01:57:16 -0000
@@ -10,13 +10,6 @@
unsigned int length;
};
-struct mmu_sglist {
- char *addr;
- char *__dont_touch;
- unsigned int len;
- dma_addr_t dvma_addr;
-};
-
#define ISA_DMA_THRESHOLD (0x00ffffff)
#endif /* __ASM_SCATTERLIST_H */
--
Florian Lohoff flo@rfc822.org +49-5201-669912
Heisenberg may have been here.
pgpsQ3cB1vbxz.pgp
Description: PGP signature
|