Received: by 2002:a05:7412:f589:b0:e2:908c:2ebd with SMTP id eh9csp620857rdb; Tue, 31 Oct 2023 18:23:58 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEDQMBcsI7ODTio0oGC1lykbgm8reGa0dl8hnXd4tcpv1gUauN9yhmW2ngVkMwxQVUAupao X-Received: by 2002:a05:6a20:42a5:b0:14d:6309:fc96 with SMTP id o37-20020a056a2042a500b0014d6309fc96mr14516512pzj.4.1698801837963; Tue, 31 Oct 2023 18:23:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698801837; cv=none; d=google.com; s=arc-20160816; b=QLqSUogxrkQYbCohE53pRcigb+lqNKLf+4BetzkxgAcS6UMpP3elmBXnKxkmlaW3sK gZOVA+ayEFlCXYD4A/FBpWd3Ki+6/5tDKFIR87+e0N42aQdN7AIXkucyErAmrGGnDTYi keQtICbBOxKCAA9bYQLuRyWiiDh/967BGujMSzCOaKRN+zGIks5+/MkpHdR42VaeQEuj m2R0fm+eu44SNNg+SPdW7FpKVr37HhekHi5JZdg3oB9XHRGGbTLTGAG9Efj3ALiu/B+h MFiegWySf7Om/HUZReRr23RVYNBnATMGE9xX7wNZnVtkSOKZ3SckCsdppadT+DY79UTh pkxw== 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=8U2vpHTprmj+1YHwMbcQXqYkxz046ZmpXOsFZFnAEjk=; fh=qvjkmraV+sh0PKUKvfP82elzReL5YNE/oehz0zAs54s=; b=FQoGC1zozv8P6qV0jgH/AobfDuLgB0voOh8Gx9i8U66PpH9huUnVsW2/00l59rbIzn EDxQ3nH7yJMqmtxhwdXkJZrExoV0etUkNycN0RJepaz10K/aFfgUm0dk1UcBvR4SoPN6 VnB8xyi34g7zcYLwoghG3SgmaGK7vGaxV+nrgz2c+CNb01M8ahwqjF1NTxJfZbt/yVxO 6013WFGa9jqONE6NmdvxUOTSm9Qivkjhuw/rNCw0FlVz+GP+AB/e+ubOF2GFLU8ZHQe4 0ZQp3RiVhkVg9JdX9emHNRIiOMakciFso4blBqbhiJOpK9YOXZS1TKDN6ZLPrdHymwr8 3xow== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 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 pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id z6-20020a170902d54600b001cc38c45470si2011620plf.232.2023.10.31.18.23.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 31 Oct 2023 18:23:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 2E0C580284C9; Tue, 31 Oct 2023 18:23:53 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345114AbjKABXk (ORCPT + 99 others); Tue, 31 Oct 2023 21:23:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59774 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345060AbjKABXj (ORCPT ); Tue, 31 Oct 2023 21:23:39 -0400 Received: from out30-132.freemail.mail.aliyun.com (out30-132.freemail.mail.aliyun.com [115.124.30.132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 14600F4 for ; Tue, 31 Oct 2023 18:23:32 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R191e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018045176;MF=jiapeng.chong@linux.alibaba.com;NM=1;PH=DS;RN=9;SR=0;TI=SMTPD_---0VvIq7WL_1698801803; Received: from localhost(mailfrom:jiapeng.chong@linux.alibaba.com fp:SMTPD_---0VvIq7WL_1698801803) by smtp.aliyun-inc.com; Wed, 01 Nov 2023 09:23:29 +0800 From: Jiapeng Chong To: jgg@ziepe.ca Cc: kevin.tian@intel.com, joro@8bytes.org, will@kernel.org, robin.murphy@arm.com, iommu@lists.linux.dev, linux-kernel@vger.kernel.org, Jiapeng Chong , Abaci Robot Subject: [PATCH] iommufd/selftest: Remove unused function Date: Wed, 1 Nov 2023 09:23:23 +0800 Message-Id: <20231101012323.33154-1-jiapeng.chong@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=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE, UNPARSEABLE_RELAY,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Tue, 31 Oct 2023 18:23:53 -0700 (PDT) The function are defined in the selftest.c file, but not called elsewhere, so delete the unused function. drivers/iommu/iommufd/selftest.c:511:1: warning: unused function 'get_md_pagetable_nested'. Reported-by: Abaci Robot Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=7104 Signed-off-by: Jiapeng Chong --- drivers/iommu/iommufd/selftest.c | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/drivers/iommu/iommufd/selftest.c b/drivers/iommu/iommufd/selftest.c index 256f93715a0d..758d328a44cd 100644 --- a/drivers/iommu/iommufd/selftest.c +++ b/drivers/iommu/iommufd/selftest.c @@ -515,25 +515,6 @@ get_md_pagetable(struct iommufd_ucmd *ucmd, u32 mockpt_id, return hwpt; } -static inline struct iommufd_hw_pagetable * -get_md_pagetable_nested(struct iommufd_ucmd *ucmd, u32 mockpt_id, - struct mock_iommu_domain_nested **mock_nested) -{ - struct iommufd_hw_pagetable *hwpt; - - hwpt = __get_md_pagetable(ucmd, mockpt_id, IOMMUFD_OBJ_HWPT_NESTED); - if (IS_ERR(hwpt)) - return hwpt; - if (hwpt->domain->type != IOMMU_DOMAIN_NESTED || - hwpt->domain->ops != &domain_nested_ops) { - iommufd_put_object(&hwpt->obj); - return ERR_PTR(-EINVAL); - } - *mock_nested = container_of(hwpt->domain, - struct mock_iommu_domain_nested, domain); - return hwpt; -} - struct mock_bus_type { struct bus_type bus; struct notifier_block nb; -- 2.20.1.7.g153144c