From: Martin Brandenburg <martin@omnibond.com>
To: linux-fsdevel@vger.kernel.org, devel@lists.orangefs.org
Cc: Martin Brandenburg <martin@omnibond.com>, hubcap@omnibond.com
Subject: [PATCH] orangefs: report attributes_mask and attributes for statx
Date: Fri, 4 May 2018 19:07:52 +0000 [thread overview]
Message-ID: <20180504190752.1704-1-martin@omnibond.com> (raw)
Reported-by: Becky Ligon <ligon@clemson.edu>
Signed-off-by: Martin Brandenburg <martin@omnibond.com>
Cc: hubcap@omnibond.com
---
fs/orangefs/inode.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/fs/orangefs/inode.c b/fs/orangefs/inode.c
index b583fbf90665..f301e4957659 100644
--- a/fs/orangefs/inode.c
+++ b/fs/orangefs/inode.c
@@ -268,6 +268,13 @@ int orangefs_getattr(const struct path *path, struct kstat *stat,
else
stat->result_mask = STATX_BASIC_STATS &
~STATX_SIZE;
+
+ stat->attributes_mask = STATX_ATTR_IMMUTABLE |
+ STATX_ATTR_APPEND;
+ if (inode->i_flags & S_IMMUTABLE)
+ stat->attributes |= STATX_ATTR_IMMUTABLE;
+ if (inode->i_flags & S_APPEND)
+ stat->attributes |= STATX_ATTR_APPEND;
}
return ret;
}
--
2.14.3
next reply other threads:[~2018-05-04 19:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-04 19:07 Martin Brandenburg [this message]
2018-05-07 5:11 ` [PATCH] orangefs: report attributes_mask and attributes for statx Ritesh Harjani
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=20180504190752.1704-1-martin@omnibond.com \
--to=martin@omnibond.com \
--cc=devel@lists.orangefs.org \
--cc=hubcap@omnibond.com \
--cc=linux-fsdevel@vger.kernel.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).