From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751844AbcEJI0B (ORCPT ); Tue, 10 May 2016 04:26:01 -0400 Received: from mx1.redhat.com ([209.132.183.28]:34199 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751296AbcEJIZ6 (ORCPT ); Tue, 10 May 2016 04:25:58 -0400 Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: <20160510070421.GB30896@infradead.org> References: <20160510070421.GB30896@infradead.org> <20160508083543.GA14316@infradead.org> <20160429125736.23636.47874.stgit@warthog.procyon.org.uk> <20160429125743.23636.85219.stgit@warthog.procyon.org.uk> <31651.1462798652@warthog.procyon.org.uk> To: Christoph Hellwig Cc: dhowells@redhat.com, linux-fsdevel@vger.kernel.org, linux-afs@lists.infradead.org, linux-nfs@vger.kernel.org, samba-technical@lists.samba.org, linux-kernel@vger.kernel.org, linux-ext4@vger.kernel.org Subject: Re: [PATCH 1/6] statx: Add a system call to make enhanced file info available MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <6896.1462868755.1@warthog.procyon.org.uk> Date: Tue, 10 May 2016 09:25:55 +0100 Message-ID: <6897.1462868755@warthog.procyon.org.uk> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Tue, 10 May 2016 08:25:58 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Christoph Hellwig wrote: > > It does what stat() does now, whatever that is for each fs. The > > assumption is that this might be used to emulate stat() from userspace. > > However, we want to be able to make sure we get the two behaviours above. > > And why would you emulate stat if we already have a perfectly working > version of it? Either way we need to document what that behavior is, > and why userspace would chose one of the three options. Because it's not necessarily a perfectly working version of it. See the Y2037 problem for example. I was assuming that C libraries might want to update the struct stat and the stat call() to provide fields that aren't currently there in Linux but are in other OS's. We could even dispense with older stat syscalls on new arches. Admittedly, this means that you would have backwardly incompatible versions of the C library and would have to version your interface, so it might be too much effort. However, if we're going to discard this possibility, we can make these features available only to direct calls of extended stat. David