diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-01-22 16:09:03 +0100 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2019-01-29 06:40:54 +0100 |
commit | fd84ec206d7a0d5a2aa0c3c78868deec6bfcd050 (patch) | |
tree | 733e4d7de95c57a0baf954639d8e36ec25276edc /drivers/scsi/snic/snic_trc.c | |
parent | scsi: fnic: no need to check return value of debugfs_create functions (diff) | |
download | linux-fd84ec206d7a0d5a2aa0c3c78868deec6bfcd050.tar.xz linux-fd84ec206d7a0d5a2aa0c3c78868deec6bfcd050.zip |
scsi: snic: no need to check return value of debugfs_create functions
When calling debugfs functions, there is no need to ever check the return
value. The function can work or not, but the code logic should never do
something different based on this.
Cc: Karan Tilak Kumar <kartilak@cisco.com>
Cc: Sesidhar Baddela <sebaddel@cisco.com>
Cc: "James E.J. Bottomley" <jejb@linux.ibm.com>
Cc: "Martin K. Petersen" <martin.petersen@oracle.com>
Cc: linux-scsi@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/snic/snic_trc.c')
-rw-r--r-- | drivers/scsi/snic/snic_trc.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/scsi/snic/snic_trc.c b/drivers/scsi/snic/snic_trc.c index 458eaba24c78..f23fe2f88438 100644 --- a/drivers/scsi/snic/snic_trc.c +++ b/drivers/scsi/snic/snic_trc.c @@ -138,12 +138,7 @@ snic_trc_init(void) trc->buf = (struct snic_trc_data *) tbuf; spin_lock_init(&trc->lock); - ret = snic_trc_debugfs_init(); - if (ret) { - SNIC_ERR("Failed to create Debugfs Files.\n"); - - goto error; - } + snic_trc_debugfs_init(); trc->max_idx = (tbuf_sz / SNIC_TRC_ENTRY_SZ); trc->rd_idx = trc->wr_idx = 0; @@ -153,11 +148,6 @@ snic_trc_init(void) ret = 0; return ret; - -error: - snic_trc_free(); - - return ret; } /* end of snic_trc_init */ /* |