<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/scripts/mksysmap, branch v6.4</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v6.4</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v6.4'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2023-04-17T02:03:56Z</updated>
<entry>
<title>scripts/kallsyms: move compiler-generated symbol patterns to mksysmap</title>
<updated>2023-04-17T02:03:56Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2023-03-08T11:52:40Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=320e7c9d4494f7a6f046871678f582a3392235f8'/>
<id>urn:sha1:320e7c9d4494f7a6f046871678f582a3392235f8</id>
<content type='text'>
scripts/kallsyms.c maintains compiler-generated symbols, but we end up
with something similar in scripts/mksysmap to avoid the "Inconsistent
kallsyms data" error. For example, commit c17a2538704f ("mksysmap: Fix
the mismatch of 'L0' symbols in System.map").

They were separately maintained prior to commit 94ff2f63d6a3 ("kbuild:
reuse mksysmap output for kallsyms").

Now that scripts/kallsyms.c parses the output of scripts/mksysmap,
it makes more sense to collect all the ignored patterns to mksysmap.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Reviewed-by: Nick Desaulniers &lt;ndesaulniers@google.com&gt;
</content>
</entry>
<entry>
<title>scripts/kallsyms: exclude symbols generated by itself dynamically</title>
<updated>2023-04-17T02:03:56Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2023-03-08T11:52:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ca09bf48f99bdc08e17da11aeae56b7ea132b7c8'/>
<id>urn:sha1:ca09bf48f99bdc08e17da11aeae56b7ea132b7c8</id>
<content type='text'>
Drop the symbols generated by scripts/kallsyms itself automatically
instead of maintaining the symbol list manually.

Pass the kallsyms object from the previous kallsyms step (if it exists)
as the third parameter of scripts/mksysmap, which will weed out the
generated symbols from the input to the next kallsyms step.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>scripts/mksysmap: use sed with in-line comments</title>
<updated>2023-04-17T02:03:56Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2023-03-08T11:52:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c4802044a0a7d7dfa82af858c2fa3ae9d76249c4'/>
<id>urn:sha1:c4802044a0a7d7dfa82af858c2fa3ae9d76249c4</id>
<content type='text'>
It is not feasible to insert comments in a multi-line shell command.
Use sed, and move comments close to the code.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>scripts/mksysmap: remove comments described in nm(1)</title>
<updated>2023-04-17T02:03:56Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2023-03-08T11:52:37Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e9f76363d0aa2d7c01288d9aad79b7e44855a435'/>
<id>urn:sha1:e9f76363d0aa2d7c01288d9aad79b7e44855a435</id>
<content type='text'>
I do not think we need to repeat what is written in 'man nm'.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>kallsyms: ignore __kstrtab_* and __kstrtabns_* symbols</title>
<updated>2022-10-02T18:51:58Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2022-09-26T09:02:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d32b55f4bb43466bc6cdd98a00f8a600bbf7e8ec'/>
<id>urn:sha1:d32b55f4bb43466bc6cdd98a00f8a600bbf7e8ec</id>
<content type='text'>
Every EXPORT_SYMBOL creates __kstrtab_* and __kstrtabns_*, which
consumes 15-20% of the kallsyms entries.

For example, on the system built from the x86_64 defconfig,

  $ cat /proc/kallsyms | wc
     129527    388581   5685465
  $ cat /proc/kallsyms | grep __kstrtab | wc
      23489     70467   1187932

We already ignore __crc_* symbols populated by EXPORT_SYMBOL, so it
should be fine to ignore __kstrtab_* and __kstrtabns_* as well.

This makes vmlinux a bit smaller.

  $ size vmlinux.before vmlinux.after
     text    data     bss     dec     hex filename
  22785374        8559694 1413328 32758396        1f3da7c vmlinux.before
  22785374        8137806 1413328 32336508        1ed6a7c vmlinux.after

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>kallsyms: drop duplicated ignore patterns from kallsyms.c</title>
<updated>2022-10-02T09:06:05Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2022-09-26T09:02:27Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a2833d1b07ab107db71a18e6f3855f6908886361'/>
<id>urn:sha1:a2833d1b07ab107db71a18e6f3855f6908886361</id>
<content type='text'>
Now that kallsyms.c parses the output from mksysmap, some symbols have
already been dropped.

Move comments to scripts/mksysmap. Also, make the grep command readable.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>mksysmap: update comment about __crc_*</title>
<updated>2022-10-02T09:06:05Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2022-09-26T09:02:25Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c13461693ea21d787f82232ce3a5667da370d973'/>
<id>urn:sha1:c13461693ea21d787f82232ce3a5667da370d973</id>
<content type='text'>
Since commit 7b4537199a4a ("kbuild: link symbol CRCs at final link,
removing CONFIG_MODULE_REL_CRCS"), __crc_* symbols never become
absolute.

Keep ignoring __crc_*, but update the comment.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>mksysmap: Fix the mismatch of 'L0' symbols in System.map</title>
<updated>2022-09-09T20:35:13Z</updated>
<author>
<name>Youling Tang</name>
<email>tangyouling@loongson.cn</email>
</author>
<published>2022-09-01T11:10:59Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c17a2538704f926ee4d167ba625e09b1040d8439'/>
<id>urn:sha1:c17a2538704f926ee4d167ba625e09b1040d8439</id>
<content type='text'>
When System.map was generated, the kernel used mksysmap to filter the
kernel symbols, we need to filter "L0" symbols in LoongArch architecture.

$ cat System.map | grep L0
9000000000221540 t L0

The L0 symbol exists in System.map, but not in .tmp_System.map. When
"cmp -s System.map .tmp_System.map" will show "Inconsistent kallsyms
data" error message in link-vmlinux.sh script.

Signed-off-by: Youling Tang &lt;tangyouling@loongson.cn&gt;
Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>mksysmap: Fix the mismatch of '.L' symbols in System.map</title>
<updated>2020-06-06T14:39:20Z</updated>
<author>
<name>ashimida</name>
<email>ashimida@linux.alibaba.com</email>
</author>
<published>2020-06-02T07:45:17Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=72d24accf02add25e08733f0ecc93cf10fcbd88c'/>
<id>urn:sha1:72d24accf02add25e08733f0ecc93cf10fcbd88c</id>
<content type='text'>
When System.map was generated, the kernel used mksysmap to
filter the kernel symbols, but all the symbols with the
second letter 'L' in the kernel were filtered out, not just
the symbols starting with 'dot + L'.

For example:
ashimida@ubuntu:~/linux$ cat System.map |grep ' .L'
ashimida@ubuntu:~/linux$ nm -n vmlinux |grep ' .L'
ffff0000088028e0 t bLength_show
......
ffff0000092e0408 b PLLP_OUTC_lock
ffff0000092e0410 b PLLP_OUTA_lock

The original intent should be to filter out all local symbols
starting with '.L', so the dot should be escaped.

Fixes: 00902e984732 ("mksysmap: Add h8300 local symbol pattern")
Signed-off-by: ashimida &lt;ashimida@linux.alibaba.com&gt;
Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
</content>
</entry>
<entry>
<title>mksysmap: Add h8300 local symbol pattern</title>
<updated>2015-06-23T04:35:47Z</updated>
<author>
<name>Yoshinori Sato</name>
<email>ysato@users.sourceforge.jp</email>
</author>
<published>2015-03-09T06:30:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=00902e984732e93f0aa7caec26dbebfcfbb9a829'/>
<id>urn:sha1:00902e984732e93f0aa7caec26dbebfcfbb9a829</id>
<content type='text'>
h8300's nm output have a lot of local symbols.
ex)
00000000 N .Lframe0
00000013 N .LLST1
00000026 N .LLST2
00000039 N .LLST3
0000004c N .LLST4
Added new pattern " .L" to filter rule.

Signed-off-by: Yoshinori Sato &lt;ysato@users.sourceforge.jp&gt;
</content>
</entry>
</feed>
