Commit ba1b464f authored by Miaoqian Lin's avatar Miaoqian Lin Committed by Zheng Zengkai
Browse files

powerpc/spufs: Fix refcount leak in spufs_init_isolated_loader

stable inclusion
from stable-v5.10.137
commit 85aff6a9b7b7ec4e5c319f7946c9864c8d5e3d4a
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I60PLB

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=85aff6a9b7b7ec4e5c319f7946c9864c8d5e3d4a



--------------------------------

[ Upstream commit 6ac059da ]

of_find_node_by_path() returns remote device nodepointer with
refcount incremented, we should use of_node_put() on it when done.
Add missing of_node_put() to avoid refcount leak.

Fixes: 0afacde3 ("[POWERPC] spufs: allow isolated mode apps by starting the SPE loader")
Signed-off-by: default avatarMiaoqian Lin <linmq006@gmail.com>
Acked-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220603121543.22884-1-linmq006@gmail.com


Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarZheng Zengkai <zhengzengkai@huawei.com>
Reviewed-by: default avatarWei Li <liwei391@huawei.com>
parent 003ff18d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment