• Jens Axboe's avatar
    Revert "io_uring: Require zeroed sqe->len on provided-buffers send" · 641a6816
    Jens Axboe authored
    This reverts commit 79996b45.
    
    Revert the change that restricts a send provided buffer to be zero, so
    it will always consume the whole buffer. This is strictly needed for
    partial consumption, as the send may very well be a subset of the
    current buffer. In fact, that's the intended use case.
    
    For non-incremental provided buffer rings, an application should set
    sqe->len carefully to avoid the potential issue described in the
    reverted commit. It is recommended that '0' still be set for len for
    that case, if the application is set on maintaining more than 1 send
    inflight for the same socket. This is somewhat of a nonsensical thing
    to do.
    Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
    641a6816
net.c 44.8 KB