patch-2.2.18 linux/drivers/scsi/wd33c93.c
Next file: linux/drivers/scsi/wd33c93.h
Previous file: linux/drivers/scsi/sym53c8xx_defs.h
Back to the patch index
Back to the overall index
- Lines: 51
- Date:
Fri Oct 13 23:58:25 2000
- Orig file:
v2.2.17/drivers/scsi/wd33c93.c
- Orig date:
Fri Apr 21 12:46:33 2000
diff -u --new-file --recursive --exclude-from /usr/src/exclude v2.2.17/drivers/scsi/wd33c93.c linux/drivers/scsi/wd33c93.c
@@ -176,6 +176,7 @@
static inline uchar read_wd33c93(wd33c93_regs *regp,uchar reg_num)
{
regp->SASR = reg_num;
+ mb();
return(regp->SCMD);
}
@@ -186,14 +187,18 @@
static inline void write_wd33c93(wd33c93_regs *regp,uchar reg_num, uchar value)
{
regp->SASR = reg_num;
+ mb();
regp->SCMD = value;
+ mb();
}
static inline void write_wd33c93_cmd(wd33c93_regs *regp, uchar cmd)
{
regp->SASR = WD_COMMAND;
+ mb();
regp->SCMD = cmd;
+ mb();
}
@@ -216,9 +221,11 @@
static void write_wd33c93_count(wd33c93_regs *regp,unsigned long value)
{
regp->SASR = WD_TRANSFER_COUNT_MSB;
+ mb();
regp->SCMD = value >> 16;
regp->SCMD = value >> 8;
regp->SCMD = value;
+ mb();
}
@@ -227,9 +234,11 @@
unsigned long value;
regp->SASR = WD_TRANSFER_COUNT_MSB;
+ mb();
value = regp->SCMD << 16;
value |= regp->SCMD << 8;
value |= regp->SCMD;
+ mb();
return value;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)