projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e1d9ec3
)
fpga: Fix dead store fpga-mgr.c
author
Tom Rix
<trix@redhat.com>
Mon, 8 Jun 2020 12:54:45 +0000
(
05:54
-0700)
committer
Moritz Fischer
<mdf@kernel.org>
Fri, 19 Jun 2020 01:24:16 +0000
(18:24 -0700)
Using clang's scan-build/view this issue was flagged in fpga-mgr.c
drivers/fpga/fpga-mgr.c:585:3: warning: Value stored to 'ret' is never read [deadcode.DeadStores]
ret = id;
Signed-off-by: Tom Rix <trix@redhat.com>
Signed-off-by: Moritz Fischer <mdf@kernel.org>
drivers/fpga/fpga-mgr.c
patch
|
blob
|
history
diff --git
a/drivers/fpga/fpga-mgr.c
b/drivers/fpga/fpga-mgr.c
index e05104f5e40c6a492608644478bdec2ff150c461..f38bab01432e2eae6a1bc7d7bd541837c488bcb0 100644
(file)
--- a/
drivers/fpga/fpga-mgr.c
+++ b/
drivers/fpga/fpga-mgr.c
@@
-581,10
+581,8
@@
struct fpga_manager *fpga_mgr_create(struct device *dev, const char *name,
return NULL;
id = ida_simple_get(&fpga_mgr_ida, 0, 0, GFP_KERNEL);
- if (id < 0) {
- ret = id;
+ if (id < 0)
goto error_kfree;
- }
mutex_init(&mgr->ref_mutex);