On Thu, Nov 03, 2022 at 04:50:01PM +0800, Ming Lei wrote: > do_splice_direct() has at least two advantages: > > 1) the extra pipe isn't required from user viewpoint, so userspace > code can be simplified, meantime easy to relax current pipe > limit since curret->splice_pipe is used for direct splice > > 2) in some situation, it isn't good to expose file data via > ->splice_read() to userspace, such as the coming ublk driver's > zero copy support, request pages will be spliced to pipe for > supporting zero copy, and if it is READ, userspace may read > data of kernel pages, and direct splice can avoid this kind > of info leaks Please make this a separate opcode instead of overloading the splice op with a flag that causes very different behavior and isn't supported for the regular splice syscall.