Request migrates from fiq to fpq for awhile it is out of revocation lists.
So, we must recheck revoke status.

The bug is old.

Affects: #VSTOR-100953

Signed-off-by: Alexey Kuznetsov <kuz...@virtuozzo.com>
---
 fs/fuse/dev.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/fs/fuse/dev.c b/fs/fuse/dev.c
index 118613f..b437b8d 100644
--- a/fs/fuse/dev.c
+++ b/fs/fuse/dev.c
@@ -1421,6 +1421,15 @@ static ssize_t fuse_dev_do_read(struct fuse_dev *fud, 
struct file *file,
                goto out_end;
 
        }
+       if (args->page_cache && args->inode) {
+               struct fuse_inode *fi = get_fuse_inode(args->inode);
+
+               if (test_bit(FUSE_I_INVAL_FILES, &fi->state) || args->killed) {
+                       req->out.h.error = -EIO;
+                       err = -EAGAIN;
+                       goto out_end;
+               }
+       }
        list_add(&req->list, &fpq->io);
        spin_unlock(&fpq->lock);
        cs->req = req;
-- 
1.8.3.1

_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel

Reply via email to