diff options
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_bsg.c | 2 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_gbl.h | 1 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_init.c | 18 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_mbx.c | 2 |
4 files changed, 12 insertions, 11 deletions
diff --git a/drivers/scsi/qla2xxx/qla_bsg.c b/drivers/scsi/qla2xxx/qla_bsg.c index 6146d392eeb5..10942fc9808d 100644 --- a/drivers/scsi/qla2xxx/qla_bsg.c +++ b/drivers/scsi/qla2xxx/qla_bsg.c | |||
@@ -103,7 +103,7 @@ qla24xx_proc_fcp_prio_cfg_cmd(struct fc_bsg_job *bsg_job) | |||
103 | 103 | ||
104 | bsg_job->reply->reply_payload_rcv_len = 0; | 104 | bsg_job->reply->reply_payload_rcv_len = 0; |
105 | 105 | ||
106 | if (!IS_QLA24XX_TYPE(ha) || !IS_QLA25XX(ha)) { | 106 | if (!(IS_QLA24XX_TYPE(ha) || IS_QLA25XX(ha))) { |
107 | ret = -EINVAL; | 107 | ret = -EINVAL; |
108 | goto exit_fcp_prio_cfg; | 108 | goto exit_fcp_prio_cfg; |
109 | } | 109 | } |
diff --git a/drivers/scsi/qla2xxx/qla_gbl.h b/drivers/scsi/qla2xxx/qla_gbl.h index 1370f05ae330..c228d248cf17 100644 --- a/drivers/scsi/qla2xxx/qla_gbl.h +++ b/drivers/scsi/qla2xxx/qla_gbl.h | |||
@@ -70,6 +70,7 @@ extern void qla2x00_async_adisc_done(struct scsi_qla_host *, fc_port_t *, | |||
70 | extern void qla2x00_async_tm_cmd_done(struct scsi_qla_host *, fc_port_t *, | 70 | extern void qla2x00_async_tm_cmd_done(struct scsi_qla_host *, fc_port_t *, |
71 | struct srb_iocb *); | 71 | struct srb_iocb *); |
72 | extern void *qla2x00_alloc_iocbs(struct scsi_qla_host *, srb_t *); | 72 | extern void *qla2x00_alloc_iocbs(struct scsi_qla_host *, srb_t *); |
73 | extern int qla24xx_update_fcport_fcp_prio(scsi_qla_host_t *, fc_port_t *); | ||
73 | 74 | ||
74 | extern fc_port_t * | 75 | extern fc_port_t * |
75 | qla2x00_alloc_fcport(scsi_qla_host_t *, gfp_t ); | 76 | qla2x00_alloc_fcport(scsi_qla_host_t *, gfp_t ); |
diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c index e9b800e72559..c8ca25a8f2c2 100644 --- a/drivers/scsi/qla2xxx/qla_init.c +++ b/drivers/scsi/qla2xxx/qla_init.c | |||
@@ -2928,6 +2928,7 @@ qla2x00_update_fcport(scsi_qla_host_t *vha, fc_port_t *fcport) | |||
2928 | fcport->flags &= ~(FCF_LOGIN_NEEDED | FCF_ASYNC_SENT); | 2928 | fcport->flags &= ~(FCF_LOGIN_NEEDED | FCF_ASYNC_SENT); |
2929 | 2929 | ||
2930 | qla2x00_iidma_fcport(vha, fcport); | 2930 | qla2x00_iidma_fcport(vha, fcport); |
2931 | qla24xx_update_fcport_fcp_prio(vha, fcport); | ||
2931 | qla2x00_reg_remote_port(vha, fcport); | 2932 | qla2x00_reg_remote_port(vha, fcport); |
2932 | atomic_set(&fcport->state, FCS_ONLINE); | 2933 | atomic_set(&fcport->state, FCS_ONLINE); |
2933 | } | 2934 | } |
@@ -5473,7 +5474,7 @@ qla81xx_update_fw_options(scsi_qla_host_t *vha) | |||
5473 | * the tag (priority) value is returned. | 5474 | * the tag (priority) value is returned. |
5474 | * | 5475 | * |
5475 | * Input: | 5476 | * Input: |
5476 | * ha = adapter block po | 5477 | * vha = scsi host structure pointer. |
5477 | * fcport = port structure pointer. | 5478 | * fcport = port structure pointer. |
5478 | * | 5479 | * |
5479 | * Return: | 5480 | * Return: |
@@ -5567,7 +5568,7 @@ qla24xx_get_fcp_prio(scsi_qla_host_t *vha, fc_port_t *fcport) | |||
5567 | * Activates fcp priority for the logged in fc port | 5568 | * Activates fcp priority for the logged in fc port |
5568 | * | 5569 | * |
5569 | * Input: | 5570 | * Input: |
5570 | * ha = adapter block pointer. | 5571 | * vha = scsi host structure pointer. |
5571 | * fcp = port structure pointer. | 5572 | * fcp = port structure pointer. |
5572 | * | 5573 | * |
5573 | * Return: | 5574 | * Return: |
@@ -5577,25 +5578,24 @@ qla24xx_get_fcp_prio(scsi_qla_host_t *vha, fc_port_t *fcport) | |||
5577 | * Kernel context. | 5578 | * Kernel context. |
5578 | */ | 5579 | */ |
5579 | int | 5580 | int |
5580 | qla24xx_update_fcport_fcp_prio(scsi_qla_host_t *ha, fc_port_t *fcport) | 5581 | qla24xx_update_fcport_fcp_prio(scsi_qla_host_t *vha, fc_port_t *fcport) |
5581 | { | 5582 | { |
5582 | int ret; | 5583 | int ret; |
5583 | uint8_t priority; | 5584 | uint8_t priority; |
5584 | uint16_t mb[5]; | 5585 | uint16_t mb[5]; |
5585 | 5586 | ||
5586 | if (atomic_read(&fcport->state) == FCS_UNCONFIGURED || | 5587 | if (fcport->port_type != FCT_TARGET || |
5587 | fcport->port_type != FCT_TARGET || | 5588 | fcport->loop_id == FC_NO_LOOP_ID) |
5588 | fcport->loop_id == FC_NO_LOOP_ID) | ||
5589 | return QLA_FUNCTION_FAILED; | 5589 | return QLA_FUNCTION_FAILED; |
5590 | 5590 | ||
5591 | priority = qla24xx_get_fcp_prio(ha, fcport); | 5591 | priority = qla24xx_get_fcp_prio(vha, fcport); |
5592 | ret = qla24xx_set_fcp_prio(ha, fcport->loop_id, priority, mb); | 5592 | ret = qla24xx_set_fcp_prio(vha, fcport->loop_id, priority, mb); |
5593 | if (ret == QLA_SUCCESS) | 5593 | if (ret == QLA_SUCCESS) |
5594 | fcport->fcp_prio = priority; | 5594 | fcport->fcp_prio = priority; |
5595 | else | 5595 | else |
5596 | DEBUG2(printk(KERN_WARNING | 5596 | DEBUG2(printk(KERN_WARNING |
5597 | "scsi(%ld): Unable to activate fcp priority, " | 5597 | "scsi(%ld): Unable to activate fcp priority, " |
5598 | " ret=0x%x\n", ha->host_no, ret)); | 5598 | " ret=0x%x\n", vha->host_no, ret)); |
5599 | 5599 | ||
5600 | return ret; | 5600 | return ret; |
5601 | } | 5601 | } |
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c index effd8a1403d9..04d6cfc2e919 100644 --- a/drivers/scsi/qla2xxx/qla_mbx.c +++ b/drivers/scsi/qla2xxx/qla_mbx.c | |||
@@ -4125,7 +4125,7 @@ qla24xx_set_fcp_prio(scsi_qla_host_t *vha, uint16_t loop_id, uint16_t priority, | |||
4125 | return QLA_FUNCTION_FAILED; | 4125 | return QLA_FUNCTION_FAILED; |
4126 | 4126 | ||
4127 | DEBUG11(printk(KERN_INFO | 4127 | DEBUG11(printk(KERN_INFO |
4128 | "%s(%ld): entered.\n", __func__, ha->host_no)); | 4128 | "%s(%ld): entered.\n", __func__, vha->host_no)); |
4129 | 4129 | ||
4130 | mcp->mb[0] = MBC_PORT_PARAMS; | 4130 | mcp->mb[0] = MBC_PORT_PARAMS; |
4131 | mcp->mb[1] = loop_id; | 4131 | mcp->mb[1] = loop_id; |