Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp315897pxy; Thu, 22 Apr 2021 02:51:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyEJo+Ldx7BU3SuA3/fwEMR0DU1k8hVZ3xVAssjw7tCgx2l+/4WFJwuOFGv0WPcGOcubszT X-Received: by 2002:a63:3757:: with SMTP id g23mr2694621pgn.422.1619085109806; Thu, 22 Apr 2021 02:51:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619085109; cv=none; d=google.com; s=arc-20160816; b=jdpnPPppzTAxhsUjoi86mkufudzte1Q/QlEHCbB/eNxRDoDJMgZmGG8zQ0e4rJD9uo P4pT5eKX0ngRh3/n7F+P5VndqfZ5q/NB85e9q/lzb/jXwZhwscPZPt+A1bH1412jSroZ KZhr8VSYiq5qH998HYvl+eXTuP8HEzAKCsJ+bHlQFCXdsrdngG2gk/B7GaZdRNO87OcS IDB4lh2GAVKuPJHykEI2o2G/eB5OK+LsD62DByprLbQa77GNsUWGLnERL1EmqyIX/19T 4n1MXfyRdY+NVKj0QExJ17lOxGJjRzU6kZUHLoQweMBkzoinBk35uH4HbtNBESSuKRa6 kMpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=FmdNe45SJqDDtS5Io6mRw8KIercPQ6afDxZ51oYYnfM=; b=M3H2+brkGKT5h0WYoxzdvKk1hh6tmefTleNZdCq2wFx5eFhLci1jjgb8TJSA0qNwZC 704F0WdA3PZ5+/zZOq9MSQOC7UX6DimVIsCUvNUKjXmbP/M6XyzsfnSUWFcB/VXVhAsr cQLjrRUjJGox49+My4KW5EJ76Ro0slx7Fu/xn4yMW4DOZB2VoBECk8nqnpYFCpoTuQec Bi4ypDQHOfnSbPkeuAsORIA2dUYL2PoSsCtt2GgIQfaqaoZDzo9tqg+1+bFVqOVG+FcF hkOZzbi1xak3U1bJbY1spcSSgH0lOT22idW6Izg/GYS+kst4/yNsI639BAao2Fb9sNzA i84g== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e30si2749070pgn.211.2021.04.22.02.51.37; Thu, 22 Apr 2021 02:51:49 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235814AbhDVJty (ORCPT + 99 others); Thu, 22 Apr 2021 05:49:54 -0400 Received: from out30-132.freemail.mail.aliyun.com ([115.124.30.132]:34685 "EHLO out30-132.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235801AbhDVJtx (ORCPT ); Thu, 22 Apr 2021 05:49:53 -0400 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R201e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04420;MF=jiapeng.chong@linux.alibaba.com;NM=1;PH=DS;RN=12;SR=0;TI=SMTPD_---0UWOJIrC_1619084948; Received: from j63c13417.sqa.eu95.tbsite.net(mailfrom:jiapeng.chong@linux.alibaba.com fp:SMTPD_---0UWOJIrC_1619084948) by smtp.aliyun-inc.com(127.0.0.1); Thu, 22 Apr 2021 17:49:17 +0800 From: Jiapeng Chong To: ast@kernel.org Cc: daniel@iogearbox.net, andrii@kernel.org, kafai@fb.com, songliubraving@fb.com, yhs@fb.com, john.fastabend@gmail.com, kpsingh@kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, bpf@vger.kernel.org, Jiapeng Chong Subject: [PATCH v2] kallsyms: Remove function arch_get_kallsym() Date: Thu, 22 Apr 2021 17:49:06 +0800 Message-Id: <1619084946-28509-1-git-send-email-jiapeng.chong@linux.alibaba.com> X-Mailer: git-send-email 1.8.3.1 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Fix the following sparse warning: kernel/kallsyms.c:457:12: warning: symbol 'arch_get_kallsym' was not declared. Should it be static? Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- Changes in v2: -Remove function arch_get_kallsym(). kernel/kallsyms.c | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/kernel/kallsyms.c b/kernel/kallsyms.c index 8043a90..49c4268 100644 --- a/kernel/kallsyms.c +++ b/kernel/kallsyms.c @@ -454,24 +454,10 @@ struct kallsym_iter { int show_value; }; -int __weak arch_get_kallsym(unsigned int symnum, unsigned long *value, - char *type, char *name) -{ - return -EINVAL; -} - static int get_ksymbol_arch(struct kallsym_iter *iter) { - int ret = arch_get_kallsym(iter->pos - kallsyms_num_syms, - &iter->value, &iter->type, - iter->name); - - if (ret < 0) { - iter->pos_arch_end = iter->pos; - return 0; - } - - return 1; + iter->pos_arch_end = iter->pos; + return 0; } static int get_ksymbol_mod(struct kallsym_iter *iter) -- 1.8.3.1