aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/ibmvscsi
diff options
context:
space:
mode:
authorBrian King <brking@linux.vnet.ibm.com>2008-11-14 14:33:52 -0500
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2008-12-29 12:24:17 -0500
commit5919ce29085f4ca080054fde5feef8f8b3405261 (patch)
tree22f7b2620d0128fdd91e0244ae6fb73b443c6ba3 /drivers/scsi/ibmvscsi
parent4081b77c3a86151d2eaeed9d568a34dd0982ed52 (diff)
[SCSI] ibmvfc: Fix command timeouts due to cached CRQ access
The CRQs used by the ibmvfc driver are read and written by both the client and the server. Therefore, we need to mark them volatile so that we do not cache their contents when handling an interrupt. This fixes a problem which can surface as occasional command timeouts. No commands were actually timing out, but due to accessing cached data for the CRQ in the interrupt handler, the interrupt was not processing all command completions as it should. Signed-off-by: Brian King <brking@linux.vnet.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/ibmvscsi')
-rw-r--r--drivers/scsi/ibmvscsi/ibmvfc.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/scsi/ibmvscsi/ibmvfc.h b/drivers/scsi/ibmvscsi/ibmvfc.h
index f0c0212a7460..526bca743c81 100644
--- a/drivers/scsi/ibmvscsi/ibmvfc.h
+++ b/drivers/scsi/ibmvscsi/ibmvfc.h
@@ -523,10 +523,10 @@ enum ibmvfc_async_event {
523}; 523};
524 524
525struct ibmvfc_crq { 525struct ibmvfc_crq {
526 u8 valid; 526 volatile u8 valid;
527 u8 format; 527 volatile u8 format;
528 u8 reserved[6]; 528 u8 reserved[6];
529 u64 ioba; 529 volatile u64 ioba;
530}__attribute__((packed, aligned (8))); 530}__attribute__((packed, aligned (8)));
531 531
532struct ibmvfc_crq_queue { 532struct ibmvfc_crq_queue {
@@ -536,13 +536,13 @@ struct ibmvfc_crq_queue {
536}; 536};
537 537
538struct ibmvfc_async_crq { 538struct ibmvfc_async_crq {
539 u8 valid; 539 volatile u8 valid;
540 u8 pad[3]; 540 u8 pad[3];
541 u32 pad2; 541 u32 pad2;
542 u64 event; 542 volatile u64 event;
543 u64 scsi_id; 543 volatile u64 scsi_id;
544 u64 wwpn; 544 volatile u64 wwpn;
545 u64 node_name; 545 volatile u64 node_name;
546 u64 reserved; 546 u64 reserved;
547}__attribute__((packed, aligned (8))); 547}__attribute__((packed, aligned (8)));
548 548