Server IP : 15.235.198.142 / Your IP : 216.73.216.14 Web Server : Apache/2.4.58 (Ubuntu) System : Linux ballsack 6.8.0-45-generic #45-Ubuntu SMP PREEMPT_DYNAMIC Fri Aug 30 12:02:04 UTC 2024 x86_64 User : www-data ( 33) PHP Version : 8.3.6 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /usr/lib/modules/6.8.0-45-generic/build/tools/testing/selftests/damon/ |
Upload File : |
#!/bin/bash # SPDX-License-Identifier: GPL-2.0 test_write_result() { file=$1 content=$2 orig_content=$3 expect_reason=$4 expected=$5 echo "$content" > "$file" if [ $? -ne "$expected" ] then echo "writing $content to $file doesn't return $expected" echo "expected because: $expect_reason" echo "$orig_content" > "$file" exit 1 fi } test_write_succ() { test_write_result "$1" "$2" "$3" "$4" 0 } test_write_fail() { test_write_result "$1" "$2" "$3" "$4" 1 } test_content() { file=$1 orig_content=$2 expected=$3 expect_reason=$4 content=$(cat "$file") if [ "$content" != "$expected" ] then echo "reading $file expected $expected but $content" echo "expected because: $expect_reason" echo "$orig_content" > "$file" exit 1 fi } source ./_chk_dependency.sh damon_onoff="$DBGFS/monitor_on" if [ $(cat "$damon_onoff") = "on" ] then echo "monitoring is on" exit $ksft_skip fi