From 4d94c275d2344b9231d9dc4585bd42b8e9fb7794 Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Fri, 22 Jun 2007 20:41:27 +0200 Subject: [PATCH] netsplice: use zero-copy if possible Signed-off-by: Jens Axboe --- engines/net.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/engines/net.c b/engines/net.c index a67432bf..bc3946d5 100644 --- a/engines/net.c +++ b/engines/net.c @@ -122,7 +122,7 @@ static int vmsplice_io_u_out(struct thread_data *td, struct io_u *io_u, int bytes = 0; while (iov.iov_len) { - int ret = vmsplice(nd->pipes[0], &iov, 1, 0); + int ret = vmsplice(nd->pipes[0], &iov, 1, SPLICE_F_MOVE); if (ret < 0) { if (!bytes) @@ -153,7 +153,7 @@ static int vmsplice_io_u_in(struct thread_data *td, struct io_u *io_u) unsigned int bytes = 0; while (iov.iov_len) { - int ret = vmsplice(nd->pipes[1], &iov, 1, 0); + int ret = vmsplice(nd->pipes[1], &iov, 1, SPLICE_F_MOVE); if (ret < 0) return -1; -- 2.25.1