aboutsummaryrefslogtreecommitdiffstats
path: root/lib/fuse_lowlevel.c
diff options
context:
space:
mode:
authorBernd Schubert <bschubert@ddn.com>2025-05-28 15:13:47 +0200
committerBernd Schubert <bernd@bsbernd.com>2025-08-22 23:07:24 +0200
commitd52ae4f9d44d7e08375bfacac0bc7cc02ad1b54b (patch)
tree4a0e084061d7e5305c4eee54ce062118eeda3854 /lib/fuse_lowlevel.c
parent253ea916fd5122e1c182cb3ffbff1ac2eeea3991 (diff)
downloadlibfuse-d52ae4f9d44d7e08375bfacac0bc7cc02ad1b54b.tar.gz
Allow applications to retrieve the req payload (io-uring only)
With io-uring the req owns the payload buffer, the application can directly access it and copy data into it. fuse_buf_copy_one() already has a check for dstmem == srcmem and skips data copies. fuse_reply_data fuse_reply_data_uring fuse_buf_copy fuse_buf_copy_one Signed-off-by: Bernd Schubert <bschubert@ddn.com>
Diffstat (limited to 'lib/fuse_lowlevel.c')
-rw-r--r--lib/fuse_lowlevel.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c
index 6afcecd..e4544df 100644
--- a/lib/fuse_lowlevel.c
+++ b/lib/fuse_lowlevel.c
@@ -3317,6 +3317,18 @@ bool fuse_req_is_uring(fuse_req_t req)
return req->is_uring;
}
+#ifndef HAVE_URING
+int fuse_req_get_payload(fuse_req_t req, char **payload, size_t *payload_sz,
+ void **mr)
+{
+ (void)req;
+ (void)payload;
+ (void)payload_sz;
+ (void)mr;
+ return -ENOTSUP;
+}
+#endif
+
static struct {
void (*func)(fuse_req_t req, const fuse_ino_t node, const void *arg);
const char *name;