Skip to content

Commit c65a43e

Browse files
yoavcohkawasaki
authored andcommitted
ublk: make ublk_ctrl_stop_dev return void
This function always returns 0, so there is no need to return a value. Signed-off-by: Yoav Cohen <[email protected]>
1 parent 0ab4e8c commit c65a43e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/block/ublk_drv.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3304,10 +3304,9 @@ static inline void ublk_ctrl_cmd_dump(struct io_uring_cmd *cmd)
33043304
header->data[0], header->addr, header->len);
33053305
}
33063306

3307-
static int ublk_ctrl_stop_dev(struct ublk_device *ub)
3307+
static void ublk_ctrl_stop_dev(struct ublk_device *ub)
33083308
{
33093309
ublk_stop_dev(ub);
3310-
return 0;
33113310
}
33123311

33133312
static int ublk_ctrl_get_dev_info(struct ublk_device *ub,
@@ -3780,7 +3779,8 @@ static int ublk_ctrl_uring_cmd(struct io_uring_cmd *cmd,
37803779
ret = ublk_ctrl_start_dev(ub, header);
37813780
break;
37823781
case UBLK_CMD_STOP_DEV:
3783-
ret = ublk_ctrl_stop_dev(ub);
3782+
ublk_ctrl_stop_dev(ub);
3783+
ret = 0;
37843784
break;
37853785
case UBLK_CMD_GET_DEV_INFO:
37863786
case UBLK_CMD_GET_DEV_INFO2:

0 commit comments

Comments
 (0)