Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | |
Simon Glass | 22cc069 | 2015-01-25 08:26:56 -0700 | [diff] [blame] | 3 | die() { |
| 4 | echo $1 |
| 5 | exit 1 |
| 6 | } |
| 7 | |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 8 | NUM_CPUS=$(cat /proc/cpuinfo |grep -c processor) |
| 9 | dtc -I dts -O dtb test/dm/test.dts -o test/dm/test.dtb |
Simon Glass | 22cc069 | 2015-01-25 08:26:56 -0700 | [diff] [blame] | 10 | make O=sandbox sandbox_config || die "Cannot configure U-Boot" |
| 11 | make O=sandbox -s -j${NUM_CPUS} || die "Cannot build U-Boot" |
Simon Glass | ebcab48 | 2014-10-13 23:42:10 -0600 | [diff] [blame] | 12 | dd if=/dev/zero of=spi.bin bs=1M count=2 |
Simon Glass | e00cb22 | 2015-03-25 12:23:05 -0600 | [diff] [blame^] | 13 | echo -n "this is a test" > testflash.bin |
| 14 | dd if=/dev/zero bs=1M count=4 >>testflash.bin |
Simon Glass | 2e7d35d | 2014-02-26 15:59:21 -0700 | [diff] [blame] | 15 | ./sandbox/u-boot -d test/dm/test.dtb -c "dm test" |
Simon Glass | ebcab48 | 2014-10-13 23:42:10 -0600 | [diff] [blame] | 16 | rm spi.bin |
Simon Glass | e00cb22 | 2015-03-25 12:23:05 -0600 | [diff] [blame^] | 17 | rm testflash.bin |