[PATCH 0/2] downgrade noisy debug calls in block devices and ramfs
Sascha Hauer
s.hauer at pengutronix.de
Wed Oct 30 01:50:30 PDT 2024
On Tue, Oct 29, 2024 at 03:12:59PM +0100, Stefan Kerkmann wrote:
> Hi Sascha,
>
> On 29.10.24 14:33, Sascha Hauer wrote:
> > On Mon, Oct 28, 2024 at 05:17:00PM +0100, Stefan Kerkmann wrote:
> >> These two patches are the outcome of an investigation why loading a
> >> fitimage from an eMMC took nearly 7s - the sheer amount of generated
> >> debugging messages slowed down the system by a factor of ~21 with
> >> KConfig options:
> >>
> >> CONFIG_COMPILE_LOGLEVEL=7
> >> CONFIG_DEFAULT_LOGLEVEL=6
> >>
> >> Which is the current default combination for barebox.
> >
> > This is not the default combination. The default is:
> >
> > CONFIG_COMPILE_LOGLEVEL=6
> > CONFIG_DEFAULT_LOGLEVEL=7
> >
>
> Oh! You are right, I totally mixed that up.
>
> > The rationale is:
> >
> > Do not compile in debug messages by default (CONFIG_COMPILE_LOGLEVEL=6)
> > unless DEBUG is defined in a source file. When DEBUG is defined then make
> > sure the messages are printed (CONFIG_DEFAULT_LOGLEVEL=7).
> >
> > There are tons of debug messages throughout the code which normally
> > shouldn't be compiled into the binay.
> >
>
> When triaging a problem I like to gather a good overview by generally enabling
> all debugging messages. But the important bits would drown in the block/ramfs
> messages. So I would still argue that it is worthwhile to downgrade the level to
> verbose debug.
Yes, indeed. We should prefer pr_vdebug/dev_vdbg in hotpaths.
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