]> xenbits.xensource.com Git - xentesttools/bootstrap.git/commitdiff
isolinux/rcS: Add 'test=cpu-low' and 'test=cpu-high' test-cases
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Tue, 29 Apr 2014 13:50:32 +0000 (09:50 -0400)
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Tue, 29 Apr 2014 13:50:32 +0000 (09:50 -0400)
The first will consume one CPU by spinning around and
doing md5sum of the memory. The later will do this on
all of the CPUs.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
boot/isolinux/isolinux.cfg
root_image/etc/init.d/rcS

index dc3bf2df9b333968c6b1a92cf5c1111dc72ccf5f..50ca10e705c4d2db5c1490983bcb136325f246f6 100755 (executable)
@@ -10,6 +10,17 @@ LABEL Network test
        KERNEL vmlinuz
        APPEND initrd=initramf.gz  console=ttyS0,115200 test=net nofb
 
+LABEL One-CPU burn
+       MENU LABEL One-CPU
+       KERNEL vmlinuz
+       APPEND initrd=initramf.gz  console=ttyS0,115200 test=cpu-low nofb
+
+LABEL All-CPU burn
+       MENU LABEL All-CPU
+       KERNEL vmlinuz
+       APPEND initrd=initramf.gz  console=ttyS0,115200 test=cpu-high nofb
+
+
 LABEL Static Network test
        MENU LABEL Static Network test
        KERNEL vmlinuz
index 17ced11fd43ed3a4ba2786c1fef7422a46494776..e890ef9290569ae78010a239d750a8c1068bb42f 100755 (executable)
@@ -147,6 +147,20 @@ if [ $? == 0 ]; then
                        while (true); do dfbtest_fillrect; done &
                        NOFB="yes"
                        ;;
+               cpu-low)
+                       while (true); do md5sum /dev/mem; done &
+                       ;;
+               cpu-high)
+                       echo -n "Launching CPU burners for $NR_CPUS"
+                       for cpu in `seq 1 $NR_CPUS`
+                       do
+                               echo "while (true); do md5sum /dev/mem; done" > /tmp/cpu$cpu
+                               chmod 755 /tmp/cpu$cpu
+                               echo -n "."
+                               nohup bash /tmp/cpu$cpu 1>/dev/null 2>/dev/null &
+                       done
+                       echo "done!"
+                       ;;
                net)
                        netserver &
                        iperf -s -D -w 256000 &