Merge branch 'postk_topic-contiguous_pte' into development

* Merge cd7ab307fae9bc8aa49d23b32becf37368a1603e
* Merge commit is changed to one commit for gerrit

Change-Id: I75f0f4cf6b8b3286284638ac2c7816c5257551e4
This commit is contained in:
Dominique Martinet
2019-01-31 11:03:46 +09:00
parent 7f1c17fc4c
commit 6d38c34993
55 changed files with 2757 additions and 17 deletions

View File

@ -0,0 +1,48 @@
#!/bin/sh
# go_contiguous_pte_test.sh COPYRIGHT FUJITSU LIMITED 2018
contiguous_pte_test_dir=$(dirname "${BASH_SOURCE[0]}")
# read config
. ${contiguous_pte_test_dir}/../common.sh
. ${HOME}/.mck_test_config
os_num=0
if [ ! -e "/dev/mcos${os_num}" ]; then
echo "Error: failed to mcreboot"
exit 1
fi
logdir="${contiguous_pte_test_dir}/result"
mkdir -p "$logdir"
# exec test program
user_proc="${contiguous_pte_test_dir}/bin/test_contiguous_pte"
for test_case in `grep -E '^TEST_CASE_DEF' ${contiguous_pte_test_dir}/src/test_case.list`
do
tp_num=`echo $test_case | sed 's|TEST_CASE_DEF(contiguous_pte,||g' | sed 's|)$||g'`
logfile="${logdir}/${tp_num}.log"
# run
echo "${MCEXEC} ${os_num} ${user_proc} -n $tp_num" >${logfile} 2>&1
timeout 20 ${MCEXEC} ${os_num} ${user_proc} -n $tp_num >>${logfile}
rcode=$?
# check result
grep -q "^RESULT: ok$" ${logfile}
if [ $? -eq 0 -a $rcode -eq 0 ]; then
echo "OK: ${tp_num}"
else
echo "NG: ${tp_num}"
echo "==" >>${logfile}
echo "${IHKOSCTL} ${os_num} kmsg" >>${logfile}
sudo ${IHKOSCTL} ${os_num} kmsg >>${logfile}
fi
# restart after madvise system call test
if [ 400 -le $tp_num -a $tp_num -lt 500 ]; then
mcstop
mcreboot
fi
done
mcstop