diff options
author | Chad Dupuis <chad.dupuis@qlogic.com> | 2013-01-30 03:34:38 -0500 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2013-02-22 06:29:49 -0500 |
commit | 3c290d0b5f8ff7b0fd2c964c5ec2c14191a9e790 (patch) | |
tree | aeabbf158d1efef3689782c996685a2630de289c /drivers/scsi/qla2xxx/qla_def.h | |
parent | 8d93f5502221cc8eb420da65dc86a5ef07b038d0 (diff) |
[SCSI] qla2xxx: Ramp down queue depth for attached SCSI devices when driver resources are low.
Signed-off-by: Chad Dupuis <chad.dupuis@qlogic.com>
Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_def.h')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_def.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_def.h index a84bb8d6ff74..06c6271d5911 100644 --- a/drivers/scsi/qla2xxx/qla_def.h +++ b/drivers/scsi/qla2xxx/qla_def.h | |||
@@ -2536,6 +2536,7 @@ struct req_que { | |||
2536 | srb_t **outstanding_cmds; | 2536 | srb_t **outstanding_cmds; |
2537 | uint32_t current_outstanding_cmd; | 2537 | uint32_t current_outstanding_cmd; |
2538 | uint16_t num_outstanding_cmds; | 2538 | uint16_t num_outstanding_cmds; |
2539 | #define MAX_Q_DEPTH 32 | ||
2539 | int max_q_depth; | 2540 | int max_q_depth; |
2540 | }; | 2541 | }; |
2541 | 2542 | ||
@@ -3058,6 +3059,12 @@ struct qla_hw_data { | |||
3058 | struct work_struct idc_state_handler; | 3059 | struct work_struct idc_state_handler; |
3059 | struct work_struct nic_core_unrecoverable; | 3060 | struct work_struct nic_core_unrecoverable; |
3060 | 3061 | ||
3062 | #define HOST_QUEUE_RAMPDOWN_INTERVAL (60 * HZ) | ||
3063 | #define HOST_QUEUE_RAMPUP_INTERVAL (30 * HZ) | ||
3064 | unsigned long host_last_rampdown_time; | ||
3065 | unsigned long host_last_rampup_time; | ||
3066 | int cfg_lun_q_depth; | ||
3067 | |||
3061 | struct qlt_hw_data tgt; | 3068 | struct qlt_hw_data tgt; |
3062 | }; | 3069 | }; |
3063 | 3070 | ||
@@ -3117,6 +3124,8 @@ typedef struct scsi_qla_host { | |||
3117 | #define MPI_RESET_NEEDED 19 /* Initiate MPI FW reset */ | 3124 | #define MPI_RESET_NEEDED 19 /* Initiate MPI FW reset */ |
3118 | #define ISP_QUIESCE_NEEDED 20 /* Driver need some quiescence */ | 3125 | #define ISP_QUIESCE_NEEDED 20 /* Driver need some quiescence */ |
3119 | #define SCR_PENDING 21 /* SCR in target mode */ | 3126 | #define SCR_PENDING 21 /* SCR in target mode */ |
3127 | #define HOST_RAMP_DOWN_QUEUE_DEPTH 22 | ||
3128 | #define HOST_RAMP_UP_QUEUE_DEPTH 23 | ||
3120 | 3129 | ||
3121 | uint32_t device_flags; | 3130 | uint32_t device_flags; |
3122 | #define SWITCH_FOUND BIT_0 | 3131 | #define SWITCH_FOUND BIT_0 |