From mboxrd@z Thu Jan 1 00:00:00 1970 From: Theodore Ts'o Subject: Re: [PATCH 2/7] Define new syscalls readv2,preadv2,writev2,pwritev2 Date: Wed, 17 Sep 2014 12:59:30 -0400 Message-ID: <20140917165930.GA24887@thunk.org> References: <057d758976db2fcce58e394abaa0d55e48cdeec1.1410810247.git.milosz@adfin.com> <20140917154327.GA12190@thunk.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: LKML , Christoph Hellwig , "linux-fsdevel@vger.kernel.org" , linux-aio@kvack.org, Mel Gorman , Volker Lendecke , Tejun Heo , Jeff Moyer To: Milosz Tanski Return-path: Content-Disposition: inline In-Reply-To: Sender: owner-linux-aio@kvack.org List-Id: linux-fsdevel.vger.kernel.org On Wed, Sep 17, 2014 at 12:05:23PM -0400, Milosz Tanski wrote: > Theodore, > > I might be missing understanding something, but... I already omitted > read2 and write2 which can be implemented in userspace by libc (as you > pointed out). In the case of readv vs. preadv there's an extra > positional argument (file offset) and preadv version doesn't change > the file location. I didn't want to overload the meaning of preadv2 to > take a special negative offset value that uses the current file > position but also changes the file position. off_t has to be signed, so having a magic negative value doesn't bother me that much. Or you could use a flag bitvalue which means to use the fd's offset and to ignore the positional value. (More bike-shedding :-) The main reason why I mention it is we have a huge number of read/write syscalls already, and if we add yet another to support scatter-gather lists on the memory side, we'll be adding another factor of two more read/write system calls. So the suggestion was one of trying to (probably fruitlessly) trying to stem the expnoential increase in read/write system calls. :-) Cheers, - Ted -- To unsubscribe, send a message with 'unsubscribe linux-aio' in the body to majordomo@kvack.org. For more info on Linux AIO, see: http://www.kvack.org/aio/ Don't email: aart@kvack.org