aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla4xxx/ql4_isr.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/qla4xxx/ql4_isr.c')
-rw-r--r--drivers/scsi/qla4xxx/ql4_isr.c23
1 files changed, 15 insertions, 8 deletions
diff --git a/drivers/scsi/qla4xxx/ql4_isr.c b/drivers/scsi/qla4xxx/ql4_isr.c
index c196d55eae39..596c3031483c 100644
--- a/drivers/scsi/qla4xxx/ql4_isr.c
+++ b/drivers/scsi/qla4xxx/ql4_isr.c
@@ -97,7 +97,7 @@ qla4xxx_status_cont_entry(struct scsi_qla_host *ha,
97 97
98 /* Place command on done queue. */ 98 /* Place command on done queue. */
99 if (srb->req_sense_len == 0) { 99 if (srb->req_sense_len == 0) {
100 qla4xxx_srb_compl(ha, srb); 100 kref_put(&srb->srb_ref, qla4xxx_srb_compl);
101 ha->status_srb = NULL; 101 ha->status_srb = NULL;
102 } 102 }
103} 103}
@@ -329,7 +329,7 @@ status_entry_exit:
329 /* complete the request, if not waiting for status_continuation pkt */ 329 /* complete the request, if not waiting for status_continuation pkt */
330 srb->cc_stat = sts_entry->completionStatus; 330 srb->cc_stat = sts_entry->completionStatus;
331 if (ha->status_srb == NULL) 331 if (ha->status_srb == NULL)
332 qla4xxx_srb_compl(ha, srb); 332 kref_put(&srb->srb_ref, qla4xxx_srb_compl);
333} 333}
334 334
335/** 335/**
@@ -393,7 +393,7 @@ static void qla4xxx_process_response_queue(struct scsi_qla_host * ha)
393 /* ETRY normally by sending it back with 393 /* ETRY normally by sending it back with
394 * DID_BUS_BUSY */ 394 * DID_BUS_BUSY */
395 srb->cmd->result = DID_BUS_BUSY << 16; 395 srb->cmd->result = DID_BUS_BUSY << 16;
396 qla4xxx_srb_compl(ha, srb); 396 kref_put(&srb->srb_ref, qla4xxx_srb_compl);
397 break; 397 break;
398 398
399 case ET_CONTINUE: 399 case ET_CONTINUE:
@@ -498,15 +498,22 @@ static void qla4xxx_isr_decode_mailbox(struct scsi_qla_host * ha,
498 break; 498 break;
499 499
500 case MBOX_ASTS_LINK_UP: 500 case MBOX_ASTS_LINK_UP:
501 DEBUG2(printk("scsi%ld: AEN %04x Adapter LINK UP\n",
502 ha->host_no, mbox_status));
503 set_bit(AF_LINK_UP, &ha->flags); 501 set_bit(AF_LINK_UP, &ha->flags);
502 if (test_bit(AF_INIT_DONE, &ha->flags))
503 set_bit(DPC_LINK_CHANGED, &ha->dpc_flags);
504
505 DEBUG2(printk(KERN_INFO "scsi%ld: AEN %04x Adapter"
506 " LINK UP\n", ha->host_no,
507 mbox_status));
504 break; 508 break;
505 509
506 case MBOX_ASTS_LINK_DOWN: 510 case MBOX_ASTS_LINK_DOWN:
507 DEBUG2(printk("scsi%ld: AEN %04x Adapter LINK DOWN\n",
508 ha->host_no, mbox_status));
509 clear_bit(AF_LINK_UP, &ha->flags); 511 clear_bit(AF_LINK_UP, &ha->flags);
512 set_bit(DPC_LINK_CHANGED, &ha->dpc_flags);
513
514 DEBUG2(printk(KERN_INFO "scsi%ld: AEN %04x Adapter"
515 " LINK DOWN\n", ha->host_no,
516 mbox_status));
510 break; 517 break;
511 518
512 case MBOX_ASTS_HEARTBEAT: 519 case MBOX_ASTS_HEARTBEAT:
@@ -831,7 +838,7 @@ void qla4xxx_process_aen(struct scsi_qla_host * ha, uint8_t process_aen)
831 qla4xxx_reinitialize_ddb_list(ha); 838 qla4xxx_reinitialize_ddb_list(ha);
832 } else if (mbox_sts[1] == 1) { /* Specific device. */ 839 } else if (mbox_sts[1] == 1) { /* Specific device. */
833 qla4xxx_process_ddb_changed(ha, mbox_sts[2], 840 qla4xxx_process_ddb_changed(ha, mbox_sts[2],
834 mbox_sts[3]); 841 mbox_sts[3], mbox_sts[4]);
835 } 842 }
836 break; 843 break;
837 } 844 }