Files
linux/drivers/md
Mikulas Patocka fed13a5478 dm: fix a crash if blk_alloc_disk fails
If blk_alloc_disk fails, the variable md->disk is set to an error value.
cleanup_mapped_device will see that md->disk is non-NULL and it will
attempt to access it, causing a crash on this statement
"md->disk->private_data = NULL;".

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Reported-by: Chenyuan Yang <chenyuan0y@gmail.com>
Closes: https://marc.info/?l=dm-devel&m=172824125004329&w=2
Cc: stable@vger.kernel.org
Reviewed-by: Nitesh Shetty <nj.shetty@samsung.com>
2024-10-15 13:37:17 +02:00
..
2024-04-01 11:53:37 -06:00
2024-09-26 17:27:07 +02:00
2024-06-26 11:32:39 -04:00
2024-05-09 09:10:58 -04:00
2024-02-20 14:22:51 -05:00
2024-06-26 11:32:39 -04:00
2024-02-20 14:22:51 -05:00
2024-09-02 11:41:11 +02:00
2024-07-05 00:42:04 -06:00
2024-10-15 13:37:17 +02:00
2024-09-06 10:31:12 -07:00
2024-03-06 08:59:53 -08:00