Re: [PATCH v2] workqueue: Control intensive warning threshold through cmdline

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Feb 22, 2024 at 03:28:08PM +0800, Xuewen Yan wrote:
> When CONFIG_WQ_CPU_INTENSIVE_REPORT is set, the kernel will report
> the work functions which violate the intensive_threshold_us repeatedly.
> And now, only when the violate times exceed 4 and is a power of 2,
> the kernel warning could be triggered.
> 
> However, sometimes, even if a long work execution time occurs only once,
> it may cause other work to be delayed for a long time. This may also
> cause some problems sometimes.
> 
> In order to freely control the threshold of warninging, a boot argument
> is added so that the user can control the warning threshold to be printed.
> At the same time, keep the exponential backoff to prevent reporting too much.
> 
> By default, the warning threshold is 4.
> 
> Signed-off-by: Xuewen Yan <xuewen.yan@xxxxxxxxxx>

Applied to wq/for-6.9 with the following edit:

> +	workqueue.cpu_intensive_warning_thresh=<uint>
> +			If CONFIG_WQ_CPU_INTENSIVE_REPORT is set, the kernel
> +			will report the work functions which violate the
> +			intensive_threshold_us repeatedly. In order to prevent
> +			the kernel log from being printed too frequently,
> +			control the frequency and the threshold.
> +
> +			By Default, the threshold is 4 times, and the warning
> +			is limited by powers of 2. On the other hand, 0 will
> +			disable the warning.

I changed this to:

			If CONFIG_WQ_CPU_INTENSIVE_REPORT is set, the kernel
			will report the work functions which violate the
			intensive_threshold_us repeatedly. In order to prevent
			spurious warnings, start printing only after a work
			function has violated this threshold number of times.

			The default is 4 times. 0 disables the warning.

Thanks.

-- 
tejun




[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux