Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965486AbbLOR3I (ORCPT ); Tue, 15 Dec 2015 12:29:08 -0500 Received: from swsoft-msk-nat.sw.ru ([195.214.232.10]:6441 "EHLO sandbox" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S965385AbbLOR3E (ORCPT ); Tue, 15 Dec 2015 12:29:04 -0500 Subject: [PATCH RFC 0/3] Fix splice for packetized pipes From: Stanislav Kinsburskiy To: linux-fsdevel@vger.kernel.org, viro@zeniv.linux.org.uk, linux-kernel@vger.kernel.org Cc: criu@openvz.org, skinsbursky@virtuozzo.com Date: Tue, 15 Dec 2015 21:28:56 +0400 Message-ID: <20151215172356.16355.29361.stgit@localhost.localdomain> User-Agent: StGit/0.17-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1175 Lines: 30 With introduction of packetized pipes, splice wasn't updated to respect this new behaviour. In terms of splice it means, that it never set PIPE_BUF_FLAG_PACKET on created pipe buffer regarless pipe operating mode, thus breaking the whole logic. To fix this, new SPLICE_F_PACKET flag was introduced. It's supposed to be used only in kernel and set, when write pipe is in packetized mode. In splice_to_pipe() it's converted into created pipe buffer PIPE_BUF_FLAG_PACKET flag. The following series implements... --- Stanislav Kinsburskiy (3): pipe: make is_packetized() non-static and declare in pipe_fs_i.h splice: new SPLICE_F_PACKET flag introduced splice: add support of splicing to packetized pipe fs/pipe.c | 2 +- fs/splice.c | 8 ++++++++ include/linux/pipe_fs_i.h | 2 ++ include/linux/splice.h | 5 +++++ 4 files changed, 16 insertions(+), 1 deletion(-) -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/