diff options
| author | Dick Kennedy <[email protected]> | 2020-06-30 14:49:48 -0700 |
|---|---|---|
| committer | Martin K. Petersen <[email protected]> | 2020-07-02 23:06:33 -0400 |
| commit | e5fcb81d40d44d3000e5ff8b6c9d87ea36a26faa (patch) | |
| tree | b97b677e8590a0d7ed92af84a50b211c3ff63126 /tools/perf/scripts | |
| parent | 9f2475fe7406b8ef5f97099c4980021344872d9f (diff) | |
scsi: lpfc: Fix unused assignment in lpfc_sli4_bsg_link_diag_test
Coverity reported the following error:
Assigned value that is never used may represent unnecessary computation.
The rc variable was initially assigned a value but in several cases, when
an error case is detected, it is reassigned a new value. The initial value
had little use.
In code-reviewing this routine, it could use some cleanup:
- Setting the initialization value to -ENODEV is a much better choice and
lessens code in the routine.
- The wasn't tracking logic errors vs no error and mailbox failure.
Better to resolve by adding a status to track the mailbox failure
and merge it with the logic error when the routine returns.
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Dick Kennedy <[email protected]>
Signed-off-by: James Smart <[email protected]>
Signed-off-by: Martin K. Petersen <[email protected]>
Diffstat (limited to 'tools/perf/scripts')
0 files changed, 0 insertions, 0 deletions