Message ID | 1605346706-23782-1-git-send-email-zou_wei@huawei.com (mailing list archive) |
---|---|
State | Rejected |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [-next] cxgb4: Remove unused variable ret | expand |
Context | Check | Description |
---|---|---|
netdev/cover_letter | success | Link |
netdev/fixes_present | success | Link |
netdev/patch_count | success | Link |
netdev/tree_selection | success | Guessed tree name to be net-next |
netdev/subject_prefix | warning | Target tree name not specified in the subject |
netdev/source_inline | success | Was 0 now: 0 |
netdev/verify_signedoff | success | Link |
netdev/module_param | success | Was 0 now: 0 |
netdev/build_32bit | fail | Errors and warnings before: 0 this patch: 8 |
netdev/kdoc | success | Errors and warnings before: 0 this patch: 0 |
netdev/verify_fixes | success | Link |
netdev/checkpatch | success | total: 0 errors, 0 warnings, 0 checks, 16 lines checked |
netdev/build_allmodconfig_warn | fail | Errors and warnings before: 0 this patch: 8 |
netdev/header_inline | success | Link |
netdev/stable | success | Stable not CCed |
On Sat, 14 Nov 2020 17:38:26 +0800 Zou Wei wrote: > This patch fixes below warning reported by coccicheck: > > ./drivers/net/ethernet/chelsio/cxgb4/t4_hw.c:3284:5-8: Unneeded variable: "ret". Return "0" on line 3301 > > Signed-off-by: Zou Wei <zou_wei@huawei.com> Some macro uses it implicitly, this breaks the build.
diff --git a/drivers/net/ethernet/chelsio/cxgb4/t4_hw.c b/drivers/net/ethernet/chelsio/cxgb4/t4_hw.c index 98d01a7..426d15e 100644 --- a/drivers/net/ethernet/chelsio/cxgb4/t4_hw.c +++ b/drivers/net/ethernet/chelsio/cxgb4/t4_hw.c @@ -3281,8 +3281,6 @@ int t4_get_scfg_version(struct adapter *adapter, u32 *vers) */ int t4_get_version_info(struct adapter *adapter) { - int ret = 0; - #define FIRST_RET(__getvinfo) \ do { \ int __ret = __getvinfo; \ @@ -3298,7 +3296,7 @@ int t4_get_version_info(struct adapter *adapter) FIRST_RET(t4_get_vpd_version(adapter, &adapter->params.vpd_vers)); #undef FIRST_RET - return ret; + return 0; } /**
This patch fixes below warning reported by coccicheck: ./drivers/net/ethernet/chelsio/cxgb4/t4_hw.c:3284:5-8: Unneeded variable: "ret". Return "0" on line 3301 Signed-off-by: Zou Wei <zou_wei@huawei.com> --- drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)