Thread (5 messages) flat view 5 messages, 4 authors, 2018-10-20

Re: [PATCH v2 6/5] statx: add STATX_RESULT_MASK flag

From: Andreas Dilger <hidden>
Date: 2018-10-20 14:04:27
Also in: linux-fsdevel, lkml

On Oct 19, 2018, at 11:42 AM, Miklos Szeredi [off-list ref] wrote:
quoted
quoted
+#define STATX_RESULT_MASK STATX__RESERVED
Please don't use that bit.
Using it internally is perfectly harmless.   If we'll need to extend
statx in the future and make use of this flag externally, then we can
easily move the internal flag somewhere else (e.g. extend request_mask
to 64bit, which we'll probably need to do anyway in that case).
I was thinking about this - what is the point of returning an error
if STATX__RESERVED is set?  If this is used to indicate the presence
of e.g. stx_mask2, then newer applications trying to request any of the
flags encoded into stx_mask2 will get an error, rather than the expected
behaviour of "ignore flags you don't understand, and don't set them in
the return stx_mask".

Essentially, this will make STATX__RESERVED useless in the future, since
no application will be able to use it without getting an error if they
are running on an old kernel.

Cheers, Andreas




Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help