[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 014/111] vitriofsd/passthrough_ll: fix fallocate() ifdefs
From: |
Dr. David Alan Gilbert (git) |
Subject: |
[PULL 014/111] vitriofsd/passthrough_ll: fix fallocate() ifdefs |
Date: |
Thu, 23 Jan 2020 11:57:04 +0000 |
From: Xiao Yang <address@hidden>
1) Use correct CONFIG_FALLOCATE macro to check if fallocate() is supported.(i.e
configure
script sets CONFIG_FALLOCATE intead of HAVE_FALLOCATE if fallocate() is
supported)
2) Replace HAVE_POSIX_FALLOCATE with CONFIG_POSIX_FALLOCATE.
Signed-off-by: Xiao Yang <address@hidden>
Signed-off-by: Dr. David Alan Gilbert <address@hidden>
Merged from two of Xiao Yang's patches
---
tools/virtiofsd/passthrough_ll.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/virtiofsd/passthrough_ll.c b/tools/virtiofsd/passthrough_ll.c
index 322a889cdf..6c4da18075 100644
--- a/tools/virtiofsd/passthrough_ll.c
+++ b/tools/virtiofsd/passthrough_ll.c
@@ -975,13 +975,13 @@ static void lo_fallocate(fuse_req_t req, fuse_ino_t ino,
int mode, off_t offset,
int err = EOPNOTSUPP;
(void)ino;
-#ifdef HAVE_FALLOCATE
+#ifdef CONFIG_FALLOCATE
err = fallocate(fi->fh, mode, offset, length);
if (err < 0) {
err = errno;
}
-#elif defined(HAVE_POSIX_FALLOCATE)
+#elif defined(CONFIG_POSIX_FALLOCATE)
if (mode) {
fuse_reply_err(req, EOPNOTSUPP);
return;
--
2.24.1
- [PULL 002/111] virtiofsd: Pull in kernel's fuse.h, (continued)
- [PULL 002/111] virtiofsd: Pull in kernel's fuse.h, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 008/111] virtiofsd: remove mountpoint dummy argument, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 003/111] virtiofsd: Add auxiliary .c's, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 010/111] virtiofsd: Remove unused enum fuse_buf_copy_flags, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 006/111] virtiofsd: Trim down imported files, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 009/111] virtiofsd: remove unused notify reply support, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 011/111] virtiofsd: Fix fuse_daemonize ignored return values, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 005/111] virtiofsd: Add passthrough_ll, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 013/111] virtiofsd: Trim out compatibility code, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 001/111] virtiofsd: Pull in upstream headers, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 014/111] vitriofsd/passthrough_ll: fix fallocate() ifdefs,
Dr. David Alan Gilbert (git) <=
- [PULL 004/111] virtiofsd: Add fuse_lowlevel.c, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 015/111] virtiofsd: Make fsync work even if only inode is passed in, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 020/111] virtiofsd: Add main virtio loop, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 012/111] virtiofsd: Fix common header and define for QEMU builds, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 018/111] virtiofsd: Open vhost connection instead of mounting, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 016/111] virtiofsd: Add options for virtio, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 023/111] virtiofsd: Poll kick_fd for queue, Dr. David Alan Gilbert (git), 2020/01/23
- [PULL 025/111] virtiofsd: Send replies to messages, Dr. David Alan Gilbert (git), 2020/01/23