Received: by 2002:a25:ca44:0:0:0:0:0 with SMTP id a65csp1687190ybg; Wed, 29 Jul 2020 23:14:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzZanegsSGPpUQK3OaPr5x0POwzXI86uinhWlArnCKVbcy6H43sI597bdnDvpZbdHLTVvDP X-Received: by 2002:a50:afa2:: with SMTP id h31mr1151248edd.303.1596089686810; Wed, 29 Jul 2020 23:14:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596089686; cv=none; d=google.com; s=arc-20160816; b=pieT2sAzOxSr8/v3scKTozP3K3FISWtMHiq1rfCeAQVprNQ7MhZLYli0T6wmThd3Mu IBfHYl3qC4AIm5cy8YgVclBGa4q7Kno23KIZapAYtl6PIW3OEz3k5NqKTfITIpHfzSr2 44FO72DdNBkt9ulKVBZk0rAV1mq1zbyf6IDQ3vu5kDjLyIyysmugKAdLSnffezjOhFO4 6MBUKe5mKiLpwUsOzaFZ7W3G343tbef7PmivVq7sZQuf8bp7AUs6X7h8KuT5V693hlmD r4YHVXs0e+V+Hw5W73vr7TyQqZn1oZ5nHqSjZ9u0YQRUzGqTxmWgfDRVDRXbkV2iYxfx crCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=GGiUP2bVq/JP9FTtUqNBNL3J94yI7DyjZeZtZ4EfQfQ=; b=Eiq6a7YnbBZRdDhFqfB2Ov5xQkxjQUHtTVAnEpPO5DiDxezTI6ZQ3RelwA1Or7B0La CUqYTbSvjzwuBUZBK668hC9x5Is+Gw+KeUWNrsZQOizDI1ZtUPGudfCJSu1TfAMWpIMG kvEyGqt37yoxbk8JKzk9BgArVROKhb9yAZBLulGh4NlU0pnz3qiO8zTbhJqGHMXqZbLX VcrgE/59AYMDfgsLCJD8oABDo0XN/KcnFPD/WpHzd0dt192SscZ4Spdc0rsXnuYGIdji HBFpaiUiHhsm4wyeb9d4NemmmJI4ykhYGM79DCN+a60PeSA4nhO1Xlc4dh9fA87muXSm IL8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=casper.20170209 header.b=uppmGrPF; 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 p12si1780739ejz.478.2020.07.29.23.14.24; Wed, 29 Jul 2020 23:14:46 -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; dkim=fail header.i=@infradead.org header.s=casper.20170209 header.b=uppmGrPF; 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 S1728758AbgG3GLG (ORCPT + 99 others); Thu, 30 Jul 2020 02:11:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34834 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728670AbgG3GKi (ORCPT ); Thu, 30 Jul 2020 02:10:38 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1770BC061794 for ; Wed, 29 Jul 2020 23:10:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description; bh=GGiUP2bVq/JP9FTtUqNBNL3J94yI7DyjZeZtZ4EfQfQ=; b=uppmGrPF4xsvgm9wggWDs0wEPO +Rhf5794DXq9nHrgXdPftxW6VFivsrcVGh9/v6xa/kKnWedJT5YSlNRO/OJcgEtISHv9MK/YIgmu/ mDJjvrgmwUJsgXt7tmkDt0pyXdoG4GpQyFN+6KQrZ5435kV5/0MWjOWTTe8YqBBl3gieoKEL80NK1 TyZz7josALf/17YAsQe4rW/dd/zIOopV8EEKNMV8iQhsJGGxpNDOXQItXIXjItSOZnRfva49wHHhX 6ncKOnW9kUy0KflAJd5+s613HjxvXrS1e5Tf9c0LPHlB7wjen/4T5ON+puObfxLCyJoyJ3SObMjWg UpCi7ZdA==; Received: from 138.57.168.109.cust.ip.kpnqwest.it ([109.168.57.138] helo=localhost) by casper.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1k11ly-0007UO-Pn; Thu, 30 Jul 2020 06:10:35 +0000 From: Christoph Hellwig To: Jessica Yu Cc: Greg Kroah-Hartman , linux-kernel@vger.kernel.org (open list) Subject: [PATCH 2/8] modules: mark find_symbol static Date: Thu, 30 Jul 2020 08:10:21 +0200 Message-Id: <20200730061027.29472-3-hch@lst.de> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200730061027.29472-1-hch@lst.de> References: <20200730061027.29472-1-hch@lst.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org find_symbol is only used in module.c. Signed-off-by: Christoph Hellwig --- include/linux/module.h | 11 ----------- kernel/module.c | 3 +-- 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/include/linux/module.h b/include/linux/module.h index f1fdbeef2153a8..90bdc362be3681 100644 --- a/include/linux/module.h +++ b/include/linux/module.h @@ -590,17 +590,6 @@ struct symsearch { bool unused; }; -/* - * Search for an exported symbol by name. - * - * Must be called with module_mutex held or preemption disabled. - */ -const struct kernel_symbol *find_symbol(const char *name, - struct module **owner, - const s32 **crc, - bool gplok, - bool warn); - /* * Walk the exported symbol table * diff --git a/kernel/module.c b/kernel/module.c index 17d64dae756c80..84da96a6d8241c 100644 --- a/kernel/module.c +++ b/kernel/module.c @@ -585,7 +585,7 @@ static bool find_exported_symbol_in_section(const struct symsearch *syms, /* Find an exported symbol and return it, along with, (optional) crc and * (optional) module which owns it. Needs preempt disabled or module_mutex. */ -const struct kernel_symbol *find_symbol(const char *name, +static const struct kernel_symbol *find_symbol(const char *name, struct module **owner, const s32 **crc, bool gplok, @@ -608,7 +608,6 @@ const struct kernel_symbol *find_symbol(const char *name, pr_debug("Failed to find symbol %s\n", name); return NULL; } -EXPORT_SYMBOL_GPL(find_symbol); /* * Search for module by name: must hold module_mutex (or preempt disabled -- 2.27.0