Skip to content

Commit f62bf4f

Browse files
krzkgregkh
authored andcommitted
net: hisilicon: hip04: fix OF node leak in probe()
[ Upstream commit 1755529 ] Driver is leaking OF node reference from of_parse_phandle_with_fixed_args() in probe(). Signed-off-by: Krzysztof Kozlowski <[email protected]> Reviewed-by: Simon Horman <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]> Signed-off-by: Sasha Levin <[email protected]>
1 parent 143edf0 commit f62bf4f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/net/ethernet/hisilicon/hip04_eth.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -947,6 +947,7 @@ static int hip04_mac_probe(struct platform_device *pdev)
947947
priv->tx_coalesce_timer.function = tx_done;
948948

949949
priv->map = syscon_node_to_regmap(arg.np);
950+
of_node_put(arg.np);
950951
if (IS_ERR(priv->map)) {
951952
dev_warn(d, "no syscon hisilicon,hip04-ppe\n");
952953
ret = PTR_ERR(priv->map);

0 commit comments

Comments
 (0)