]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
dm_early_create: fix freeing used table on dm_resume failure
authorMikulas Patocka <mpatocka@redhat.com>
Thu, 9 Jul 2026 19:29:11 +0000 (21:29 +0200)
committerMikulas Patocka <mpatocka@redhat.com>
Fri, 10 Jul 2026 12:40:24 +0000 (14:40 +0200)
commit366665416f20527ff7cad548a32d1ddf23195740
treec4e78655f1e1886e6c51291702bd4c7b0a4f4ed7
parent5a266764fadaff8b5c1fe37a186ebf9b09cb953e
dm_early_create: fix freeing used table on dm_resume failure

If dm_resume fails, the kernel attempts to free table with
dm_table_destroy, but the table was already instantiated with
dm_swap_table. This commit skips the call to dm_table_destroy in this
case.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Assisted-by: Claude:claude-opus-4.6
Fixes: 6bbc923dfcf5 ("dm: add support to directly boot to a mapped device")
Cc: stable@vger.kernel.org
drivers/md/dm-ioctl.c