Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp773736ybc; Sat, 23 Nov 2019 08:07:25 -0800 (PST) X-Google-Smtp-Source: APXvYqwFuCmWtdT2zK18cZVodE7Q+vP69gPjeocgaweCdqdGF9NOWenKwq4+oE+7VtWzNSrk4EWg X-Received: by 2002:a17:906:edd2:: with SMTP id sb18mr28594268ejb.112.1574525245810; Sat, 23 Nov 2019 08:07:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574525245; cv=none; d=google.com; s=arc-20160816; b=lJySILi5uFWvMG4qzzt/G8z+rsW5mQpbQlRO7gS34pgVI447IqMY8kk1ptHmCx+JEp uoy17s/VTEgkboLoEUqXkBoV1U13qZbwU9fAN6RnZq84JVya51lsbMnT0oIaulPMfkpI faYjO6ZjZV123Ifh8eq9wV69dyg0Oi4fk9duxbtzEL4vvUuQxrUTh/SI7KW5khmw9qn4 XIFPiq2j0PLx5AeojmIPEo2sRYvG8t2HoHjPw517yw+psMV4OBBgSSA5Q7dqozlBy/xL GmDWeBNKZUD35b70NRSm+7nSp3xMMa5OmRptQwTF4E4IL+fTlwoRPCjPCydjoIu1qPB/ 2wUw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter; bh=9iKDRL9d6hTzpOpmUOinbE+RaKJ+14kZ7Ic+FqY8y+Y=; b=hq2e/XMXwzZUrJG3FuN5YPMc0GcR335bug0zk/3vBNz7pmcpFtxJAW5ubBwrew7Yiz TACWscKJ9wFOPPH1Y5AmOLimEM7JrtIJxQS7VgPXyzu50uStBmuRkSkelefyYOnTODKt WW6WILy5zhIZ+sS/lIbHH6Uz2H9NcHFlHwrFnl51ny2MAeT7lg6ct0zbfaJsep+bnNOf A6ttVMacNoUHiRT4zhPqgSF9Kbe7r2QvgUIx+uaQU3Y5EpciQxTA3D1f1JpAR4WM1yKn PJJFrDF4UhRHqkr65XVxzkhTjOH+V7+yVaPMwgVdt80tnhTzoJycyusMXfYhjMx5WJvs LOYQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=KFpeQPl7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g12si1049930edp.190.2019.11.23.08.07.01; Sat, 23 Nov 2019 08:07:25 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=KFpeQPl7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727165AbfKWQFd (ORCPT + 99 others); Sat, 23 Nov 2019 11:05:33 -0500 Received: from conuserg-12.nifty.com ([210.131.2.79]:49456 "EHLO conuserg-12.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726774AbfKWQFC (ORCPT ); Sat, 23 Nov 2019 11:05:02 -0500 Received: from grover.flets-west.jp (softbank126093102113.bbtec.net [126.93.102.113]) (authenticated) by conuserg-12.nifty.com with ESMTP id xANG4l5T019106; Sun, 24 Nov 2019 01:04:53 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-12.nifty.com xANG4l5T019106 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1574525093; bh=9iKDRL9d6hTzpOpmUOinbE+RaKJ+14kZ7Ic+FqY8y+Y=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KFpeQPl7WSOVE5M+4JYWJ8DMYIoVWCT9dijqhBO0BSP29OO5sbiSI38pWWHLPvQsR 3P2tCKW9H7g5pB3N1UJXUEJTKd77GHg0d+36p4dO0Sy1++uNzc32sO2iMtc/hUE5dX U3Slqh0jkDfZUIZqhHaTMgOv+AawhekGBWj4+qJHz5LSRhrlrcp/AKa9i6DPxm8Fh0 FqxhmXd46eEK7LPhlTg38Tbh7TIYT+U69UZchvJz/Uy0IQ1T9Xj/1NleQbNrneYbBM t76u28L7Rz6MhKlUlcFoIjeHeTGRSsyYwOREi1teDNknwm2oBNv/iczAabOK8Hnup5 Y5V1zze2RuJnw== X-Nifty-SrcIP: [126.93.102.113] From: Masahiro Yamada To: linux-kbuild@vger.kernel.org Cc: Masahiro Yamada , linux-kernel@vger.kernel.org Subject: [PATCH v2 12/16] scripts/kallsyms: move more patterns to the ignored_prefixes array Date: Sun, 24 Nov 2019 01:04:40 +0900 Message-Id: <20191123160444.11251-13-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20191123160444.11251-1-yamada.masahiro@socionext.com> References: <20191123160444.11251-1-yamada.masahiro@socionext.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Refactoring for shortening the code. Signed-off-by: Masahiro Yamada --- Changes in v2: None scripts/kallsyms.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/scripts/kallsyms.c b/scripts/kallsyms.c index 843615c1d384..04a1dd16edcf 100644 --- a/scripts/kallsyms.c +++ b/scripts/kallsyms.c @@ -105,6 +105,8 @@ static bool is_ignored_symbol(const char *name, char type) }; static const char * const ignored_prefixes[] = { + "$", /* local symbols for ARM, MIPS, etc. */ + ".LASANPC", /* s390 kasan local symbols */ "__crc_", /* modversions */ "__efistub_", /* arm64 EFI stub namespace */ NULL @@ -198,19 +200,9 @@ static int read_symbol(FILE *in, struct sym_entry *s) } else if (toupper(stype) == 'U') return -1; - /* - * Ignore generated symbols such as: - * - mapping symbols in ARM ELF files ($a, $t, and $d) - * - MIPS ELF local symbols ($L123 instead of .L123) - */ - else if (sym[0] == '$') - return -1; /* exclude debugging symbols */ else if (stype == 'N' || stype == 'n') return -1; - /* exclude s390 kasan local symbols */ - else if (!strncmp(sym, ".LASANPC", 8)) - return -1; /* include the type field in the symbol name, so that it gets * compressed together */ -- 2.17.1