From mboxrd@z Thu Jan 1 00:00:00 1970 From: Al Viro Subject: Re: switch loop and target to use ITER_BVEC iov_iter V2 Date: Mon, 26 Jan 2015 05:10:19 +0000 Message-ID: <20150126051019.GM29656@ZenIV.linux.org.uk> References: <1422216722-27786-1-git-send-email-hch@lst.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Jens Axboe , Nicholas Bellinger , Ming Lei , linux-fsdevel@vger.kernel.org, target-devel@vger.kernel.org To: Christoph Hellwig Return-path: Received: from zeniv.linux.org.uk ([195.92.253.2]:39056 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751001AbbAZFK0 (ORCPT ); Mon, 26 Jan 2015 00:10:26 -0500 Content-Disposition: inline In-Reply-To: <1422216722-27786-1-git-send-email-hch@lst.de> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Sun, Jan 25, 2015 at 09:11:57PM +0100, Christoph Hellwig wrote: > This series adds two new helpers to easily read from and write to > arbitrary iov_iter structures and switches the loop driver and target file > backend to use those with bio_vecs. > > Using bio_vecs directly avoids the need to kmap individual elements in > the callers, which is epecially important in the target driver, and also > gets rid of the horrible splice code abuse hack in the loop driver. > > Changes since V1: > - rebase ontop of viro/for-next > - changed the helpers to read/write any iov_iter, and use > iov_iter_bvec to build those > - return -EINVAL if ->read_iter/->write_iter aren't present > instead of -EBADFD > - use kcalloc in the target patch > - add a patch to rewrite the target WRITE SAME emulation Applied, with iov_iter_bvec() direction argument matching the actual direction of copying intended.