]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
usb: host: ohci-ppc-of: Fix refcount leak bug
authorLiang He <windhl@126.com>
Fri, 17 Jun 2022 03:46:37 +0000 (11:46 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Aug 2022 09:15:43 +0000 (11:15 +0200)
commitec583e300aee9f152a64911445092d18e1c36729
treed29fcd7db936532583547b268c9a1655075ee6ad
parent0543a332e7bec92008e29f8272da67aa6c13575e
usb: host: ohci-ppc-of: Fix refcount leak bug

[ Upstream commit 40a959d7042bb7711e404ad2318b30e9f92c6b9b ]

In ohci_hcd_ppc_of_probe(), of_find_compatible_node() will return
a node pointer with refcount incremented. We should use of_node_put()
when it is not used anymore.

Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Liang He <windhl@126.com>
Link: https://lore.kernel.org/r/20220617034637.4003115-1-windhl@126.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/usb/host/ohci-ppc-of.c