File Index
Files and directories
Sign in
FILE

test_loop_06.sh

File preview with syntax highlighting.

linux-6.19.14/tools/testing/selftests/ublk/test_loop_06.sh BASH
 1#!/bin/bash
 2# SPDX-License-Identifier: GPL-2.0
 3
 4. "$(cd "$(dirname "$0")" && pwd)"/test_common.sh
 5
 6TID="loop_06"
 7ERR_CODE=0
 8
 9if ! _have_program fio; then
10	exit "$UBLK_SKIP_CODE"
11fi
12
13_prep_test "loop" "write and verify over user copy"
14
15_create_backfile 0 256M
16dev_id=$(_add_ublk_dev -t loop -u "${UBLK_BACKFILES[0]}")
17_check_add_dev $TID $?
18
19# run fio over the ublk disk
20_run_fio_verify_io --filename=/dev/ublkb"${dev_id}" --size=256M
21ERR_CODE=$?
22
23_cleanup_test "loop"
24
25_show_result $TID $ERR_CODE
~/ Read-only file preview.