diff options
author | Suganath Prabu <suganath-prabu.subramani@broadcom.com> | 2018-10-31 16:23:32 +0300 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2018-11-07 04:16:01 +0300 |
commit | 02abcbc25a06cdbb93bd60ceeb062b8445dae0ff (patch) | |
tree | c13ca4dd479df214143eb5878df0047c3b268e28 /drivers/scsi/mpt3sas/mpt3sas_ctl.c | |
parent | 6c2938f7bfd937280f71973600b1bed615d997b5 (diff) | |
download | linux-02abcbc25a06cdbb93bd60ceeb062b8445dae0ff.tar.xz |
scsi: mpt3sas: Added new #define variable IOC_OPERATIONAL_WAIT_COUNT
Added new #define variable IOC_OPERATIONAL_WAIT_COUNT and it replaces hard
coded value '10' in all the places where driver is waiting for the IOC to
become operational.
Signed-off-by: Suganath Prabu <suganath-prabu.subramani@broadcom.com>
Reviewed-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/mpt3sas/mpt3sas_ctl.c')
-rw-r--r-- | drivers/scsi/mpt3sas/mpt3sas_ctl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/mpt3sas/mpt3sas_ctl.c b/drivers/scsi/mpt3sas/mpt3sas_ctl.c index 4afa597cbfba..a285e95c9ae4 100644 --- a/drivers/scsi/mpt3sas/mpt3sas_ctl.c +++ b/drivers/scsi/mpt3sas/mpt3sas_ctl.c @@ -669,7 +669,7 @@ _ctl_do_mpt_command(struct MPT3SAS_ADAPTER *ioc, struct mpt3_ioctl_command karg, wait_state_count = 0; ioc_state = mpt3sas_base_get_iocstate(ioc, 1); while (ioc_state != MPI2_IOC_STATE_OPERATIONAL) { - if (wait_state_count++ == 10) { + if (wait_state_count++ == IOC_OPERATIONAL_WAIT_COUNT) { ioc_err(ioc, "%s: failed due to ioc not operational\n", __func__); ret = -EFAULT; |