csiostor : Add maintainer & code cleanup
cover csiostor : Add maintainer & code cleanup
Patches adds Praveen Madhavan as maintainer for the csiostor driver and cleans up dead code in the csiostor driver.
Applies on e56f698bd072 ('blk-mq: set default timeout as 30 seconds') at hare/scsi-devel master
Anish Bhatt (2):
scsi : Add maintainer for csiostor driver
csiostor : Remove __CSIO_DEBUG__ dead code
MAINTAINERS | 7 +++++++ drivers/scsi/csiostor/csio_attr.c | 2 +- drivers/scsi/csiostor/csio_defs.h | 8 +------- drivers/scsi/csiostor/csio_hw.c | 2 +- drivers/scsi/csiostor/csio_hw.h | 6 +----- drivers/scsi/csiostor/csio_mb.c | 2 +- drivers/scsi/csiostor/csio_rnode.c | 4 ++-- drivers/scsi/csiostor/csio_scsi.c | 2 -- 8 files changed, 14 insertions(+), 19 deletions(-)
Signature · 1 line
2.5.1
PATCH 1/2 Add maintainer for csiostor driver
Add Praveen Madhavan as maintainer for Chelsio FCoE driver (csiostor)
--- MAINTAINERS | 7 +++++++ 1 file changed, 7 insertions(+)
MAINTAINERS +7 -0
@@ -2641,6 +2641,13 @@ M: Joe Perches <[email protected]> S: Maintained F: scripts/checkpatch.pl +CHELSIO FCOE SCSI DRIVER +M: Praveen Madhavan <[email protected]> +L: [email protected] +W: http://www.chelsio.com +S: Supported +F: drivers/scsi/csiostor/ + CHINESE DOCUMENTATION M: Harry Wei <[email protected]> L: [email protected] (subscribers-only)
Signature · 1 line
2.5.1
PATCH 2/2 csiostor : Remove __CSIO_DEBUG__ dead code
In reply to Anish BhattCode guarded by __CSIO_DEBUG__ was dead code, fix via csio_dbg now direcly calling dev_dbg, so output can be controlled by changing kernel log level.
This dead code also enabled many BUG_ON() calls, use the preferred WARN_ON() for any debug-only asserts instead.
--- drivers/scsi/csiostor/csio_attr.c | 2 +- drivers/scsi/csiostor/csio_defs.h | 8 +------- drivers/scsi/csiostor/csio_hw.c | 2 +- drivers/scsi/csiostor/csio_hw.h | 6 +----- drivers/scsi/csiostor/csio_mb.c | 2 +- drivers/scsi/csiostor/csio_rnode.c | 4 ++-- drivers/scsi/csiostor/csio_scsi.c | 2 -- 7 files changed, 7 insertions(+), 19 deletions(-)
drivers/scsi/csiostor/csio_attr.c +1 -1
@@ -71,7 +71,7 @@ csio_reg_rnode(struct csio_rnode *rn)if (rn->role &CSIO_RNFR_INITIATOR || rn->role &CSIO_RNFR_TARGET ) { rport = rn->rport; -CSIO_ASSERT (rport !=NULL ); +BUG_ON (!rport); goto update_role; }
drivers/scsi/csiostor/csio_defs.h +1 -7
@@ -110,12 +110,6 @@ csio_match_state(void *smp, void *state) return (csio_get_state(smp) == (csio_sm_state_t)state); } -#define CSIO_ASSERT (cond) BUG_ON(!(cond)) - -#ifdef __CSIO_DEBUG__ -#define CSIO_DB_ASSERT (__c) CSIO_ASSERT((__c)) -#else -#define CSIO_DB_ASSERT (__c) -#endif +#define CSIO_DB_ASSERT (cond) WARN_ON(!(cond))#endif /* ifndef __CSIO_DEFS_H__ */
drivers/scsi/csiostor/csio_hw.c +1 -1
@@ -735,7 +735,7 @@ csio_hw_fw_dload(struct csio_hw *hw, uint8_t *fw_data, uint32_t size) goto out;csio_dbg (hw,"Writing Flash .. start:%d end:%d\n" , -FW_IMG_START ,FW_IMG_START + size); +FLASH_FW_START ,FLASH_FW_START + size); addr =FLASH_FW_START ;for (size -=SF_PAGE_SIZE ; size; size -=SF_PAGE_SIZE ) {
drivers/scsi/csiostor/csio_hw.h +1 -5
@@ -562,12 +562,8 @@ csio_us_to_core_ticks(struct csio_hw *hw, uint32_t us)#define csio_warn (__hw, __fmt, ...) \ dev_warn(&(__hw)->pdev->dev, __fmt, ##__VA_ARGS__) -#ifdef __CSIO_DEBUG__#define csio_dbg (__hw, __fmt, ...) \ - csio_info((__hw), __fmt, ##__VA_ARGS__); -#else -#define csio_dbg (__hw, __fmt, ...) -#endif + dev_dbg(&(__hw)->pdev->dev, __fmt, ##__VA_ARGS__);int csio_hw_wait_op_done_val (struct csio_hw *,int ,uint32_t ,int ,int ,int ,uint32_t *);
drivers/scsi/csiostor/csio_mb.c +1 -1
@@ -1511,7 +1511,7 @@ csio_mb_isr_handler(struct csio_hw *hw)#endif } -CSIO_ASSERT (mbp !=NULL ); +BUG_ON (!mbp); cmd = mbp->mb; size = mbp->mb_size;
drivers/scsi/csiostor/csio_rnode.c +2 -2
@@ -363,7 +363,7 @@ csio_confirm_rnode(struct csio_lnode *ln, uint32_t rdev_flowid,"rnode is already" "active ssni:x%x\n" , rdev_flowid); -CSIO_ASSERT (0 ); +BUG (); }csio_rn_flowid (rn) =CSIO_INVALID_IDX ; rn = match_rn;
@@ -401,7 +401,7 @@ csio_confirm_rnode(struct csio_lnode *ln, uint32_t rdev_flowid,"wwpn:%llx ssni:x%x\n" ,wwn_to_u64 (csio_rn_wwpn (rn)), rdev_flowid); -CSIO_ASSERT (0 ); +BUG (); }csio_rn_flowid (rn) =CSIO_INVALID_IDX ; goto alloc_rnode;
drivers/scsi/csiostor/csio_scsi.c +0 -2
@@ -552,9 +552,7 @@ csio_scsi_write(struct csio_ioreq *req)static inline void csio_setup_ddp (struct csio_scsim *scsim,struct csio_ioreq *req) { -#ifdef __CSIO_DEBUG__struct csio_hw *hw = req->lnode->hwp; -#endif struct scatterlist *sgel =NULL ;struct scsi_cmnd *scmnd =csio_scsi_cmnd (req);uint64_t sg_addr =0 ;
Signature · 1 line
2.5.1