lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20250514131017.77576-1-lblbjy@gmail.com>
Date: Wed, 14 May 2025 22:10:17 +0900
From: JaeYoon Lee <lblbjy@...il.com>
To: mingo@...hat.com,
	peterz@...radead.org,
	juri.lelli@...hat.com,
	vincent.guittot@...aro.org
Cc: linux-kernel@...r.kernel.org,
	JaeYoon Lee <lblbjy@...il.com>
Subject: [PATCH] sched/loadavg: fix comment for avenrun calculation

The comment in loadavg.c incorrectly states that each avenrun[n] value is
calculated based on avenrun[0], but the code updates each avenrun[n]
independently. This patch fixes the comment to reflect the actual logic.

Signed-off-by: JaeYoon Lee <lblbjy@...il.com>
---
 kernel/sched/loadavg.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/loadavg.c b/kernel/sched/loadavg.c
index c48900b856a2..060b0948c78d 100644
--- a/kernel/sched/loadavg.c
+++ b/kernel/sched/loadavg.c
@@ -22,7 +22,7 @@
  *   for_each_possible_cpu(cpu)
  *	nr_active += cpu_of(cpu)->nr_running + cpu_of(cpu)->nr_uninterruptible;
  *
- *   avenrun[n] = avenrun[0] * exp_n + nr_active * (1 - exp_n)
+ *   avenrun[n] = avenrun[n] * exp_n + nr_active * (1 - exp_n)
  *
  * Due to a number of reasons the above turns in the mess below:
  *
-- 
2.29.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ