On Wed, Jan 03, 2024 at 11:13:08AM +0100, Ahmad Fatoum wrote: > We did not have any protection in place to ensure that KASAN shadow memory > isn't overwritten during boot. Add that now to avoid strange effects > during debugging. > > Signed-off-by: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx> > --- > arch/arm/cpu/start.c | 4 ++++ > 1 file changed, 4 insertions(+) Applied, thanks Sascha > > diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c > index 15f5b2937227..9f4cdfe67fbf 100644 > --- a/arch/arm/cpu/start.c > +++ b/arch/arm/cpu/start.c > @@ -133,6 +133,10 @@ static int barebox_memory_areas_init(void) > request_sdram_region("board data", (unsigned long)barebox_boarddata, > barebox_boarddata_size); > > + if (IS_ENABLED(CONFIG_KASAN)) > + request_sdram_region("kasan shadow", kasan_shadow_base, > + mem_malloc_start() - kasan_shadow_base); > + > return 0; > } > device_initcall(barebox_memory_areas_init); > -- > 2.39.2 > > > -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |