]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
CIFS: Set ->should_dirty in cifs_user_readv()
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 5 May 2017 05:30:40 +0000 (08:30 +0300)
committerSteve French <smfrench@gmail.com>
Tue, 20 Jun 2017 22:57:27 +0000 (17:57 -0500)
The current code causes a static checker warning because ITER_IOVEC is
zero so the condition is never true.

Fixes: 6685c5e2d1ac ("CIFS: Add asynchronous read support through kernel AIO")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Steve French <smfrench@gmail.com>
fs/cifs/file.c

index 0fd081bd2a2f5d3fb4ed18fdcb7a1371cf9f5627..fcef70602b278b48ffd74e97f10d2a57b6968cc3 100644 (file)
@@ -3271,7 +3271,7 @@ ssize_t cifs_user_readv(struct kiocb *iocb, struct iov_iter *to)
        if (!is_sync_kiocb(iocb))
                ctx->iocb = iocb;
 
-       if (to->type & ITER_IOVEC)
+       if (to->type == ITER_IOVEC)
                ctx->should_dirty = true;
 
        rc = setup_aio_ctx_iter(ctx, to, READ);