diff options
author | Jim Cromie <jim.cromie@gmail.com> | 2020-07-19 17:10:46 -0600 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-07-24 17:00:08 +0200 |
commit | 81d0c2c60942cf35daf3fc18d42606f669fcf44c (patch) | |
tree | b900e4795e0931a86592978382745de69879d60f /net/decnet/Kconfig | |
parent | e5ebffe18e5add85acb23c7a0f74509749967204 (diff) |
dyndbg: fix overcounting of ram used by dyndbg
during dyndbg init, verbose logging prints its ram overhead. It
counted strlens of struct _ddebug's 4 string members, in all callsite
entries, which would be approximately correct if each had been
mallocd. But they are pointers into shared .rodata; for example, all
10 kobject callsites have identical filename, module values.
Its best not to count that memory at all, since we cannot know they
were linked in because of CONFIG_DYNAMIC_DEBUG=y, and we want to
report a number that reflects what ram is saved by deconfiguring it.
Also fix wording and size under-reporting of the __dyndbg section.
Heres my overhead, on a virtme-run VM on a fedora-31 laptop:
dynamic_debug:dynamic_debug_init: 260 modules, 2479 entries \
and 10400 bytes in ddebug tables, 138824 bytes in __dyndbg section
Acked-by: <jbaron@akamai.com>
Signed-off-by: Jim Cromie <jim.cromie@gmail.com>
Link: https://lore.kernel.org/r/20200719231058.1586423-7-jim.cromie@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/decnet/Kconfig')
0 files changed, 0 insertions, 0 deletions