[PATCH] ARM: start: print debugging info when CONFIG_DEBUG_INITCALLS

Ahmad Fatoum a.fatoum at pengutronix.de
Thu Dec 8 23:49:09 PST 2022


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 at 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 |




More information about the barebox mailing list