Received: by 2002:a25:23cc:0:0:0:0:0 with SMTP id j195csp1841034ybj; Wed, 6 May 2020 06:25:15 -0700 (PDT) X-Google-Smtp-Source: APiQypKf156jGS4/OZcno+SlQXy9KKaX3x6eZrraIhF1O1WFmhbYbg4CMV5JJ6Su+VQ4kOTsYSD6 X-Received: by 2002:a17:906:7a51:: with SMTP id i17mr7097373ejo.8.1588771515150; Wed, 06 May 2020 06:25:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588771515; cv=none; d=google.com; s=arc-20160816; b=iGyfpIxuaH+VGPMRaYk1UXVeH+54ZCdQEi66CrQpLxiERmN3aQD0RP2QcNU1x2J2zL Ixqnsfdwn8mhtk/FyYvUIH8cKCXtg7VHL0UtJl6nDLp2nxtcpMS3yK513QM6A/Pr3Py9 jRv+jFsRuBEMHJVc/Ub3Trm70AbUm/7lhXpOUxQ7pO36ea7Y0k1OuImojZvte9utFvUL MPCzHJnnYmBrdW1YddeZTl1tXUs7gya+9aK03jRLizsQ+GIzYQCLCTzDHLMd3co1zHts UwNm3/q4LxolM8pvx3gbRRwnvpYt13+SlYdHbURzFlpRynzIktamhuNoL0OUiAEQSo0G ow4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from; bh=yBXQUL9T/nVTVuUOusjKLcV6rzPl3cwFn847yjqzJak=; b=joXmUOZ7AD1DLEHSmyzBm3oTU9UCZrtl3D0dfeIkyDeiCCOghhr9LEhiERL6VYAS8T 3qdP/7zckxPPgkUmsHFUcHe678z0xs/gMzXHUZD9ALQe56qF5Kex9IaZx+8eFLrOUYa7 uA9EdKcrSVokC6yspTfIPS0V8eh7KznS/VSRcPPHRwIWNNQ8QWEvBq0DvJHivrG0yN8Y FtVs6jWxCllfzjt+Uj0Cz5pczYCRuMMJqYfOQ/JPNxRMHcfn4m2PVbPtj2ZeucALL4TP 9tzKqqy4LcKrpJtL3P9CU4dy+GIXy/LP/1BDboUMHceTKbd8cxdHV6tZoRALdkPQjg2C l4Zw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dn15si995414edb.555.2020.05.06.06.24.51; Wed, 06 May 2020 06:25:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728375AbgEFNXM (ORCPT + 99 others); Wed, 6 May 2020 09:23:12 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:42640 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728058AbgEFNXM (ORCPT ); Wed, 6 May 2020 09:23:12 -0400 Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 9B9D2CFD35C662F401BB; Wed, 6 May 2020 21:23:07 +0800 (CST) Received: from localhost (10.166.215.154) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.487.0; Wed, 6 May 2020 21:23:00 +0800 From: YueHaibing To: , , CC: , , YueHaibing Subject: [PATCH -next] btrfs: Remove unused inline function heads_to_leaves Date: Wed, 6 May 2020 21:22:39 +0800 Message-ID: <20200506132239.3252-1-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.166.215.154] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org There's no callers in-tree anymore since commit 64403612b73a ("btrfs: rework btrfs_check_space_for_delayed_refs") Signed-off-by: YueHaibing --- fs/btrfs/extent-tree.c | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c index faa585d54eb7..3593f8cce9e5 100644 --- a/fs/btrfs/extent-tree.c +++ b/fs/btrfs/extent-tree.c @@ -2114,22 +2114,6 @@ static u64 find_middle(struct rb_root *root) } #endif -static inline u64 heads_to_leaves(struct btrfs_fs_info *fs_info, u64 heads) -{ - u64 num_bytes; - - num_bytes = heads * (sizeof(struct btrfs_extent_item) + - sizeof(struct btrfs_extent_inline_ref)); - if (!btrfs_fs_incompat(fs_info, SKINNY_METADATA)) - num_bytes += heads * sizeof(struct btrfs_tree_block_info); - - /* - * We don't ever fill up leaves all the way so multiply by 2 just to be - * closer to what we're really going to want to use. - */ - return div_u64(num_bytes, BTRFS_LEAF_DATA_SIZE(fs_info)); -} - /* * Takes the number of bytes to be csumm'ed and figures out how many leaves it * would require to store the csums for that many bytes. -- 2.17.1