From: Jeff Layton Subject: Re: why is O_TMPFILE multiplexed over open() instead of being a separate syscall? Date: Fri, 2 Aug 2013 08:59:29 -0400 Message-ID: <20130802085929.635c4f54@corrin.poochiereds.net> References: <20130801084253.GA4727@infradead.org> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: viro@zeniv.linux.org.uk, torvalds@linux-foundation.org, linux-fsdevel@vger.kernel.org To: Christoph Hellwig Return-path: Received: from mx1.redhat.com ([209.132.183.28]:38187 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751487Ab3HBM7O (ORCPT ); Fri, 2 Aug 2013 08:59:14 -0400 In-Reply-To: <20130801084253.GA4727@infradead.org> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Thu, 1 Aug 2013 01:42:53 -0700 Christoph Hellwig wrote: > Sorry for being a bit late to the game, but.. > > Why is the useful tmpfile functionality multiplexed over open when it > has very different semantics from a normal open? > > In addition to the flag problems already discussed to death it also just > leads to splattering of the code in the implementaiton, given that > path_openat branches out really early in path_openat. > > What's the problem with a clear single purpose tmpfile() system call? Agreed. A new syscall for this seems like it would be a lot cleaner. I mentioned that to Al via IRC when he first showed me these patches but he didn't like the idea (I don't recall his rationale though). I probably should have followed that up with an email to the mailing list, but the first public mention of it was the pull request... -- Jeff Layton