]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
udf: Remove useless check in udf_adinicb_write_begin()
authorJan Kara <jack@suse.cz>
Tue, 6 Sep 2016 16:04:40 +0000 (18:04 +0200)
committerJan Kara <jack@suse.cz>
Tue, 6 Sep 2016 16:04:40 +0000 (18:04 +0200)
As Al properly points out, len is guaranteed to be smaller than
PAGE_SIZE when we reach udf_adinicb_write_begin() as otherwise we would
have converted the file to the normal format.

Reported-by: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: Jan Kara <jack@suse.cz>
fs/udf/file.c

index 632570617327564ce9ed1c8f7aaf757c1e2c543a..254bc02d7e2c307822e840135aa1f607ebe049c1 100644 (file)
@@ -94,7 +94,7 @@ static int udf_adinicb_write_begin(struct file *file,
                return -ENOMEM;
        *pagep = page;
 
-       if (!PageUptodate(page) && len != PAGE_SIZE)
+       if (!PageUptodate(page))
                __udf_adinicb_readpage(page);
        return 0;
 }