* [PATCH] ARM: start: print debugging info when CONFIG_DEBUG_INITCALLS @ 2022-11-01 6:23 Ahmad Fatoum 2022-12-09 7:15 ` Ahmad Fatoum 0 siblings, 1 reply; 5+ messages in thread From: Ahmad Fatoum @ 2022-11-01 6:23 UTC (permalink / raw) To: barebox; +Cc: Ahmad Fatoum Like we now do during PBL, have CONFIG_DEBUG_INITCALLS also activate the early barebox start debug logging just prior to initcall execution. This is useful when debugging early hands and will only be visible if CONFIG_DEBUG_LL is enabled and configured appropriately. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> --- arch/arm/cpu/start.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c index f9b617aa855a..be303514c23d 100644 --- a/arch/arm/cpu/start.c +++ b/arch/arm/cpu/start.c @@ -3,6 +3,10 @@ #define pr_fmt(fmt) "start.c: " fmt +#ifdef CONFIG_DEBUG_INITCALLS +#define DEBUG +#endif + #include <common.h> #include <init.h> #include <linux/sizes.h> -- 2.30.2 ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ARM: start: print debugging info when CONFIG_DEBUG_INITCALLS 2022-11-01 6:23 [PATCH] ARM: start: print debugging info when CONFIG_DEBUG_INITCALLS Ahmad Fatoum @ 2022-12-09 7:15 ` Ahmad Fatoum 2022-12-09 7:32 ` Sascha Hauer 0 siblings, 1 reply; 5+ messages in thread From: Ahmad Fatoum @ 2022-12-09 7:15 UTC (permalink / raw) To: Ahmad Fatoum; +Cc: barebox On 01.11.22 07:23, Ahmad Fatoum wrote: > Like we now do during PBL, have CONFIG_DEBUG_INITCALLS also activate > the early barebox start debug logging just prior to initcall execution. > > This is useful when debugging early hands and will only be visible if > CONFIG_DEBUG_LL is enabled and configured appropriately. > > Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Ping. > --- > arch/arm/cpu/start.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c > index f9b617aa855a..be303514c23d 100644 > --- a/arch/arm/cpu/start.c > +++ b/arch/arm/cpu/start.c > @@ -3,6 +3,10 @@ > > #define pr_fmt(fmt) "start.c: " fmt > > +#ifdef CONFIG_DEBUG_INITCALLS > +#define DEBUG > +#endif > + > #include <common.h> > #include <init.h> > #include <linux/sizes.h> -- 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 | ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ARM: start: print debugging info when CONFIG_DEBUG_INITCALLS 2022-12-09 7:15 ` Ahmad Fatoum @ 2022-12-09 7:32 ` Sascha Hauer 2022-12-09 7:49 ` Ahmad Fatoum 0 siblings, 1 reply; 5+ messages in thread From: Sascha Hauer @ 2022-12-09 7:32 UTC (permalink / raw) To: Ahmad Fatoum; +Cc: barebox On Fri, Dec 09, 2022 at 08:15:49AM +0100, Ahmad Fatoum wrote: > On 01.11.22 07:23, Ahmad Fatoum wrote: > > Like we now do during PBL, have CONFIG_DEBUG_INITCALLS also activate > > the early barebox start debug logging just prior to initcall execution. > > > > This is useful when debugging early hands and will only be visible if > > CONFIG_DEBUG_LL is enabled and configured appropriately. > > > > Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> > > Ping. > > > --- > > arch/arm/cpu/start.c | 4 ++++ > > 1 file changed, 4 insertions(+) > > > > diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c > > index f9b617aa855a..be303514c23d 100644 > > --- a/arch/arm/cpu/start.c > > +++ b/arch/arm/cpu/start.c > > @@ -3,6 +3,10 @@ > > > > #define pr_fmt(fmt) "start.c: " fmt > > > > +#ifdef CONFIG_DEBUG_INITCALLS > > +#define DEBUG > > +#endif I am hesitating to apply this. The main reason is that enabling DEBUG here might break PBL startup and you no longer get to the point for which you enabled CONFIG_DEBUG_INITCALLS in the first hand. How about putting another Kconfig knob to control early debugging here? That would also resolve the issue that "Trace initcalls" doesn't really fit here. Sascha -- 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 | ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ARM: start: print debugging info when CONFIG_DEBUG_INITCALLS 2022-12-09 7:32 ` Sascha Hauer @ 2022-12-09 7:49 ` Ahmad Fatoum 2022-12-09 9:17 ` Sascha Hauer 0 siblings, 1 reply; 5+ messages in thread From: Ahmad Fatoum @ 2022-12-09 7:49 UTC (permalink / raw) To: Sascha Hauer; +Cc: barebox Hi, On 09.12.22 08:32, Sascha Hauer wrote: > On Fri, Dec 09, 2022 at 08:15:49AM +0100, Ahmad Fatoum wrote: >> On 01.11.22 07:23, Ahmad Fatoum wrote: >>> Like we now do during PBL, have CONFIG_DEBUG_INITCALLS also activate >>> the early barebox start debug logging just prior to initcall execution. >>> >>> This is useful when debugging early hands and will only be visible if >>> CONFIG_DEBUG_LL is enabled and configured appropriately. >>> >>> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> >> >> Ping. >> >>> --- >>> arch/arm/cpu/start.c | 4 ++++ >>> 1 file changed, 4 insertions(+) >>> >>> diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c >>> index f9b617aa855a..be303514c23d 100644 >>> --- a/arch/arm/cpu/start.c >>> +++ b/arch/arm/cpu/start.c >>> @@ -3,6 +3,10 @@ >>> >>> #define pr_fmt(fmt) "start.c: " fmt >>> >>> +#ifdef CONFIG_DEBUG_INITCALLS >>> +#define DEBUG >>> +#endif > > I am hesitating to apply this. The main reason is that enabling DEBUG > here might break PBL startup and you no longer get to the point for > which you enabled CONFIG_DEBUG_INITCALLS in the first hand. I can understand the reasoning for the other patch that defines DEBUG globally for PBL, but this one is in barebox proper, so I can't see why itwe would expect DEBUG_INITCALLS to work, but not the debug output in start.c. Cheers, Ahmad > > How about putting another Kconfig knob to control early debugging here? > > That would also resolve the issue that "Trace initcalls" doesn't really > fit here. > > Sascha > -- 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 | ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ARM: start: print debugging info when CONFIG_DEBUG_INITCALLS 2022-12-09 7:49 ` Ahmad Fatoum @ 2022-12-09 9:17 ` Sascha Hauer 0 siblings, 0 replies; 5+ messages in thread From: Sascha Hauer @ 2022-12-09 9:17 UTC (permalink / raw) To: Ahmad Fatoum; +Cc: barebox On Fri, Dec 09, 2022 at 08:49:09AM +0100, Ahmad Fatoum wrote: > Hi, > > On 09.12.22 08:32, Sascha Hauer wrote: > > On Fri, Dec 09, 2022 at 08:15:49AM +0100, Ahmad Fatoum wrote: > >> On 01.11.22 07:23, Ahmad Fatoum wrote: > >>> Like we now do during PBL, have CONFIG_DEBUG_INITCALLS also activate > >>> the early barebox start debug logging just prior to initcall execution. > >>> > >>> This is useful when debugging early hands and will only be visible if > >>> CONFIG_DEBUG_LL is enabled and configured appropriately. > >>> > >>> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> > >> > >> Ping. > >> > >>> --- > >>> arch/arm/cpu/start.c | 4 ++++ > >>> 1 file changed, 4 insertions(+) > >>> > >>> diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c > >>> index f9b617aa855a..be303514c23d 100644 > >>> --- a/arch/arm/cpu/start.c > >>> +++ b/arch/arm/cpu/start.c > >>> @@ -3,6 +3,10 @@ > >>> > >>> #define pr_fmt(fmt) "start.c: " fmt > >>> > >>> +#ifdef CONFIG_DEBUG_INITCALLS > >>> +#define DEBUG > >>> +#endif > > > > I am hesitating to apply this. The main reason is that enabling DEBUG > > here might break PBL startup and you no longer get to the point for > > which you enabled CONFIG_DEBUG_INITCALLS in the first hand. > > I can understand the reasoning for the other patch that defines DEBUG > globally for PBL, but this one is in barebox proper, so I can't see why > itwe would expect DEBUG_INITCALLS to work, but not the debug output > in start.c. Ah, I didn't realize that there are two different patches. Take what I said to the other patch and consider this one applied. Sascha -- 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 | ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-12-09 9:18 UTC | newest] Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2022-11-01 6:23 [PATCH] ARM: start: print debugging info when CONFIG_DEBUG_INITCALLS Ahmad Fatoum 2022-12-09 7:15 ` Ahmad Fatoum 2022-12-09 7:32 ` Sascha Hauer 2022-12-09 7:49 ` Ahmad Fatoum 2022-12-09 9:17 ` Sascha Hauer
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox