Skip to content

Commit fe2230d

Browse files
Ming Leiaxboe
authored andcommitted
selftests: ublk: don't show modprobe failure
ublk_drv may be built-in, so don't show modprobe failure, and we do check `/dev/ublk-control` for skipping test if ublk_drv isn't enabled. Reported-by: Jens Axboe <axboe@kernel.dk> Signed-off-by: Ming Lei <ming.lei@redhat.com> Link: https://lore.kernel.org/r/20250320013743.4167489-3-ming.lei@redhat.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent 8764c1a commit fe2230d

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

tools/testing/selftests/ublk/test_common.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ _check_root() {
6464

6565
_remove_ublk_devices() {
6666
${UBLK_PROG} del -a
67-
modprobe -r ublk_drv
67+
modprobe -r ublk_drv > /dev/null 2>&1
6868
}
6969

7070
_get_ublk_dev_state() {
@@ -79,7 +79,7 @@ _prep_test() {
7979
_check_root
8080
local type=$1
8181
shift 1
82-
modprobe ublk_drv
82+
modprobe ublk_drv > /dev/null 2>&1
8383
[ "$UBLK_TEST_QUIET" -eq 0 ] && echo "ublk $type: $*"
8484
}
8585

0 commit comments

Comments
 (0)