linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Edmund Nadolski <enadolski@suse.com>
To: enadolski@suse.com, linux-btrfs@vger.kernel.org
Subject: [PATCH 1/3] btrfs: btrfs_inode_log_parent should use defined inode_only values.
Date: Mon, 20 Nov 2017 13:24:47 -0700	[thread overview]
Message-ID: <20171120202449.22947-2-enadolski@suse.com> (raw)
In-Reply-To: <20171120202449.22947-1-enadolski@suse.com>

Replace hardcoded numeric argument values for inode_only with the
constants defined for that use.

Signed-off-by: Edmund Nadolski <enadolski@suse.com>
---
 fs/btrfs/tree-log.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c
index 1f79405..95cff91 100644
--- a/fs/btrfs/tree-log.c
+++ b/fs/btrfs/tree-log.c
@@ -5403,11 +5403,10 @@ static int btrfs_log_inode_parent(struct btrfs_trans_handle *trans,
 				  struct dentry *parent,
 				  const loff_t start,
 				  const loff_t end,
-				  int exists_only,
+				  int inode_only,
 				  struct btrfs_log_ctx *ctx)
 {
 	struct btrfs_fs_info *fs_info = root->fs_info;
-	int inode_only = exists_only ? LOG_INODE_EXISTS : LOG_INODE_ALL;
 	struct super_block *sb;
 	struct dentry *old_parent = NULL;
 	int ret = 0;
@@ -5573,7 +5572,7 @@ int btrfs_log_dentry_safe(struct btrfs_trans_handle *trans,
 	int ret;
 
 	ret = btrfs_log_inode_parent(trans, root, BTRFS_I(d_inode(dentry)),
-			parent, start, end, 0, ctx);
+			parent, start, end, LOG_INODE_ALL, ctx);
 	dput(parent);
 
 	return ret;
@@ -5836,6 +5835,6 @@ int btrfs_log_new_name(struct btrfs_trans_handle *trans,
 		return 0;
 
 	return btrfs_log_inode_parent(trans, root, inode, parent, 0,
-				      LLONG_MAX, 1, NULL);
+				      LLONG_MAX, LOG_INODE_EXISTS, NULL);
 }
 
-- 
2.10.2


  reply	other threads:[~2017-11-20 20:25 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-20 20:24 [PATCH 0/3] btrfs: some code cleanup and documentation Edmund Nadolski
2017-11-20 20:24 ` Edmund Nadolski [this message]
2017-11-21  8:44   ` [PATCH 1/3] btrfs: btrfs_inode_log_parent should use defined inode_only values Nikolay Borisov
2017-11-20 20:24 ` [PATCH 2/3] btrfs: update some code documentation Edmund Nadolski
2017-11-21  7:59   ` Nikolay Borisov
2017-11-21 22:20     ` Edmund Nadolski
2017-11-22  7:01       ` Nikolay Borisov
2017-11-21 13:24   ` David Sterba
2017-11-20 20:24 ` [PATCH 3/3] btrfs: remove dead code from btrfs_get_extent Edmund Nadolski
2017-11-21  8:25   ` Nikolay Borisov
2017-11-21 13:28 ` [PATCH 0/3] btrfs: some code cleanup and documentation David Sterba

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=20171120202449.22947-2-enadolski@suse.com \
    --to=enadolski@suse.com \
    --cc=linux-btrfs@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).