[PATCH] 2.3.99-pre3 sym53c8xx//ncr53c8xx

From: roussel@efi.com
Date: Mon Mar 27 2000 - 12:51:23 EST


Hi,

Here is a patch for sym53c8xx and ncr53c8xx drivers, so that they will
compile on ALPHA. It is an NCR_IOMAPPED issue.

The patch worked for me on a PC164. I've heard it failed on an LX164.

PS I'm not subscribing to the list.

--- linux-2.3.99-pre3/drivers/scsi/sym53c8xx_comm.h Mon Mar 27 08:57:52 2000
+++ linux/drivers/scsi/sym53c8xx_comm.h Mon Mar 27 08:59:18 2000
@@ -1180,32 +1180,32 @@
 ** IO mapped only input / ouput
 */
 
-#define INB_OFF(o) inb (np->base_io + ncr_offb(o))
-#define OUTB_OFF(o, val) outb ((val), np->base_io + ncr_offb(o))
+#define INB_OFF(o) inb (np->port + ncr_offb(o))
+#define OUTB_OFF(o, val) outb ((val), np->port + ncr_offb(o))
 
 #if defined(__BIG_ENDIAN) && !defined(SCSI_NCR_BIG_ENDIAN)
 
-#define INW_OFF(o) inw_l2b (np->base_io + ncr_offw(o))
-#define INL_OFF(o) inl_l2b (np->base_io + (o))
+#define INW_OFF(o) inw_l2b (np->port + ncr_offw(o))
+#define INL_OFF(o) inl_l2b (np->port + (o))
 
-#define OUTW_OFF(o, val) outw_b2l ((val), np->base_io + ncr_offw(o))
-#define OUTL_OFF(o, val) outl_b2l ((val), np->base_io + (o))
+#define OUTW_OFF(o, val) outw_b2l ((val), np->port + ncr_offw(o))
+#define OUTL_OFF(o, val) outl_b2l ((val), np->port + (o))
 
 #elif defined(__LITTLE_ENDIAN) && defined(SCSI_NCR_BIG_ENDIAN)
 
-#define INW_OFF(o) inw_b2l (np->base_io + ncr_offw(o))
-#define INL_OFF(o) inl_b2l (np->base_io + (o))
+#define INW_OFF(o) inw_b2l (np->port + ncr_offw(o))
+#define INL_OFF(o) inl_b2l (np->port + (o))
 
-#define OUTW_OFF(o, val) outw_l2b ((val), np->base_io + ncr_offw(o))
-#define OUTL_OFF(o, val) outl_l2b ((val), np->base_io + (o))
+#define OUTW_OFF(o, val) outw_l2b ((val), np->port + ncr_offw(o))
+#define OUTL_OFF(o, val) outl_l2b ((val), np->port + (o))
 
 #else
 
-#define INW_OFF(o) inw_raw (np->base_io + ncr_offw(o))
-#define INL_OFF(o) inl_raw (np->base_io + (o))
+#define INW_OFF(o) inw_raw (np->port + ncr_offw(o))
+#define INL_OFF(o) inl_raw (np->port + (o))
 
-#define OUTW_OFF(o, val) outw_raw ((val), np->base_io + ncr_offw(o))
-#define OUTL_OFF(o, val) outl_raw ((val), np->base_io + (o))
+#define OUTW_OFF(o, val) outw_raw ((val), np->port + ncr_offw(o))
+#define OUTL_OFF(o, val) outl_raw ((val), np->port + (o))
 
 #endif /* ENDIANs */
 
@@ -1281,7 +1281,7 @@
         u_long io_port;
         int irq;
 /* port and reg fields to use INB, OUTB macros */
- u_long base_io;
+ u_long port;
         volatile struct ncr_reg *reg;
 } ncr_slot;
 
@@ -1798,7 +1798,7 @@
         */
 #ifdef NCR_IOMAPPED
         request_region(devp->slot.io_port, 128, NAME53C8XX);
- devp->slot.base_io = devp->slot.io_port;
+ devp->slot.port = devp->slot.io_port;
 #else
         devp->slot.reg = (struct ncr_reg *) remap_pci_mem(devp->slot.base, 128);
         if (!devp->slot.reg)
@@ -1823,7 +1823,7 @@
         ** Release access to chip IO registers
         */
 #ifdef NCR_IOMAPPED
- release_region(devp->slot.base_io, 128);
+ release_region(devp->slot.port, 128);
 #else
         unmap_pci_mem((u_long) devp->slot.reg, 128ul);
 #endif

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Mar 31 2000 - 21:00:20 EST