test: Add test programs for #1158
refs: #1158 Change-Id: I853dd84f5433a01da510813e9fb1276e5477f73f
This commit is contained in:
committed by
Masamichi Takagi
parent
42b9b31606
commit
ab284b0531
45
test/issues/1158/C1158.sh
Normal file
45
test/issues/1158/C1158.sh
Normal file
@ -0,0 +1,45 @@
|
||||
#!/bin/sh
|
||||
|
||||
USELTP=0
|
||||
USEOSTEST=0
|
||||
|
||||
. ../../common.sh
|
||||
|
||||
tid=001
|
||||
echo "*** CT_$tid start *******************************"
|
||||
tgt_file=`find /sys/devices/ -name local_cpus | head -n 1`
|
||||
echo "[Linux ] cat ${tgt_file}"
|
||||
cat ${tgt_file} | tee ./CT_${tid}_lnx.txt
|
||||
echo "[McKernel] mcexec cat ${tgt_file}"
|
||||
${MCEXEC} cat ${tgt_file} | tee ./CT_${tid}_mck.txt
|
||||
|
||||
diff ./CT_${tid}_lnx.txt ./CT_${tid}_mck.txt &> /dev/null
|
||||
|
||||
if [ $? == 0 ]; then
|
||||
echo "[OK] local_cpus is same between Linux and McKernel"
|
||||
echo "*** CT_$tid: PASSED"
|
||||
else
|
||||
echo "[NG] local_cpus is NOT same between Linux and McKernel"
|
||||
echo "*** CT_$tid: FAILED"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
tid=002
|
||||
echo "*** CT_$tid start *******************************"
|
||||
tgt_file=`find /sys/devices/ -name local_cpulist | head -n 1`
|
||||
echo "[Linux ] cat ${tgt_file}"
|
||||
cat ${tgt_file} | tee ./CT_${tid}_lnx.txt
|
||||
echo "[McKernel] mcexec cat ${tgt_file}"
|
||||
${MCEXEC} cat ${tgt_file} | tee ./CT_${tid}_mck.txt
|
||||
|
||||
diff ./CT_${tid}_lnx.txt ./CT_${tid}_mck.txt &> /dev/null
|
||||
|
||||
if [ $? == 0 ]; then
|
||||
echo "[OK] local_cpulist is same between Linux and McKernel"
|
||||
echo "*** CT_$tid: PASSED"
|
||||
else
|
||||
echo "[NG] local_cpulist is NOT same between Linux and McKernel"
|
||||
echo "*** CT_$tid: FAILED"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
Reference in New Issue
Block a user