]> www.infradead.org Git - mtd-utils.git/commitdiff
fs-tests: integck: fsync more often
authorArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Tue, 17 May 2011 03:25:32 +0000 (06:25 +0300)
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Fri, 20 May 2011 09:48:42 +0000 (12:48 +0300)
Currently integck calls 'fsync()' very rarely - with 0.1% probability. Make
this happen more often - with 1% probability.

Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
tests/fs-tests/integrity/integck.c

index 221bd4985e004a1935ca56006b3dee4be15b4022..81d384f64ef972966e332abd60fdce4d40e30d23 100644 (file)
@@ -1269,7 +1269,7 @@ static int file_write(struct file_info *file, int fd)
        }
 
        /* Sync sometimes */
-       if (random_no(1000) >= 999) {
+       if (random_no(100) >= 99) {
                if (random_no(100) >= 50) {
                        ret = fsync(fd);
                        if (ret)