diff options
| author | Jens Arnold <amiconn@rockbox.org> | 2010-05-02 19:38:23 +0000 |
|---|---|---|
| committer | Jens Arnold <amiconn@rockbox.org> | 2010-05-02 19:38:23 +0000 |
| commit | 9a74223f7df26090c3d4e91b00c78912e9d156f9 (patch) | |
| tree | 31a8d7abecc610ee000aa3b0cd9c91c3671d517a | |
| parent | e891e90883fa816536a0b8771ca4b18234d83088 (diff) | |
| download | rockbox-9a74223f7df26090c3d4e91b00c78912e9d156f9.zip rockbox-9a74223f7df26090c3d4e91b00c78912e9d156f9.tar.gz rockbox-9a74223f7df26090c3d4e91b00c78912e9d156f9.tar.bz2 rockbox-9a74223f7df26090c3d4e91b00c78912e9d156f9.tar.xz | |
Test more possible alignments in the Write & Verify test. Some ata drivers apply optimisations up to line size alignment.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25787 a1c6a512-1295-4272-9138-f99709370657
| -rw-r--r-- | apps/plugins/test_disk.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/plugins/test_disk.c b/apps/plugins/test_disk.c index 34cb94d..9d186e0 100644 --- a/apps/plugins/test_disk.c +++ b/apps/plugins/test_disk.c @@ -134,9 +134,9 @@ static bool test_fs(void) total = TEST_SIZE; while (total > 0) { - current = rb->rand() % (audiobuflen - 4); + align = rb->rand() & 0xf; + current = rb->rand() % (audiobuflen - align); current = MIN(current, total); - align = rb->rand() & 3; rb->snprintf(text_buf, sizeof text_buf, "Wrt %dKB, %dKB left", current >> 10, total >> 10); log_text(text_buf, false); @@ -163,9 +163,9 @@ static bool test_fs(void) total = TEST_SIZE; while (total > 0) { - current = rb->rand() % (audiobuflen - 4); + align = rb->rand() & 0xf; + current = rb->rand() % (audiobuflen - align); current = MIN(current, total); - align = rb->rand() & 3; rb->snprintf(text_buf, sizeof text_buf, "Cmp %dKB, %dKB left", current >> 10, total >> 10); log_text(text_buf, false); |