Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp2249810iof; Wed, 8 Jun 2022 00:29:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzbUb45UJ6Qit3v5bgs8MTIrwRJchTkS8Y6QIHkq277+8smN6vmPzLbzbmYS+Gq32xJWuwu X-Received: by 2002:a17:90b:164a:b0:1e8:8e0c:88dc with SMTP id il10-20020a17090b164a00b001e88e0c88dcmr13233715pjb.237.1654673348831; Wed, 08 Jun 2022 00:29:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654673348; cv=none; d=google.com; s=arc-20160816; b=YndiNEpNVt78CwtCAuIgYXyFNNa9bmiJSF5vXNCJXNUKkLSK69YfVlW9RbJ3iO2iup u/qdYZ0dOLIPFLCQRhpjMdg7UxmVcDU15LfCrSuoxYX8NCwX5ZnG12hWAtfVQL2sC/fs IWFhRzTuHqJIR3aFXWEa3JhD56O61moZj/7TqgarHvjder1WwBnvzXXDzu9yaxsi6bie 3dWNXl0nmhs24R2LwaWOAMzhGoP7cVdanSSYi/hGNSdt74fd1vrNaQ5FHf7emVmPYOwk gmXBiUCBdSlVplnZ/Bm5JAn+zAlZk9YGDYNgVjH2rqK0Z75hQpuHcScsh/uIg9nacCyA RtEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=Xxqil7xcL+nXMa9mMgwNAH35rVMMLfRcKxP5+YzvQH0=; b=D0TZi4HhyeWVlvfMkJAyhGtE611xJecR7MqnMDl66PoG+0xE1Qh/jXqvozJWdf8Q4a 7Ev9Oh5MSBskenQpM0e4kOP/u5JMy/lSKVmrDfKiuKZptx1ruDphrWqjHlyydFQaszch HCC/boD3b0nbBe0dJM8l9RYSNTGnsSj3ZLwrDsVX2KHvR+tOOmnjJ/WS4NydXWITyZ1Z tG6BwYFbiij7gZqh3X2BXcajaeNWSw8HvGoh4J1XYqLjNFzjI9ix45i7J6wVjutK9bTz esZ4dacFbbgr1SgCL7W2cvnj0+pJj0+riEcQkdKiMrX6pl02C4vojEMc7+3dXtIHFjzi q2yw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c4-20020a63d504000000b003fbfe86551fsi7141868pgg.301.2022.06.08.00.28.35; Wed, 08 Jun 2022 00:29:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232355AbiFHEIC (ORCPT + 99 others); Wed, 8 Jun 2022 00:08:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33722 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236752AbiFHEGQ (ORCPT ); Wed, 8 Jun 2022 00:06:16 -0400 Received: from out199-13.us.a.mail.aliyun.com (out199-13.us.a.mail.aliyun.com [47.90.199.13]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 01E1829C13F; Tue, 7 Jun 2022 18:24:28 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R971e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018046060;MF=yang.lee@linux.alibaba.com;NM=1;PH=DS;RN=7;SR=0;TI=SMTPD_---0VFhsKWe_1654651319; Received: from localhost(mailfrom:yang.lee@linux.alibaba.com fp:SMTPD_---0VFhsKWe_1654651319) by smtp.aliyun-inc.com; Wed, 08 Jun 2022 09:22:00 +0800 From: Yang Li To: clm@fb.com Cc: josef@toxicpanda.com, dsterba@suse.com, linux-btrfs@vger.kernel.org, linux-kernel@vger.kernel.org, Yang Li , Abaci Robot Subject: [PATCH -next] btrfs: Remove the unused function scrub_calc_parity_bitmap_len() Date: Wed, 8 Jun 2022 09:21:58 +0800 Message-Id: <20220608012158.109334-1-yang.lee@linux.alibaba.com> X-Mailer: git-send-email 2.20.1.7.g153144c MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE, UNPARSEABLE_RELAY,USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org bitmap_len = scrub_calc_parity_bitmap_len(), the only call point of this function has been deleted, so it should also be removed. Fix the following W=1 kernel warning: fs/btrfs/scrub.c:2857:19: warning: unused function 'scrub_calc_parity_bitmap_len' Reported-by: Abaci Robot Signed-off-by: Yang Li --- fs/btrfs/scrub.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/fs/btrfs/scrub.c b/fs/btrfs/scrub.c index 46cac7c7f292..db700e6ec5a9 100644 --- a/fs/btrfs/scrub.c +++ b/fs/btrfs/scrub.c @@ -2854,11 +2854,6 @@ static void scrub_parity_check_and_repair(struct scrub_parity *sparity) scrub_free_parity(sparity); } -static inline int scrub_calc_parity_bitmap_len(int nsectors) -{ - return DIV_ROUND_UP(nsectors, BITS_PER_LONG) * sizeof(long); -} - static void scrub_parity_get(struct scrub_parity *sparity) { refcount_inc(&sparity->refs); -- 2.20.1.7.g153144c