lkml.org 
[lkml]   [2023]   [Aug]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] cma: introduce CMA_ALLOC_DEBUG config
On Wed, 9 Aug 2023 18:46:40 +0530 Bibek Kumar Patro <quic_bibekkum@quicinc.com> wrote:

> Currently enabling CONFIG_CMA_DEBUG enables DEBUG preprocessor macro.
> If DEBUG is defined, it's equivalent to a printk with KERN_DEBUG loglevel
> flooding the dmesg buffer with pr_debug prints from mm/cma driver and from
> included files as well. This results in excessive amount of CMA logging and
> also might distract the debug teams with unrelated KERN_DEBUG prints.One of
> the ways engineers currently tackle this problem is by passing loglevel=N
> though commandline to suppress KERN_DEBUG messages. This approach can
> sometimes become tiresome due to its repetitive nature.
> This patch proposes an alternative approach by introducing a simple new
> config CONFIG_CMA_ALLOC_DEBUG which only shows the cma bit allocation
> status in case of cma failure and do not enable DEBUG preprocessor macro
> from CONFIG_CMA_DEBUG avoiding excessive CMA logging from pr_debug.
> Engineers and tech teams seeking only for bitmap status in case of cma
> failure can use this simple config instead of worrying about changing
> the loglevel or trying other similar workarounds.

Would it be better to control this at runtime? With a /proc or /sys tunable?

\
 
 \ /
  Last update: 2023-08-10 18:55    [W:0.369 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site