From a6f62c0219cfd2c38d4dff0aeb9f6558db336aed Mon Sep 17 00:00:00 2001 From: Alex Levin Date: Wed, 19 Apr 2017 00:00:04 -0700 Subject: [PATCH] EDMA[Tests]: 1. Make some small changes to the test so it will not exit on a read failure. 2. chmod +x run_unit_test.sh --- .../edma/unit-test/mt_read_write.c | 12 +++++++++--- .../edma/unit-test/run_unit_test.sh | 0 2 files changed, 9 insertions(+), 3 deletions(-) mode change 100644 => 100755 sdk/linux_kernel_drivers/edma/unit-test/run_unit_test.sh diff --git a/sdk/linux_kernel_drivers/edma/unit-test/mt_read_write.c b/sdk/linux_kernel_drivers/edma/unit-test/mt_read_write.c index ba205f553..75decca4d 100644 --- a/sdk/linux_kernel_drivers/edma/unit-test/mt_read_write.c +++ b/sdk/linux_kernel_drivers/edma/unit-test/mt_read_write.c @@ -1,4 +1,4 @@ -#include +#include #include #include #include @@ -86,7 +86,10 @@ void* doWrite(void *arg) printf("wrote %u bytes\n", ret); if(ret != write_size) - exit(1); + { + printf("write ret value was %d\n", ret); + ret = 0; + } offset += ret; written_no_fsync += ret; @@ -138,7 +141,10 @@ void* doRead(void *arg) printf("\nRead %d bytes \n", ret, size_of_data); if(ret != read_size) - exit(2); + { + printf("Read ret value was %d\n", ret); + ret = 0; + } offset += ret; diff --git a/sdk/linux_kernel_drivers/edma/unit-test/run_unit_test.sh b/sdk/linux_kernel_drivers/edma/unit-test/run_unit_test.sh old mode 100644 new mode 100755