diff options
author | Petr Mladek <pmladek@suse.com> | 2021-11-22 14:26:47 +0100 |
---|---|---|
committer | Petr Mladek <pmladek@suse.com> | 2021-12-06 14:07:57 +0100 |
commit | f873efe841f813303e8a4af0d4cc48ff1f43bbe2 (patch) | |
tree | 863485b6d4c9e739a99a29c25f190098aeec9f43 /tools/perf/scripts/python/stackcollapse.py | |
parent | a6953370d2fcf8c3878f1588771d20d3d972fcf3 (diff) |
printk/console: Remove unnecessary need_default_console manipulation
There is no need to clear @need_default_console when a console
preferred by the command line, device tree, or SPCR, gets enabled.
The code is called only when some non-braille console matched a console
in @console_cmdline array. It means that a non-braille console was added
in __add_preferred_console() and the variable preferred_console is set
to a number >= 0. As a result, @need_default_console is always set to
"false" in the magic condition:
if (need_default_console || bcon || !console_drivers)
need_default_console = preferred_console < 0;
This is one small step in removing the above magic condition
that is hard to follow.
The patch removes one superfluous assignment and should not change
the functionality.
Signed-off-by: Petr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/20211122132649.12737-4-pmladek@suse.com
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions