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>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <29626e175f3238ae04451477e38bad875794a61c.camel@intel.com>
Date: Thu, 3 Apr 2025 01:11:53 +0000
From: "Zhang, Rui" <rui.zhang@...el.com>
To: "rafael@...nel.org" <rafael@...nel.org>
CC: "ggherdovich@...e.cz" <ggherdovich@...e.cz>, "linux-pm@...r.kernel.org"
	<linux-pm@...r.kernel.org>, "lenb@...nel.org" <lenb@...nel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"linux-acpi@...r.kernel.org" <linux-acpi@...r.kernel.org>
Subject: Re: [PATCH 2/2] ACPI: processor: idle: Remove obsolete comment

On Tue, 2025-04-01 at 14:13 +0200, Rafael J. Wysocki wrote:
> 
> > So I'm proposing to return the index of the highest valid state
> > directly
> > in acpi_processor_power_verify() and then we don't need this loop any
> > more.
> 
> OK, so I'd prefer to first rename power.count to power.max_index
> (which it really is) and then make the changes you have proposed.

well, in other cases, like in acpi_processor_evaluate_cst() and in the
_LPI case, power.count is still set and used as the total number of
cstates.

in this acpi_processor_get_cstate_info() case, maybe we should drop this
change
-               working++;
+               working = i;
So power.count is still consistent in all these cases.

For the current for loop that overrides power.count, I think we can just
drop it, because no one checks power.count after it, which means no one
actually uses power.count as max_index.

-rui

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ