diff options
author | Masahiro Yamada <masahiroy@kernel.org> | 2024-05-20 14:42:10 +0200 |
---|---|---|
committer | Masahiro Yamada <masahiroy@kernel.org> | 2024-05-29 09:40:03 +0200 |
commit | b18b047002b7d3b19d9fb905c1bd2a214016c153 (patch) | |
tree | 94e2250d7553c8beae7413a07cb4a40a16d4a6d9 /scripts/mksysmap | |
parent | kbuild: avoid unneeded kallsyms step 3 (diff) | |
download | linux-b18b047002b7d3b19d9fb905c1bd2a214016c153.tar.xz linux-b18b047002b7d3b19d9fb905c1bd2a214016c153.zip |
kbuild: change scripts/mksysmap into sed script
The previous commit removed the subshell execution from scripts/mksysmap,
which is now simple enough to become a sed script.
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Diffstat (limited to 'scripts/mksysmap')
-rwxr-xr-x | scripts/mksysmap | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/scripts/mksysmap b/scripts/mksysmap index e46bafe333bd..c12723a04655 100755 --- a/scripts/mksysmap +++ b/scripts/mksysmap @@ -1,22 +1,16 @@ -#!/bin/sh -x -# Based on the vmlinux file create the System.map file +#!/bin/sed -f +# SPDX-License-Identifier: GPL-2.0-only +# +# sed script to filter out symbols that are not needed for System.map, +# or not suitable for kallsyms. The input should be 'nm -n <file>'. +# # System.map is used by module-init tools and some debugging # tools to retrieve the actual addresses of symbols in the kernel. # -# Usage -# mksysmap vmlinux System.map - - -##### -# Generate System.map (actual filename passed as second argument) -# The following refers to the symbol type as per nm(1). - # readprofile starts reading symbols when _stext is found, and # continue until it finds a symbol which is not either of 'T', 't', # 'W' or 'w'. # - -${NM} -n ${1} | sed >${2} -e " # --------------------------------------------------------------------------- # Ignored symbol types # @@ -92,4 +86,3 @@ ${NM} -n ${1} | sed >${2} -e " # ppc stub /\.long_branch\./d /\.plt_branch\./d -" |