Commit 5b358b0d authored by Matthew Wilcox (Oracle)'s avatar Matthew Wilcox (Oracle) Committed by Petr Mladek

test_printf: Remove custom appending of '|'

Instead of having an ifdef to decide whether to print a |, use the
'append' functionality of the main loop to print it.
Signed-off-by: default avatarMatthew Wilcox (Oracle) <willy@infradead.org>
Reviewed-by: default avatarYafang Shao <laoar.shao@gmail.com>
Reviewed-by: default avatarPetr Mladek <pmladek@suse.com>
Reviewed-by: default avatarAnshuman Khandual <anshuman.khandual@arm.com>
Signed-off-by: default avatarPetr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/20211019142621.2810043-4-willy@infradead.org
parent a25a0854
......@@ -616,12 +616,7 @@ page_flags_test(int section, int node, int zone, int last_cpupid,
if (flags & PAGEFLAGS_MASK) {
snprintf(cmp_buf + size, BUF_SIZE - size, "%s", name);
size = strlen(cmp_buf);
#if SECTIONS_WIDTH || NODES_WIDTH || ZONES_WIDTH || \
LAST_CPUPID_WIDTH || KASAN_TAG_WIDTH
/* Other information also included in page flags */
snprintf(cmp_buf + size, BUF_SIZE - size, "|");
size = strlen(cmp_buf);
#endif
append = true;
}
for (i = 0; i < ARRAY_SIZE(pft); i++) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment