[coreboot] [PATCH] Debugging facility improvements

Peter Stuge peter at stuge.se
Tue Oct 12 09:46:47 CEST 2010


Uwe Hermann wrote:
> Debugging facility improvements.
> 
>  - Hook up malloc() debug code via CONFIG_DEBUG_MALLOC.
> 
>  - Get rid of a custom "debug" macro, use printk() as usual.
> 
> Signed-off-by: Uwe Hermann <uwe at hermann-uwe.de>
> 
> Index: src/Kconfig
> ===================================================================
> --- src/Kconfig	(Revision 5940)
> +++ src/Kconfig	(Arbeitskopie)
> @@ -553,6 +553,16 @@
>  
>  	  If unsure, say N.
>  
> +config DEBUG_MALLOC
> +	bool "Output verbose malloc debug messages"
> +	default n
> +	help
> +	  This option enables additional malloc related debug messages.
> +
> +	  Note: This option will increase the size of the coreboot image.
> +
> +	  If unsure, say N.

Should this also force debug level to SPEW?


> +++ src/lib/malloc.c	(Arbeitskopie)
> @@ -1,11 +1,12 @@
>  #include <stdlib.h>
>  #include <console/console.h>
>  
> -#if 0
> +#if CONFIG_DEBUG_MALLOC
> +#define MALLOCDBG(x...) printk(BIOS_SPEW, x)
> +#else

So that messages actually always show up when the option is selected?


//Peter




More information about the coreboot mailing list