leds: netxbig: add missing put_device() call in netxbig_leds_get_of_pdata()
authorYu Kuai <yukuai3@huawei.com>
Thu, 29 Oct 2020 09:23:05 +0000 (17:23 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 30 Dec 2020 10:53:21 +0000 (11:53 +0100)
commit1687f01f0ea8ff2202b29886c97625f8e13fb48e
treea02f888bdda306008c8e8aa2138dbb4f137135d8
parent4827f0cabc16ab83a6ad5c058d26d966beaef8f2
leds: netxbig: add missing put_device() call in netxbig_leds_get_of_pdata()

[ Upstream commit 311066aa9ebcd6f1789c829da5039ca02f2dfe46 ]

if of_find_device_by_node() succeed, netxbig_leds_get_of_pdata() doesn't
have a corresponding put_device(). Thus add jump target to fix the
exception handling for this function implementation.

Fixes: 2976b1798909 ("leds: netxbig: add device tree binding")
Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Signed-off-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/leds/leds-netxbig.c