From patchwork Tue Jan 17 22:31:41 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nikolay Borisov X-Patchwork-Id: 9522031 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 A5FAA6020B for ; Tue, 17 Jan 2017 22:39:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9905E28426 for ; Tue, 17 Jan 2017 22:39:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8DE2B28602; Tue, 17 Jan 2017 22:39:38 +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.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, 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 3E0A028426 for ; Tue, 17 Jan 2017 22:39:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751341AbdAQWjf (ORCPT ); Tue, 17 Jan 2017 17:39:35 -0500 Received: from mail-wm0-f67.google.com ([74.125.82.67]:33557 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751045AbdAQWjf (ORCPT ); Tue, 17 Jan 2017 17:39:35 -0500 Received: by mail-wm0-f67.google.com with SMTP id r144so41964649wme.0 for ; Tue, 17 Jan 2017 14:39:34 -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=lFJW1/qrUzUsxHsazlzN8gc6lc8A9qr6XXiLRlH2Jc4=; b=OD8x7CsQ8bA3Zq7KSqUEdwkYszMimdpgdsxKAcSfJdXCS0AeUIJRU3ZSje05wP/WMt ZePgXNBbcwFK6alvJUI+EDjHM4kaSLUz8Y7WzCeE823AUTyYxqsuFgmwKxRRYqFVO7aA g7B1acd0Gp84mKefWACINW2LDJdQ+kE6pyOeVp1nXxnrJZeQKXVRmmILb/yfCNbiilKc paQttrsH/RN1MRptsTL0FlVmBWa/sE5ecPTFZisrxfedErtm8r6gRUAwMc18FJOt53WV DaSpRrAWgg/AiRpEk80k6YdwJumtZ+FJuyQz4qV9XSR+tXaBIbtQGuGKiB4U3hiutz9g FhTw== 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=lFJW1/qrUzUsxHsazlzN8gc6lc8A9qr6XXiLRlH2Jc4=; b=o6LgUuRlv2ovl3c0sbGbLmubR8NnzVt6MkF80kIVkz3FcHThd6V+C1SxeOpvZVKktI HFs+noScucKaxBVxvraYNvPRrmKpJo4XxeI5Qw5uBEI6pfLXiY0w5sYclC48YYlznpVI 2HL0eFnGzLVFxDw5v953wZKtnUK+0pBjjzBOD6s5MfU/nvPSaaX1jmxrTzr5Q48BxHEh qyyu5HobrI91QcKzNFmVDx5jw2fNMicS8wjaAuH4SF5aR+jFQU3VU3fpE6WMHEINwFSO GzFGxic4wBGK8+nIcgc0/kmB6iOgCased59H+sOztTdDU7BSHVEwdqwkOrD9is7euo9V 5Bgg== X-Gm-Message-State: AIkVDXJmJDOfpXQoFj8pwLC7Ce4AqRUvQwY1bbdyaHr0SjpAnTimc4XvsXmlBsPrnDfgJw== X-Received: by 10.223.175.49 with SMTP id z46mr10777wrc.84.1484692343362; Tue, 17 Jan 2017 14:32:23 -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.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 17 Jan 2017 14:32:22 -0800 (PST) From: Nikolay Borisov To: dsterba@suse.cz Cc: linux-btrfs@vger.kernel.org, Nikolay Borisov Subject: [PATCHv2 15/24] btrfs: Make log_dir_items take btrfs_inode Date: Wed, 18 Jan 2017 00:31:41 +0200 Message-Id: <1484692310-3987-16-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 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c index e293ae0e18d7..8d7197a0eceb 100644 --- a/fs/btrfs/tree-log.c +++ b/fs/btrfs/tree-log.c @@ -3260,7 +3260,7 @@ static noinline int insert_dir_log_key(struct btrfs_trans_handle *trans, * to replay anything deleted before the fsync */ static noinline int log_dir_items(struct btrfs_trans_handle *trans, - struct btrfs_root *root, struct inode *inode, + struct btrfs_root *root, struct btrfs_inode *inode, struct btrfs_path *path, struct btrfs_path *dst_path, int key_type, struct btrfs_log_ctx *ctx, @@ -3275,7 +3275,7 @@ static noinline int log_dir_items(struct btrfs_trans_handle *trans, int nritems; u64 first_offset = min_offset; u64 last_offset = (u64)-1; - u64 ino = btrfs_ino(BTRFS_I(inode)); + u64 ino = btrfs_ino(inode); log = root->log_root; @@ -3464,7 +3464,7 @@ static noinline int log_directory_changes(struct btrfs_trans_handle *trans, min_key = 0; max_key = 0; while (1) { - ret = log_dir_items(trans, root, inode, path, + ret = log_dir_items(trans, root, BTRFS_I(inode), path, dst_path, key_type, ctx, min_key, &max_key); if (ret)