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:
336eac4
)
fsl/fman: Add a missing 'of_node_put()' call in an error handling path
author
Christophe JAILLET
<
[email protected]
>
Mon, 6 Nov 2017 21:53:31 +0000
(22:53 +0100)
committer
David S. Miller
<
[email protected]
>
Wed, 8 Nov 2017 04:53:33 +0000
(13:53 +0900)
If 'of_phy_find_device()' fails, we must undo the previous 'of_node_get()'
call, as done the the following error handling code.
Signed-off-by: Christophe JAILLET <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
drivers/net/ethernet/freescale/fman/mac.c
patch
|
blob
|
history
diff --git
a/drivers/net/ethernet/freescale/fman/mac.c
b/drivers/net/ethernet/freescale/fman/mac.c
index ca12e28129ed5309a8b4ecb2f0687f5fb1d98991..86c1e69f44d6cdee1f5e94fc2117b95e1ca6ac9f 100644
(file)
--- a/
drivers/net/ethernet/freescale/fman/mac.c
+++ b/
drivers/net/ethernet/freescale/fman/mac.c
@@
-821,6
+821,7
@@
static int mac_probe(struct platform_device *_of_dev)
phy = of_phy_find_device(mac_dev->phy_node);
if (!phy) {
err = -EINVAL;
+ of_node_put(mac_dev->phy_node);
goto _return_of_get_parent;
}