Patch "rtla/hwnoise: Reduce runtime to 75%" has been added to the 6.4-stable tree

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

 



This is a note to let you know that I've just added the patch titled

    rtla/hwnoise: Reduce runtime to 75%

to the 6.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     rtla-hwnoise-reduce-runtime-to-75.patch
and it can be found in the queue-6.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit dd9ea04419dd9d3dedf0b5630efd45dd59231de1
Author: Daniel Bristot de Oliveira <bristot@xxxxxxxxxx>
Date:   Tue Jun 6 18:12:22 2023 +0200

    rtla/hwnoise: Reduce runtime to 75%
    
    [ Upstream commit 7bc4d3089a50050d4df0af63423a5d907c3bdb1a ]
    
    osnoise runs 100% of time by default. It makes sense because osnoise
    is preemptive. hwnoise checks preemption once a second, so it
    reduces system progress.
    
    Reduce runtime to 75% to avoid problems by default. I added a Fixes
    as it might avoid problems for first time users as it lands on distros.
    
    Link: https://lkml.kernel.org/r/af0b7113ffc00031b9af4bb40ef5889a27dadf8c.1686066600.git.bristot@xxxxxxxxxx
    
    Cc: William White <chwhite@xxxxxxxxxx>
    Cc: Jonathan Corbet <corbet@xxxxxxx>
    Tested-by: Juri Lelli <juri.lelli@xxxxxxxxxx>
    Fixes: 1f428356c38d ("rtla: Add hwnoise tool")
    Signed-off-by: Daniel Bristot de Oliveira <bristot@xxxxxxxxxx>
    Signed-off-by: Steven Rostedt (Google) <rostedt@xxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/tools/tracing/rtla/src/osnoise_top.c b/tools/tracing/rtla/src/osnoise_top.c
index 562f2e4b18c57..3ece8c09ecd95 100644
--- a/tools/tracing/rtla/src/osnoise_top.c
+++ b/tools/tracing/rtla/src/osnoise_top.c
@@ -340,8 +340,14 @@ struct osnoise_top_params *osnoise_top_parse_args(int argc, char **argv)
 	if (!params)
 		exit(1);
 
-	if (strcmp(argv[0], "hwnoise") == 0)
+	if (strcmp(argv[0], "hwnoise") == 0) {
 		params->mode = MODE_HWNOISE;
+		/*
+		 * Reduce CPU usage for 75% to avoid killing the system.
+		 */
+		params->runtime = 750000;
+		params->period = 1000000;
+	}
 
 	while (1) {
 		static struct option long_options[] = {



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux