git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
VServer 1.9.2 (patch-2.6.8.1-vs1.9.2.diff)
[linux-2.6.git]
/
drivers
/
scsi
/
qla1280.c
diff --git
a/drivers/scsi/qla1280.c
b/drivers/scsi/qla1280.c
index
6dfc187
..
917a208
100644
(file)
--- a/
drivers/scsi/qla1280.c
+++ b/
drivers/scsi/qla1280.c
@@
-357,7
+357,7
@@
#else
#include <linux/blk.h>
#include "scsi.h"
#else
#include <linux/blk.h>
#include "scsi.h"
-#include
"hosts.h"
+#include
<scsi/scsi_host.h>
#include "sd.h"
#endif
#include "sd.h"
#endif
@@
-3119,6
+3119,7
@@
qla1280_marker(struct scsi_qla_host *ha, int bus, int id, int lun, u8 type)
* Returns:
* 0 = success, was able to issue command.
*/
* Returns:
* 0 = success, was able to issue command.
*/
+#ifdef QLA_64BIT_PTR
static int
qla1280_64bit_start_scsi(struct scsi_qla_host *ha, struct srb * sp)
{
static int
qla1280_64bit_start_scsi(struct scsi_qla_host *ha, struct srb * sp)
{
@@
-3371,6
+3372,7
@@
qla1280_64bit_start_scsi(struct scsi_qla_host *ha, struct srb * sp)
sp->flags |= SRB_SENT;
ha->actthreads++;
WRT_REG_WORD(®->mailbox4, ha->req_ring_index);
sp->flags |= SRB_SENT;
ha->actthreads++;
WRT_REG_WORD(®->mailbox4, ha->req_ring_index);
+ (void) RD_REG_WORD(®->mailbox4); /* PCI posted write flush */
out:
if (status)
out:
if (status)
@@
-3380,9
+3382,8
@@
qla1280_64bit_start_scsi(struct scsi_qla_host *ha, struct srb * sp)
return status;
}
return status;
}
+#else /* !QLA_64BIT_PTR */
-
-#ifndef QLA_64BIT_PTR
/*
* qla1280_32bit_start_scsi
* The start SCSI is responsible for building request packets on
/*
* qla1280_32bit_start_scsi
* The start SCSI is responsible for building request packets on
@@
-3639,6
+3640,7
@@
qla1280_32bit_start_scsi(struct scsi_qla_host *ha, struct srb * sp)
sp->flags |= SRB_SENT;
ha->actthreads++;
WRT_REG_WORD(®->mailbox4, ha->req_ring_index);
sp->flags |= SRB_SENT;
ha->actthreads++;
WRT_REG_WORD(®->mailbox4, ha->req_ring_index);
+ (void) RD_REG_WORD(®->mailbox4); /* PCI posted write flush */
out:
if (status)
out:
if (status)
@@
-3665,7
+3667,7
@@
static request_t *
qla1280_req_pkt(struct scsi_qla_host *ha)
{
struct device_reg *reg = ha->iobase;
qla1280_req_pkt(struct scsi_qla_host *ha)
{
struct device_reg *reg = ha->iobase;
- request_t *pkt =
0
;
+ request_t *pkt =
NULL
;
int cnt;
uint32_t timer;
int cnt;
uint32_t timer;
@@
-3750,6
+3752,7
@@
qla1280_isp_cmd(struct scsi_qla_host *ha)
/* Set chip new ring index. */
WRT_REG_WORD(®->mailbox4, ha->req_ring_index);
/* Set chip new ring index. */
WRT_REG_WORD(®->mailbox4, ha->req_ring_index);
+ (void) RD_REG_WORD(®->mailbox4); /* PCI posted write flush */
LEAVE("qla1280_isp_cmd");
}
LEAVE("qla1280_isp_cmd");
}
@@
-3771,7
+3774,7
@@
qla1280_isr(struct scsi_qla_host *ha, struct list_head *done_q)
{
struct device_reg *reg = ha->iobase;
struct response *pkt;
{
struct device_reg *reg = ha->iobase;
struct response *pkt;
- struct srb *sp =
0
;
+ struct srb *sp =
NULL
;
uint16_t mailbox[MAILBOX_REGISTER_COUNT];
uint16_t *wptr;
uint32_t index;
uint16_t mailbox[MAILBOX_REGISTER_COUNT];
uint16_t *wptr;
uint32_t index;
@@
-3788,7
+3791,7
@@
qla1280_isr(struct scsi_qla_host *ha, struct list_head *done_q)
/* Check for mailbox interrupt. */
/* Check for mailbox interrupt. */
- mailbox[0] = RD_REG_WORD(®->semaphore);
+ mailbox[0] = RD_REG_WORD
_dmasync
(®->semaphore);
if (mailbox[0] & BIT_0) {
/* Get mailbox data. */
if (mailbox[0] & BIT_0) {
/* Get mailbox data. */
@@
-3829,11
+3832,11
@@
qla1280_isr(struct scsi_qla_host *ha, struct list_head *done_q)
if (index < MAX_OUTSTANDING_COMMANDS)
sp = ha->outstanding_cmds[index];
else
if (index < MAX_OUTSTANDING_COMMANDS)
sp = ha->outstanding_cmds[index];
else
- sp =
0
;
+ sp =
NULL
;
if (sp) {
/* Free outstanding command slot. */
if (sp) {
/* Free outstanding command slot. */
- ha->outstanding_cmds[index] =
0
;
+ ha->outstanding_cmds[index] =
NULL
;
/* Save ISP completion status */
CMD_RESULT(sp->cmd) = 0;
/* Save ISP completion status */
CMD_RESULT(sp->cmd) = 0;
@@
-4092,7
+4095,7
@@
qla1280_status_entry(struct scsi_qla_host *ha, struct response *pkt,
}
/* Free outstanding command slot. */
}
/* Free outstanding command slot. */
- ha->outstanding_cmds[handle] =
0
;
+ ha->outstanding_cmds[handle] =
NULL
;
cmd = sp->cmd;
cmd = sp->cmd;
@@
-4185,11
+4188,11
@@
qla1280_error_entry(struct scsi_qla_host *ha, struct response *pkt,
if (handle < MAX_OUTSTANDING_COMMANDS)
sp = ha->outstanding_cmds[handle];
else
if (handle < MAX_OUTSTANDING_COMMANDS)
sp = ha->outstanding_cmds[handle];
else
- sp =
0
;
+ sp =
NULL
;
if (sp) {
/* Free outstanding command slot. */
if (sp) {
/* Free outstanding command slot. */
- ha->outstanding_cmds[handle] =
0
;
+ ha->outstanding_cmds[handle] =
NULL
;
/* Bad payload or header */
if (pkt->entry_status & (BIT_3 + BIT_2)) {
/* Bad payload or header */
if (pkt->entry_status & (BIT_3 + BIT_2)) {