mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-10-24 19:10:26 +00:00
dm table: fix missing dm_put_target_type() in dm_table_add_target()
[ Upstream commitdafa724bf5] dm_get_target_type() was previously called so any error returned from dm_table_add_target() must first call dm_put_target_type(). Otherwise the DM target module's reference count will leak and the associated kernel module will be unable to be removed. Also, leverage the fact that r is already -EINVAL and remove an extra newline. Fixes:36a0456("dm table: add immutable feature") Fixes:cc6cbe1("dm table: add always writeable feature") Fixes:3791e2f("dm table: add singleton feature") Cc: stable@vger.kernel.org # 3.2+ Signed-off-by: tang.junhui <tang.junhui@zte.com.cn> Signed-off-by: Mike Snitzer <snitzer@redhat.com> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
This commit is contained in:
parent
6e64ac0957
commit
f596302c66
1 changed files with 9 additions and 15 deletions
Loading…
Add table
Add a link
Reference in a new issue