From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from bombadil.infradead.org ([198.137.202.133]:39576 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726819AbeIMVVH (ORCPT ); Thu, 13 Sep 2018 17:21:07 -0400 Date: Thu, 13 Sep 2018 09:10:54 -0700 From: Matthew Wilcox To: David Howells Cc: viro@zeniv.linux.org.uk, linux-fsdevel@vger.kernel.org, linux-afs@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 00/10] iov_iter: Add new iters and use with AFS Message-ID: <20180913161054.GB11574@bombadil.infradead.org> References: <153685389564.14766.11306559824641824935.stgit@warthog.procyon.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <153685389564.14766.11306559824641824935.stgit@warthog.procyon.org.uk> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Thu, Sep 13, 2018 at 04:51:35PM +0100, David Howells wrote: > (5) Add an ITER_DISCARD iterator type. This provides an iterator that > simply discards anything written to it. It cannot be used as a data > source. May I suggest an ITER_ZERO iterator type instead? It acts like /dev/zero; writes are discarded (as you have here) and reads return zeroes. I've wanted such a thing in the past, but got distracted away from that project.