summaryrefslogtreecommitdiff
path: root/drivers/cpuidle
diff options
context:
space:
mode:
authorYang Yingliang <yangyingliang@huawei.com>2022-10-31 15:13:40 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-11-10 20:14:19 +0300
commite77d213843e67b4373285712699b692f9c743f61 (patch)
treedbd7a8c7c720667fb6130d7caf2d65b4635a2807 /drivers/cpuidle
parentf06186e5271b980bac03f5c97276ed0146ddc9b0 (diff)
downloadlinux-e77d213843e67b4373285712699b692f9c743f61.tar.xz
mISDN: fix possible memory leak in mISDN_register_device()
[ Upstream commit e7d1d4d9ac0dfa40be4c2c8abd0731659869b297 ] Afer commit 1fa5ae857bb1 ("driver core: get rid of struct device's bus_id string array"), the name of device is allocated dynamically, add put_device() to give up the reference, so that the name can be freed in kobject_cleanup() when the refcount is 0. Set device class before put_device() to avoid null release() function WARN message in device_release(). Fixes: 1fa5ae857bb1 ("driver core: get rid of struct device's bus_id string array") Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/cpuidle')
0 files changed, 0 insertions, 0 deletions