mirror of
https://github.com/morgan9e/systemd
synced 2026-04-14 16:37:19 +09:00
test: wait for whole block device instead of partition
In 'udevadm lock' the device /dev/loopX is locked instead of /dev/loopXp1. Hence, 'udevadm wait' should wait for /dev/loopX. For some reasons, the kernel sometimes does not emit uevent for partitions, and 'udevadm wait' for partitions may fail. Fixes #24360.
This commit is contained in:
@@ -40,8 +40,8 @@ label:gpt
|
||||
name="loop${1?}-part1"
|
||||
EOF
|
||||
LOOP=$(losetup -P --show -f "/tmp/testsuite-60-dependencies-${1?}.img")
|
||||
udevadm wait --settle --timeout=10 "${LOOP}p1"
|
||||
udevadm lock --device="${LOOP}p1" mkfs.ext4 -L "partname${1?}-1" "${LOOP}p1"
|
||||
udevadm wait --settle --timeout=10 "${LOOP}"
|
||||
udevadm lock --device="${LOOP}" mkfs.ext4 -L "partname${1?}-1" "${LOOP}p1"
|
||||
}
|
||||
|
||||
check_dependencies() {
|
||||
|
||||
Reference in New Issue
Block a user