From: Michael Kerrisk <mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Andreas Dilger <adilger-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org>
Cc: David Howells <dhowells-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
samba-technical-w/Ol4Ecudpl8XjKLYN78aQ@public.gmane.org,
linux-ext4-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 3/3] xstat: Implement a requestable extra result to procure some inode flags [ver #4]
Date: Sun, 4 Jul 2010 06:29:46 +0200 [thread overview]
Message-ID: <AANLkTimj6ors03ysxqyuiDcSxEdKqGxTCAppDnV3haTZ@mail.gmail.com> (raw)
In-Reply-To: <C80B6032-0FB2-4D63-B940-3FE86B52992B-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org>
[CC+=linux-api]
On Fri, Jul 2, 2010 at 7:45 PM, Andreas Dilger <adilger-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org> wrote:
> On 2010-07-01, at 17:57, David Howells wrote:
>> [This is, for the moment, to be considered an example. Do we actually want to
>> export these flags? Should they be a full member of struct xstat?]
>
> I would say this should be a full-fledged member of struct xstat.
> I think they are fairly standard (available on many filesystems
> today), and requiring an ioctl to access them is unpleasant.
>
>> (1) User settable flags (to be consistent with the BSD st_flags field):
>>
>> UF_NODUMP Do not dump this file.
>> UF_IMMUTABLE This file is immutable.
>> UF_APPEND This file is append-only.
>> UF_OPAQUE This directory is opaque (unionfs).
>> UF_NOUNLINK This file can't be removed or renamed.
>> UF_COMPRESSED This file is compressed.
>> UF_HIDDEN This file shouldn't be displayed in a GUI.
>>
>> The UF_SETTABLE constant is the union of the above flags.
>>
>> (2) Superuser settable flags (to be consistent with the BSD st_flags field):
>>
>> SF_ARCHIVED This file has been archived.
>> SF_IMMUTABLE This file is immutable.
>> SF_APPEND This file is append-only.
>> SF_NOUNLINK This file can't be removed or renamed.
>> SF_HIDDEN This file is a snapshot inode.
>>
>> The SF_SETTABLE constant is the union of the above flags.
>>
>> (3) Linux-specific flags:
>>
>> XSTAT_LF_MAGIC_FILE Magic file, such as found in procfs and sysfs.
>> XSTAT_LF_SYNC File is written synchronously.
>> XSTAT_LF_NOATIME Atime is not updated on this file.
>> XSTAT_LF_JOURNALLED_DATA Data modifications to this file are journalled.
>> XSTAT_LF_ENCRYPTED This file is encrypted.
>> XSTAT_LF_SYSTEM This file is a system file (FAT/NTFS/CIFS).
>> XSTAT_LF_TEMPORARY This file is a temporary file (NTFS/CIFS).
>> XSTAT_LF_OFFLINE file is currently unavailable (CIFS).
>
> Yuck on the names. Why not stick with the "UF_" and "SF_" prefixes?
> Since we don't need to keep _binary_ compatibility with these flag values
> (only name portability) we can use the same flag values as the
> FS_*_FL definitions in fs.h. That is what all of the existing filesystems
> already use (ext2/3/4, ocfs, btrfs, reiserfs, xfs, jfs).
Agree on the naming. Andreas expresses what I intended when I proposed the idea.
Cheers,
Michael
--
Michael Kerrisk Linux man-pages maintainer;
http://www.kernel.org/doc/man-pages/
Author of "The Linux Programming Interface", http://blog.man7.org/
next prev parent reply other threads:[~2010-07-04 4:29 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-01 23:57 [PATCH 1/3] xstat: Add a pair of system calls to make extended file stats available [ver #4] David Howells
2010-07-01 23:57 ` [PATCH 2/3] xstat: Provide a mechanism to gather extra results for [f]xstat() " David Howells
2010-07-01 23:57 ` [PATCH 3/3] xstat: Implement a requestable extra result to procure some inode flags " David Howells
[not found] ` <20100701235738.19035.21536.stgit-S6HVgzuS8uM4Awkfq6JHfwNdhmdF6hFW@public.gmane.org>
2010-07-02 17:45 ` Andreas Dilger
[not found] ` <C80B6032-0FB2-4D63-B940-3FE86B52992B-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org>
2010-07-04 4:29 ` Michael Kerrisk [this message]
2010-07-04 4:27 ` Michael Kerrisk
2010-07-05 15:05 ` David Howells
[not found] ` <20100701235727.19035.84584.stgit-S6HVgzuS8uM4Awkfq6JHfwNdhmdF6hFW@public.gmane.org>
2010-07-02 11:03 ` [PATCH 1/3] xstat: Add a pair of system calls to make extended file stats available " Nick Piggin
2010-07-02 14:35 ` David Howells
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=AANLkTimj6ors03ysxqyuiDcSxEdKqGxTCAppDnV3haTZ@mail.gmail.com \
--to=mtk.manpages-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
--cc=adilger-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org \
--cc=dhowells-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
--cc=linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-ext4-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=samba-technical-w/Ol4Ecudpl8XjKLYN78aQ@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).