diff options
author | Manoj Kumar <kumarmn@us.ibm.com> | 2015-10-21 20:11:00 (GMT) |
---|---|---|
committer | James Bottomley <JBottomley@Odin.com> | 2015-10-30 07:57:55 (GMT) |
commit | 3ebf203093b4ee07d62ef1a02dbbf7a293770388 (patch) | |
tree | 0740b929e699e3098a677755b80a199a08b1e858 /drivers/scsi/cxlflash/superpipe.h | |
parent | fa4aa632da19fba0154b66a50329acd738304291 (diff) | |
download | linux-3ebf203093b4ee07d62ef1a02dbbf7a293770388.tar.xz |
cxlflash: Replace magic numbers with literals
Magic numbers are not meaningful and can create confusion. As a
remedy, replace them with descriptive literals.
Replace 512 with literal MAX_SECTOR_UNIT.
Replace 5 with literal CMD_RETRIES.
Signed-off-by: Matthew R. Ochs <mrochs@linux.vnet.ibm.com>
Signed-off-by: Manoj N. Kumar <manoj@linux.vnet.ibm.com>
Reviewed-by: Brian King <brking@linux.vnet.ibm.com>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Reviewed-by: Tomas Henzl <thenzl@redhat.com>
Signed-off-by: James Bottomley <JBottomley@Odin.com>
Diffstat (limited to 'drivers/scsi/cxlflash/superpipe.h')
-rw-r--r-- | drivers/scsi/cxlflash/superpipe.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/scsi/cxlflash/superpipe.h b/drivers/scsi/cxlflash/superpipe.h index d7dc88b..3f7856b 100644 --- a/drivers/scsi/cxlflash/superpipe.h +++ b/drivers/scsi/cxlflash/superpipe.h @@ -29,6 +29,9 @@ extern struct cxlflash_global global; #define MC_CHUNK_SIZE (1 << MC_RHT_NMASK) /* in LBAs */ #define MC_DISCOVERY_TIMEOUT 5 /* 5 secs */ +#define CMD_RETRIES 5 /* 5 retries for scsi_execute */ + +#define MAX_SECTOR_UNIT 512 /* max_sector is in 512 byte multiples */ #define CHAN2PORT(_x) ((_x) + 1) #define PORT2CHAN(_x) ((_x) - 1) |