ubuntu-linux-kernel/tools/testing/selftests/lib/prime_numbers.sh

17 lines
362 B
Bash
Raw Normal View History

2024-04-01 15:06:58 +00:00
#!/bin/sh
# SPDX-License-Identifier: GPL-2.0
# Checks fast/slow prime_number generation for inconsistencies
if ! /sbin/modprobe -q -r prime_numbers; then
echo "prime_numbers: [SKIP]"
exit 77
fi
if /sbin/modprobe -q prime_numbers selftest=65536; then
/sbin/modprobe -q -r prime_numbers
echo "prime_numbers: ok"
else
echo "prime_numbers: [FAIL]"
exit 1
fi