[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3 4/4] stat: support statx DONT_SYNC and FORCE_SYNC flags

From: Pádraig Brady
Subject: Re: [PATCH v3 4/4] stat: support statx DONT_SYNC and FORCE_SYNC flags
Date: Mon, 29 Apr 2019 09:40:27 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

On 23/04/19 04:59, Jeff Layton wrote:
>> +#if HAVE_STATX && defined STATX_INO
>> +      fputs (_("\
>> +  -D, --dont-sync       don't synchronize with server (for network fs')\n\
>> +  -F, --force-sync      force synchronization with server (for network 
>> fs')\n\
>> +"), stdout);
>> +#endif
>>        fputs (_("\
>>    -c  --format=FORMAT   use the specified FORMAT instead of the default;\n\
>>                            output a newline after each use of FORMAT\n\
>> @@ -1916,7 +1937,7 @@ main (int argc, char *argv[])
>>    atexit (close_stdout);
>> -  while ((c = getopt_long (argc, argv, "c:fLt", long_options, NULL)) != -1)
>> +  while ((c = getopt_long (argc, argv, "c:DfFLt", long_options, NULL)) != 
>> -1)
> Hmm...we'll probably want to use a different string if HAVE_STATX is
> not defined. Fixed in my tree, but I'll refrain from resending until I
> get some other feedback on this.
> BTW, ping on this? I'd like to know whether this patchset is
> reasonable, as I was planning to use this functionality to write some
> tests for cephfs.

If we need a flag to control this at all, it should probably be
a single long format option with parameters, and no corresponding short option.
Also we want to avoid the ambiguity of implying a (data) sync is invoked.
Perhaps something like:


In general I think the statx interface is useful,
as file systems are tending to be more distributed over time.

I was thinking that statx could be emulated with stat where necessary,
and we could move that implementation from stat.c to gl/lib/ to gnulib/
if statx has enough advantages for general use.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]