Commit 3c397400 authored by Seokmann Ju's avatar Seokmann Ju Committed by James Bottomley

[SCSI] qla2xxx: Revert "qla2xxx: Use proper HA during asynchronous event handling."

This reverts commit bd2a1846.
The original (prior to the reverted commit) code was correct.
Additionally, the vp_idx should be checked during MBA_PORT_UPDATE
in order for proper handling to take place for a given vport.
Signed-off-by: default avatarSeokmann Ju <seokmann.ju@qlogic.com>
Signed-off-by: default avatarAndrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@HansenPartnership.com>
parent ca61668b
...@@ -272,8 +272,6 @@ qla2x00_async_event(scsi_qla_host_t *ha, uint16_t *mb) ...@@ -272,8 +272,6 @@ qla2x00_async_event(scsi_qla_host_t *ha, uint16_t *mb)
uint32_t rscn_entry, host_pid; uint32_t rscn_entry, host_pid;
uint8_t rscn_queue_index; uint8_t rscn_queue_index;
unsigned long flags; unsigned long flags;
scsi_qla_host_t *vha;
int i;
/* Setup to process RIO completion. */ /* Setup to process RIO completion. */
handle_cnt = 0; handle_cnt = 0;
...@@ -544,18 +542,10 @@ qla2x00_async_event(scsi_qla_host_t *ha, uint16_t *mb) ...@@ -544,18 +542,10 @@ qla2x00_async_event(scsi_qla_host_t *ha, uint16_t *mb)
break; break;
case MBA_PORT_UPDATE: /* Port database update */ case MBA_PORT_UPDATE: /* Port database update */
if ((ha->flags.npiv_supported) && (ha->num_vhosts)) { /* Only handle SCNs for our Vport index. */
for_each_mapped_vp_idx(ha, i) { if (ha->parent && ha->vp_idx != (mb[3] & 0xff))
list_for_each_entry(vha, &ha->vp_list,
vp_list) {
if ((mb[3] & 0xff)
== vha->vp_idx) {
ha = vha;
break; break;
}
}
}
}
/* /*
* If PORT UPDATE is global (recieved LIP_OCCURED/LIP_RESET * If PORT UPDATE is global (recieved LIP_OCCURED/LIP_RESET
* event etc. earlier indicating loop is down) then process * event etc. earlier indicating loop is down) then process
...@@ -590,18 +580,12 @@ qla2x00_async_event(scsi_qla_host_t *ha, uint16_t *mb) ...@@ -590,18 +580,12 @@ qla2x00_async_event(scsi_qla_host_t *ha, uint16_t *mb)
break; break;
case MBA_RSCN_UPDATE: /* State Change Registration */ case MBA_RSCN_UPDATE: /* State Change Registration */
if ((ha->flags.npiv_supported) && (ha->num_vhosts)) { /* Check if the Vport has issued a SCR */
for_each_mapped_vp_idx(ha, i) { if (ha->parent && test_bit(VP_SCR_NEEDED, &ha->vp_flags))
list_for_each_entry(vha, &ha->vp_list, break;
vp_list) { /* Only handle SCNs for our Vport index. */
if ((mb[3] & 0xff) if (ha->parent && ha->vp_idx != (mb[3] & 0xff))
== vha->vp_idx) {
ha = vha;
break; break;
}
}
}
}
DEBUG2(printk("scsi(%ld): Asynchronous RSCR UPDATE.\n", DEBUG2(printk("scsi(%ld): Asynchronous RSCR UPDATE.\n",
ha->host_no)); ha->host_no));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment