Re: [PATCH v2] fs/splice: don't block splice_direct_to_actor() after data was read

From: Christian Brauner
Date: Tue Sep 26 2023 - 06:22:01 EST


> + /*
> + * After at least one byte was read from the input
> + * file, don't wait for blocking I/O in the following
> + * loop iterations; instead of blocking for arbitrary
> + * amounts of time in the kernel, let userspace decide
> + * how to proceed. This avoids excessive latency if
> + * the output is being consumed faster than the input
> + * file can fill it (e.g. sendfile() from a slow hard
> + * disk to a fast network).
> + */
> + flags |= SPLICE_F_NOWAIT;
> +

Hm, so the thing that is worrysome about this change is that this may
cause regressions afaict as this is a pretty significant change from
current behavior.