UPSTREAM: ANDROID: fuse-bpf: Make compile with CONFIG_FUSE but no CONFIG_FUSE_BPF

Fixes: ANDROID: fuse-bpf: Fix perms on readdir
Test: Builds with and without CONFIG_FUSE_BPF
Bug: 202785178
Signed-off-by: Paul Lawrence <paullawrence@google.com>
Change-Id: If8b4603dd6f4bd159bfd68fc61c377dcb62ebcd0
This commit is contained in:
Paul Lawrence 2022-01-11 21:31:18 +00:00 • committed by Alexander Martinz
commit 711aab4fc8
No known key found for this signature in database
GPG key ID: CF15BDD9A321A9B2

View file

@ -1566,8 +1566,10 @@ static int fuse_permission(struct inode *inode, int mask)
if (!err && !(inode->i_mode & S_IXUGO))
return -EACCES;
}
#ifdef CONFIG_FUSE_BPF
} else if (!(mask & MAY_NOT_BLOCK) && fi->backing_inode) {
err = fuse_access(inode, mask);
#endif
}
return err;
}