# @name SPI Write/Read Performance test
# @desc Erase SPI MTD partition, mount it as ubifs and writes to it
# @requires spi_master/mtd
# @setup_requires spi

SPI_S_PERF_MTD_UBIFS source "common.sh"; install_modules.sh "spi"; blk_device_filesystem_perf_test.sh -f ubifs -s 2 -c 1 -B "262144" -d "spi"

SPI_M_PERF_MTD_UBIFS_2M source "common.sh"; install_modules.sh "spi"; blk_device_filesystem_perf_test.sh -f ubifs -s 2 -c 1 -B "102400 262144 524288 1048576" -d "spi"

SPI_M_PERF_MTD_UBIFS_FOURTH_MTDSIZE source "common.sh"; install_modules.sh "spi"; part=`get_mtd_partition_number.sh "spi"` || die "error getting mtd part number: $part"; size=`get_mtd_size.sh "$part"` || die "error getting mtd size: $size"; size=$(( $size/MB )) && size=`get_ceiling_divide.sh "$size" 4` || die "error getting divide ceiling"; blk_device_filesystem_perf_test.sh -f ubifs -s $size -c 1 -B "262144" -d "spi"




