]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
mfd: core: Fix device reference leak in mfd_clone_cell
authorJohan Hovold <johan@kernel.org>
Tue, 1 Nov 2016 10:38:18 +0000 (11:38 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 10 Feb 2017 10:04:00 +0000 (11:04 +0100)
commit26b5a4a56fd60530d0ab3b51a7fda5841d4f9316
tree0c012ffa4eac509a0f7c1f86bd5aef2993608189
parent479ce88b0d2a0abe07d9c8da8cf80a5eef626831
mfd: core: Fix device reference leak in mfd_clone_cell

commit 722f191080de641f023feaa7d5648caf377844f5 upstream.

Make sure to drop the reference taken by bus_find_device_by_name()
before returning from mfd_clone_cell().

Fixes: a9bbba996302 ("mfd: add platform_device sharing support for mfd")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Willy Tarreau <w@1wt.eu>
drivers/mfd/mfd-core.c