mediatek: mt76: eeprom: fix missing of_node_put() in mt76_find_power_limits_node()
authorLiang He <windhl@126.com>
Mon, 4 Jul 2022 08:34:21 +0000 (16:34 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Aug 2022 12:23:29 +0000 (14:23 +0200)
commitc4ff3cef5d9628f891df70dcfe892acabbee85ce
treea167abd91666e462beec9395815fda73d2aa2333
parentf646d94d7aecc3ab5e89d5f3bdaf59e9349b3b11
mediatek: mt76: eeprom: fix missing of_node_put() in mt76_find_power_limits_node()

[ Upstream commit 3bd53ea02d77917c2314ec7be9e2d05be22f87d3 ]

We should use of_node_put() for the reference 'np' returned by
of_get_child_by_name() which will increase the refcount.

Fixes: 22b980badc0f ("mt76: add functions for parsing rate power limits from DT")
Signed-off-by: Liang He <windhl@126.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/mediatek/mt76/eeprom.c