scsi: qla2xxx: move fields from qla_hw_data to qla_qpair
- Move chip_reset, enable_class_2 fields from qla_hw_data to qla_qpair to reduce cache thrash for target MQ. - Optimizations to reduce unnecessary memory load for good path io. Signed-off-by: Quinn Tran <quinn.tran@cavium.com> Signed-off-by: Himanshu Madhani <himanshu.madhani@cavium.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
committed by
Martin K. Petersen
parent
4b60c82736
commit
7c3f8fd10b
@@ -3252,6 +3252,7 @@ struct qla_qpair {
|
||||
*/
|
||||
spinlock_t *qp_lock_ptr;
|
||||
struct scsi_qla_host *vha;
|
||||
u32 chip_reset;
|
||||
|
||||
/* distill these fields down to 'online=0/1'
|
||||
* ha->flags.eeh_busy
|
||||
@@ -3263,6 +3264,8 @@ struct qla_qpair {
|
||||
uint32_t difdix_supported:1;
|
||||
uint32_t delete_in_progress:1;
|
||||
uint32_t fw_started:1;
|
||||
uint32_t enable_class_2:1;
|
||||
uint32_t enable_explicit_conf:1;
|
||||
|
||||
uint16_t id; /* qp number used with FW */
|
||||
uint16_t vp_idx; /* vport ID */
|
||||
@@ -3296,8 +3299,6 @@ struct scsi_qlt_host {
|
||||
|
||||
struct qlt_hw_data {
|
||||
/* Protected by hw lock */
|
||||
uint32_t enable_class_2:1;
|
||||
uint32_t enable_explicit_conf:1;
|
||||
uint32_t node_name_set:1;
|
||||
|
||||
dma_addr_t atio_dma; /* Physical address. */
|
||||
@@ -3954,7 +3955,6 @@ struct qla_hw_data {
|
||||
struct work_struct board_disable;
|
||||
|
||||
struct mr_data_fx00 mr;
|
||||
uint32_t chip_reset;
|
||||
|
||||
struct qlt_hw_data tgt;
|
||||
int allow_cna_fw_dump;
|
||||
@@ -4247,6 +4247,25 @@ struct qla2_sgx {
|
||||
#define QLA_QPAIR_MARK_NOT_BUSY(__qpair) \
|
||||
atomic_dec(&__qpair->ref_count); \
|
||||
|
||||
|
||||
#define QLA_ENA_CONF(_ha) {\
|
||||
int i;\
|
||||
_ha->base_qpair->enable_explicit_conf = 1; \
|
||||
for (i = 0; i < _ha->max_qpairs; i++) { \
|
||||
if (_ha->queue_pair_map[i]) \
|
||||
_ha->queue_pair_map[i]->enable_explicit_conf = 1; \
|
||||
} \
|
||||
}
|
||||
|
||||
#define QLA_DIS_CONF(_ha) {\
|
||||
int i;\
|
||||
_ha->base_qpair->enable_explicit_conf = 0; \
|
||||
for (i = 0; i < _ha->max_qpairs; i++) { \
|
||||
if (_ha->queue_pair_map[i]) \
|
||||
_ha->queue_pair_map[i]->enable_explicit_conf = 0; \
|
||||
} \
|
||||
}
|
||||
|
||||
/*
|
||||
* qla2x00 local function return status codes
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user