target: remove dead code
Subsystems (2)
PATCH 1/1 target: remove dead code
Local variable _ret_ is assigned to a constant value and it is never updated again. Remove this variable and the dead code it guards.
Addresses-Coverity-ID: 140761
Signed-off-by Gustavo A. R. Silva <[email protected]>
--- drivers/target/target_core_rd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/target/target_core_rd.c +2 -2
@@ -568,7 +568,7 @@ static ssize_t rd_set_configfs_dev_params(struct se_device *dev,struct rd_dev *rd_dev =RD_DEV (dev);char *orig, *ptr, *opts;substring_t args[MAX_OPT_ARGS ]; -int ret =0 , arg, token; +int arg, token; opts =kstrdup (page,GFP_KERNEL );if (!opts)
@@ -603,7 +603,7 @@ static ssize_t rd_set_configfs_dev_params(struct se_device *dev, }kfree (orig); -return (!ret) ? count : ret; +return count; }static ssize_t rd_show_configfs_dev_params (struct se_device *dev,char *b)
Signature · 1 line
2.5.0
Quoted 6 lines · Gustavo A. R. Silva
Local variable _ret_ is assigned to a constant value and it is never updated again. Remove this variable and the dead code it guards.
Addresses-Coverity-ID: 140761
Signed-off-by Gustavo A. R. Silva <[email protected]>---
Reviewed-by Tyrel Datwyler <[email protected]>
Nicholas A. Bellinger
AppliedQuoted 10 lines · Tyrel Datwyler
Quoted 6 lines · Gustavo A. R. Silva
Local variable _ret_ is assigned to a constant value and it is never updated again. Remove this variable and the dead code it guards.
Addresses-Coverity-ID: 140761
Signed-off-by Gustavo A. R. Silva <[email protected]>---
Reviewed-by Tyrel Datwyler <[email protected]>
Applied to target-pending/for-next.
Thanks Gustavo + Tyrel.