On Tue, Aug 08, 2023 at 09:21:56AM +0800, Kefeng Wang wrote: > @@ -117,3 +118,17 @@ void __init early_memtest(phys_addr_t start, phys_addr_t end) > do_one_pass(patterns[idx], start, end); > } > } > + > +void memtest_report_meminfo(struct seq_file *m) > +{ > + unsigned long early_memtest_bad_size_kb; > + > + if (!early_memtest_done) > + return; > + > + early_memtest_bad_size_kb = early_memtest_bad_size >> 10; > + if (early_memtest_bad_size && !early_memtest_bad_size_kb) > + early_memtest_bad_size_kb = 1; > + /* When 0 is reported, it means there actually was a successful test */ > + seq_printf(m, "EarlyMemtestBad: %5lu kB\n", early_memtest_bad_size_kb); > +} Doesn't this function need to be under CONFIG_PROC_FS ?