From: James Simmons <jsimmons@infradead.org>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
devel@driverdev.osuosl.org,
Andreas Dilger <andreas.dilger@intel.com>,
Oleg Drokin <oleg.drokin@intel.com>, NeilBrown <neilb@suse.com>
Cc: James Simmons <uja.ornl@yahoo.com>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Lustre Development List <lustre-devel@lists.lustre.org>
Subject: [lustre-devel] [PATCH 18/22] staging: lustre: llite: style changes in xattr.c
Date: Mon, 16 Apr 2018 00:15:07 -0400 [thread overview]
Message-ID: <1523852111-17321-19-git-send-email-jsimmons@infradead.org> (raw)
In-Reply-To: <1523852111-17321-1-git-send-email-jsimmons@infradead.org>
Small style changes to match more the kernel code standard
and it make it more readable.
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-9183
Reviewed-on: https://review.whamcloud.com/27240
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Sebastien Buisson <sbuisson@ddn.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: James Simmons <jsimmons@infradead.org>
---
drivers/staging/lustre/lustre/llite/xattr.c | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/drivers/staging/lustre/lustre/llite/xattr.c b/drivers/staging/lustre/lustre/llite/xattr.c
index 835d00f..d08bf1e 100644
--- a/drivers/staging/lustre/lustre/llite/xattr.c
+++ b/drivers/staging/lustre/lustre/llite/xattr.c
@@ -81,11 +81,10 @@ static int xattr_type_filter(struct ll_sb_info *sbi,
return 0;
}
-static int
-ll_xattr_set_common(const struct xattr_handler *handler,
- struct dentry *dentry, struct inode *inode,
- const char *name, const void *value, size_t size,
- int flags)
+static int ll_xattr_set_common(const struct xattr_handler *handler,
+ struct dentry *dentry, struct inode *inode,
+ const char *name, const void *value, size_t size,
+ int flags)
{
struct ll_sb_info *sbi = ll_i2sbi(inode);
struct ptlrpc_request *req = NULL;
@@ -139,9 +138,9 @@ static int xattr_type_filter(struct ll_sb_info *sbi,
fullname = kasprintf(GFP_KERNEL, "%s%s", handler->prefix, name);
if (!fullname)
return -ENOMEM;
- rc = md_setxattr(sbi->ll_md_exp, ll_inode2fid(inode),
- valid, fullname, pv, size, 0, flags,
- ll_i2suppgid(inode), &req);
+
+ rc = md_setxattr(sbi->ll_md_exp, ll_inode2fid(inode), valid, fullname,
+ pv, size, 0, flags, ll_i2suppgid(inode), &req);
kfree(fullname);
if (rc) {
if (rc == -EOPNOTSUPP && handler->flags == XATTR_USER_T) {
@@ -307,9 +306,8 @@ static int ll_xattr_set(const struct xattr_handler *handler,
flags);
}
-int
-ll_xattr_list(struct inode *inode, const char *name, int type, void *buffer,
- size_t size, u64 valid)
+int ll_xattr_list(struct inode *inode, const char *name, int type, void *buffer,
+ size_t size, u64 valid)
{
struct ll_inode_info *lli = ll_i2info(inode);
struct ll_sb_info *sbi = ll_i2sbi(inode);
@@ -439,6 +437,7 @@ static int ll_xattr_get_common(const struct xattr_handler *handler,
fullname = kasprintf(GFP_KERNEL, "%s%s", handler->prefix, name);
if (!fullname)
return -ENOMEM;
+
rc = ll_xattr_list(inode, fullname, handler->flags, buffer, size,
OBD_MD_FLXATTR);
kfree(fullname);
@@ -562,6 +561,7 @@ ssize_t ll_listxattr(struct dentry *dentry, char *buffer, size_t size)
OBD_MD_FLXATTRLS);
if (rc < 0)
return rc;
+
/*
* If we're being called to get the size of the xattr list
* (size == 0) then just assume that a lustre.lov xattr
--
1.8.3.1
next prev parent reply other threads:[~2018-04-16 4:15 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-16 4:14 [lustre-devel] [PATCH 00/22] staging: lustre: llite: fix xattr handling James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 01/22] staging: lustre: llite: initialize xattr->xe_namelen James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 02/22] staging: lustre: obd: create it_has_reply_body() James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 03/22] staging: lustre: obd: change debug reporting in lmv_enqueue() James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 04/22] staging: lustre: ldlm: xattr locks are lost on mdt James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 05/22] staging: lustre: llite: handle xattr cache refill race James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 06/22] staging: lustre: llite: Remove filtering of seclabel xattr James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 07/22] staging: lustre: llite: refactor lustre.lov xattr handling James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 08/22] staging: lustre: llite: add simple comment about lustre.lov xattrs James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 09/22] staging: lustre: llite: break up ll_setstripe_ea function James Simmons
2018-04-16 4:14 ` [lustre-devel] [PATCH 10/22] staging: lustre: llite: return from ll_adjust_lum() if lump is NULL James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 11/22] staging: lustre: llite: eat -EEXIST on setting trusted.lov James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 12/22] staging: lustre: llite: fix invalid size test in ll_setstripe_ea() James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 13/22] staging: lustre: llite: remove newline in fullname strings James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 14/22] staging: lustre: llite: record in stats attempted removal of lma/link xattr James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 15/22] staging: lustre: llite: cleanup posix acl xattr code James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 16/22] staging: lustre: llite: use proper types in the " James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 17/22] staging: lustre: llite: cleanup xattr code comments James Simmons
2018-04-16 4:15 ` James Simmons [this message]
2018-04-16 4:15 ` [lustre-devel] [PATCH 19/22] staging: lustre: llite: add support set_acl method in inode operations James Simmons
2018-04-17 8:38 ` Dan Carpenter
2018-04-16 4:15 ` [lustre-devel] [PATCH 20/22] staging: lustre: llite: use xattr_handler name for ACLs James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 21/22] staging: lustre: llite: correct removexattr detection James Simmons
2018-04-16 4:15 ` [lustre-devel] [PATCH 22/22] staging: lustre: llite: remove unused parameters from md_{get, set}xattr() James Simmons
2018-04-23 12:58 ` [lustre-devel] [PATCH 00/22] staging: lustre: llite: fix xattr handling Greg Kroah-Hartman
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=1523852111-17321-19-git-send-email-jsimmons@infradead.org \
--to=jsimmons@infradead.org \
--cc=andreas.dilger@intel.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lustre-devel@lists.lustre.org \
--cc=neilb@suse.com \
--cc=oleg.drokin@intel.com \
--cc=uja.ornl@yahoo.com \
/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).