projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fefed8a
)
net: hostess_sv11: move out assignment in if condition
author
Peng Li
<lipeng321@huawei.com>
Fri, 18 Jun 2021 02:32:19 +0000
(10:32 +0800)
committer
David S. Miller
<davem@davemloft.net>
Fri, 18 Jun 2021 18:42:39 +0000
(11:42 -0700)
Should not use assignment in if condition.
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/wan/hostess_sv11.c
patch
|
blob
|
history
diff --git
a/drivers/net/wan/hostess_sv11.c
b/drivers/net/wan/hostess_sv11.c
index
a18c09d
..
8dce8b1
100644
(file)
--- a/
drivers/net/wan/hostess_sv11.c
+++ b/
drivers/net/wan/hostess_sv11.c
@@
-340,7
+340,8
@@
static struct z8530_dev *sv11_unit;
int init_module(void)
{
- if ((sv11_unit = sv11_init(io, irq)) == NULL)
+ sv11_unit = sv11_init(io, irq);
+ if (!sv11_unit)
return -ENODEV;
return 0;
}