From patchwork Thu Jan 11 05:08:46 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lu Fengqi X-Patchwork-Id: 10157099 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 05A38605F8 for ; Thu, 11 Jan 2018 05:13:03 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EC73528627 for ; Thu, 11 Jan 2018 05:13:02 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E14CE286B1; Thu, 11 Jan 2018 05:13:02 +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.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI 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 6C5C42869C for ; Thu, 11 Jan 2018 05:13:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932130AbeAKFM5 (ORCPT ); Thu, 11 Jan 2018 00:12:57 -0500 Received: from mail.cn.fujitsu.com ([183.91.158.132]:54301 "EHLO heian.cn.fujitsu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753762AbeAKFKJ (ORCPT ); Thu, 11 Jan 2018 00:10:09 -0500 X-IronPort-AV: E=Sophos;i="5.43,368,1503331200"; d="scan'208";a="35160305" Received: from bogon (HELO cn.fujitsu.com) ([10.167.33.5]) by heian.cn.fujitsu.com with ESMTP; 11 Jan 2018 13:09:56 +0800 Received: from G08CNEXCHPEKD01.g08.fujitsu.local (unknown [10.167.33.80]) by cn.fujitsu.com (Postfix) with ESMTP id 8D2CE48AEA13 for ; Thu, 11 Jan 2018 13:09:56 +0800 (CST) Received: from localhost.localdomain (10.167.226.155) by G08CNEXCHPEKD01.g08.fujitsu.local (10.167.33.89) with Microsoft SMTP Server (TLS) id 14.3.361.1; Thu, 11 Jan 2018 13:09:59 +0800 From: Lu Fengqi To: Subject: [PATCH 14/67] btrfs-progs: add the stack prefix for root_limit set/get function Date: Thu, 11 Jan 2018 13:08:46 +0800 Message-ID: <20180111050939.21251-15-lufq.fnst@cn.fujitsu.com> X-Mailer: git-send-email 2.15.1 In-Reply-To: <20180111050939.21251-1-lufq.fnst@cn.fujitsu.com> References: <20180111050939.21251-1-lufq.fnst@cn.fujitsu.com> MIME-Version: 1.0 X-Originating-IP: [10.167.226.155] X-yoursite-MailScanner-ID: 8D2CE48AEA13.AEA52 X-yoursite-MailScanner: Found to be clean X-yoursite-MailScanner-From: lufq.fnst@cn.fujitsu.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 The root_limit set/get function defined by BTRFS_SETGET_STACK_FUNCS macro is missing the prefix stack. Signed-off-by: Lu Fengqi --- ctree.h | 3 ++- print-tree.c | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ctree.h b/ctree.h index a49f9dda..7c72b5d6 100644 --- a/ctree.h +++ b/ctree.h @@ -2061,7 +2061,8 @@ BTRFS_SETGET_STACK_FUNCS(stack_root_refs, struct btrfs_root_item, refs, 32); BTRFS_SETGET_STACK_FUNCS(stack_root_flags, struct btrfs_root_item, flags, 64); BTRFS_SETGET_STACK_FUNCS(stack_root_used, struct btrfs_root_item, bytes_used, 64); -BTRFS_SETGET_STACK_FUNCS(root_limit, struct btrfs_root_item, byte_limit, 64); +BTRFS_SETGET_STACK_FUNCS(stack_root_limit, struct btrfs_root_item, byte_limit, + 64); BTRFS_SETGET_STACK_FUNCS(root_last_snapshot, struct btrfs_root_item, last_snapshot, 64); BTRFS_SETGET_STACK_FUNCS(root_generation_v2, struct btrfs_root_item, diff --git a/print-tree.c b/print-tree.c index c2d19f38..fb9b0412 100644 --- a/print-tree.c +++ b/print-tree.c @@ -595,7 +595,7 @@ static void print_root_item(struct extent_buffer *leaf, int slot) btrfs_stack_root_refs(&root_item)); printf("\t\tlastsnap %llu byte_limit %llu bytes_used %llu flags 0x%llx(%s)\n", (unsigned long long)btrfs_root_last_snapshot(&root_item), - (unsigned long long)btrfs_root_limit(&root_item), + (unsigned long long)btrfs_stack_root_limit(&root_item), (unsigned long long)btrfs_stack_root_used(&root_item), (unsigned long long)btrfs_stack_root_flags(&root_item), flags_str);