Yang Yingliang bb75a0d122 hwmon: (coretemp) fix pci device refcount leak in nv1a_ram_new()
[ Upstream commit 7dec14537c5906b8bf40fd6fd6d9c3850f8df11d ]

As comment of pci_get_domain_bus_and_slot() says, it returns
a pci device with refcount increment, when finish using it,
the caller must decrement the reference count by calling
pci_dev_put(). So call it after using to avoid refcount leak.

Fixes: 14513ee696a0 ("hwmon: (coretemp) Use PCI host bridge ID to identify CPU if necessary")
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Link: https://lore.kernel.org/r/20221118093303.214163-1-yangyingliang@huawei.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-12-08 11:15:41 +01:00
..
2015-05-31 22:58:36 -07:00
2014-08-04 07:01:35 -07:00
2016-09-13 07:27:34 -07:00
2014-08-04 07:01:36 -07:00
2014-08-05 19:44:42 -07:00
2014-08-04 07:01:35 -07:00
2016-03-05 06:25:34 -08:00
2014-08-04 07:01:35 -07:00
2014-08-04 07:01:35 -07:00
2016-09-08 21:34:16 -07:00
2014-01-29 20:40:08 +01:00
2014-01-29 20:40:08 +01:00
2017-01-12 11:39:25 +01:00
2015-08-10 23:00:10 -07:00
2015-06-21 22:54:53 -07:00