From patchwork Tue Jan 17 22:31:37 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nikolay Borisov X-Patchwork-Id: 9522047 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 2622C6020B for ; Tue, 17 Jan 2017 22:41:40 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 19F1E28602 for ; Tue, 17 Jan 2017 22:41:40 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0BF2F28515; Tue, 17 Jan 2017 22:41:40 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A27D728515 for ; Tue, 17 Jan 2017 22:41:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751379AbdAQWlU (ORCPT ); Tue, 17 Jan 2017 17:41:20 -0500 Received: from mail-wm0-f65.google.com ([74.125.82.65]:34526 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751377AbdAQWlS (ORCPT ); Tue, 17 Jan 2017 17:41:18 -0500 Received: by mail-wm0-f65.google.com with SMTP id c85so9433544wmi.1 for ; Tue, 17 Jan 2017 14:41:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=86TkLgr646nCeQQvVGnCsVrwpZbL5y+0RQe/KQHb+IE=; b=eCy5sCcXetLHeFgr967xbORk6Vbzb4+g6T01ZfcP1XBOZ5NBxYy1ud3IoUjCJOlX1L nb0MENhucKvTI0f4B9dyR8d4blC423bKDqxYH7x9Txd7XQPwLqu6nmLIfGgDLf8Pp8Sb dVprL0v3MUpbQ09pFmR8MOfJC6gIDAjWfBfXHYyfhuTJIhcQJPgrLmy+5ISshveaYBn/ oeb6fhrRTXnhAOGOycG7MJXq6NHHaZ10LNWJ17OwEpsueUMIKqDQsUODkfHoOlnVxqy2 7oe7HJ3THsN0eg7jkJWjvGnJ17aj2KNsMEIU3r0t9MKyjYGmeSZVSPQz8WJmyVGE+fCV ICpA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=86TkLgr646nCeQQvVGnCsVrwpZbL5y+0RQe/KQHb+IE=; b=A2ei/touqTzXNTONZDLTiG/oz8g/WRysDtRN6BJAVv9A6dtIu4PegKSl3XIkJsvR3X kJdLdqrGR/FaSCqZ2s0RpEWgmeWUyGF2hN1mE0mWOb+GTdViN6KkjYahGJc+8zpoV59y QTETaPSssQU/Y1HS578WK9oIEsC1jUO+t1uB7fMPAFl4owA+fmdy2Lkt5+ZzPUexu+4V 6dyf+hrOXvfqEoDHxPzvils9fkuxkUTwmqUpcG3ivNYkctZFilmujpe8jYOQ5IyBDR8f F98Te5FSki275zOifLfv3MwPYDRuOydiszFZ0G7JDmFBWBs2b4zuzkptPiyW8wRcU3f3 2H+Q== X-Gm-Message-State: AIkVDXKlg/A00tjp5+DSt+pBNWVzoXnVRlz4s/UnL2fPwwuXFeZYCXf6QHPtZh9lXbR/GA== X-Received: by 10.223.142.1 with SMTP id n1mr29030783wrb.185.1484692338108; Tue, 17 Jan 2017 14:32:18 -0800 (PST) Received: from fisk.lan (ivokamhome.ddns.nbis.net. [87.120.136.31]) by smtp.gmail.com with ESMTPSA id w197sm39980489wmd.11.2017.01.17.14.32.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 17 Jan 2017 14:32:17 -0800 (PST) From: Nikolay Borisov To: dsterba@suse.cz Cc: linux-btrfs@vger.kernel.org, Nikolay Borisov Subject: [PATCHv2 11/24] btrfs: Make btrfs_log_all_xattrs take btrfs_inode Date: Wed, 18 Jan 2017 00:31:37 +0200 Message-Id: <1484692310-3987-12-git-send-email-n.borisov.lkml@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1484692310-3987-1-git-send-email-n.borisov.lkml@gmail.com> References: <20170117161550.GW12081@twin.jikos.cz> <1484692310-3987-1-git-send-email-n.borisov.lkml@gmail.com> Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Nikolay Borisov --- fs/btrfs/tree-log.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c index 12872bf492bd..1301c517c2f0 100644 --- a/fs/btrfs/tree-log.c +++ b/fs/btrfs/tree-log.c @@ -4277,13 +4277,13 @@ static int logged_inode_size(struct btrfs_root *log, struct btrfs_inode *inode, */ static int btrfs_log_all_xattrs(struct btrfs_trans_handle *trans, struct btrfs_root *root, - struct inode *inode, + struct btrfs_inode *inode, struct btrfs_path *path, struct btrfs_path *dst_path) { int ret; struct btrfs_key key; - const u64 ino = btrfs_ino(BTRFS_I(inode)); + const u64 ino = btrfs_ino(inode); int ins_nr = 0; int start_slot = 0; @@ -4304,7 +4304,7 @@ static int btrfs_log_all_xattrs(struct btrfs_trans_handle *trans, if (ins_nr > 0) { u64 last_extent = 0; - ret = copy_items(trans, BTRFS_I(inode), dst_path, path, + ret = copy_items(trans, inode, dst_path, path, &last_extent, start_slot, ins_nr, 1, 0); /* can't be 1, extent items aren't processed */ @@ -4334,7 +4334,7 @@ static int btrfs_log_all_xattrs(struct btrfs_trans_handle *trans, if (ins_nr > 0) { u64 last_extent = 0; - ret = copy_items(trans, BTRFS_I(inode), dst_path, path, + ret = copy_items(trans, inode, dst_path, path, &last_extent, start_slot, ins_nr, 1, 0); /* can't be 1, extent items aren't processed */ @@ -4919,7 +4919,7 @@ static int btrfs_log_inode(struct btrfs_trans_handle *trans, btrfs_release_path(path); btrfs_release_path(dst_path); - err = btrfs_log_all_xattrs(trans, root, inode, path, dst_path); + err = btrfs_log_all_xattrs(trans, root, BTRFS_I(inode), path, dst_path); if (err) goto out_unlock; if (max_key.type >= BTRFS_EXTENT_DATA_KEY && !fast_search) {