Skip to content

Commit df70080

Browse files
btw616jmberg-intel
authored andcommitted
um: ubd: Initialize ubd's disk pointer in ubd_add
Currently, the initialization of the disk pointer in the ubd structure is missing. It should be initialized with the allocated gendisk pointer in ubd_add(). Fixes: 32621ad ("ubd: remove the ubd_gendisk array") Signed-off-by: Tiwei Bie <tiwei.btw@antgroup.com> Acked-By: Anton Ivanov <anton.ivanov@cambridgegreys.com> Link: https://patch.msgid.link/20241104163203.435515-2-tiwei.btw@antgroup.com Signed-off-by: Johannes Berg <johannes.berg@intel.com>
1 parent 1d4d0ef commit df70080

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

arch/um/drivers/ubd_kern.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -898,6 +898,8 @@ static int ubd_add(int n, char **error_out)
898898
if (err)
899899
goto out_cleanup_disk;
900900

901+
ubd_dev->disk = disk;
902+
901903
return 0;
902904

903905
out_cleanup_disk:

0 commit comments

Comments
 (0)