projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b7d91c9
)
mcb: fix compiler warning logical-op in mcb-parse.c
author
Michael Moese
<
[email protected]
>
Tue, 15 Nov 2016 09:36:51 +0000
(10:36 +0100)
committer
Greg Kroah-Hartman
<
[email protected]
>
Tue, 15 Nov 2016 09:52:37 +0000
(10:52 +0100)
The expression was clearly wrong, the logical AND of expressions
must be changed to a logical OR.
Reported-by: David Binderman <
[email protected]
>
Signed-off-by: Michael Moese <
[email protected]
>
Signed-off-by: Johannes Thumshirn <
[email protected]
>
Signed-off-by: Greg Kroah-Hartman <
[email protected]
>
drivers/mcb/mcb-parse.c
patch
|
blob
|
history
diff --git
a/drivers/mcb/mcb-parse.c
b/drivers/mcb/mcb-parse.c
index 4ca2739b4fad54f0b3c07089f3802d43e75c4e3b..ee7fb6ec96bd17e599905c947e06533b81ce9857 100644
(file)
--- a/
drivers/mcb/mcb-parse.c
+++ b/
drivers/mcb/mcb-parse.c
@@
-149,7
+149,7
@@
static int chameleon_get_bar(char __iomem **base, phys_addr_t mapbase,
reg = readl(*base);
bar_count = BAR_CNT(reg);
- if (bar_count <= 0
&&
bar_count > CHAMELEON_BAR_MAX)
+ if (bar_count <= 0
||
bar_count > CHAMELEON_BAR_MAX)
return -ENODEV;
c = kcalloc(bar_count, sizeof(struct chameleon_bar),