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]
Date:	Mon, 11 May 2009 19:43:17 +0300
From:	Janne Kulmala <janne.t.kulmala@....fi>
To:	Thomas Gleixner <tglx@...utronix.de>
CC:	Frans Pop <elendil@...net.nl>, linux-kernel@...r.kernel.org,
	Steven Rostedt <rostedt@...dmis.org>, len.brown@...el.com,
	mingo@...e.hu, johnstul@...ibm.com
Subject: Re: [PATCH] ACPI: do not mark TSC unstable for invalid C-states

Thomas Gleixner wrote:
> commit a71e4917dc0ebbcb5a0ecb7ca3486643c1c9a6e2 (ACPI: idle:
> mark_tsc_unstable() at init-time, not run-time) marks TSC unstable
> even on non affected systems.
> 
> The reason is that the state enumeration does not check the cx->valid
> flag before calling tsc_halts_in_c(), so it marks TSC unstable for any
> enumerated albeit invalid C state which is known to turn off TSC.
> 
> Check cx->valid before checking whether the TSC might become unstable.
> 
> Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
> ---
>  drivers/acpi/processor_idle.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> Index: linux-2.6/drivers/acpi/processor_idle.c
> ===================================================================
> --- linux-2.6.orig/drivers/acpi/processor_idle.c
> +++ linux-2.6/drivers/acpi/processor_idle.c
> @@ -583,7 +583,7 @@ static int acpi_processor_power_verify(s
>  
>  #if defined (CONFIG_GENERIC_TIME) && defined (CONFIG_X86)
>  		/* TSC could halt in idle, so notify users */
> -		if (tsc_halts_in_c(cx->type))
> +		if (cx->valid && tsc_halts_in_c(cx->type))
>  			mark_tsc_unstable("TSC halts in idle");;

Small suggestion: can we fix the double ';' here at the same time?

>  #endif
>  		switch (cx->type) {
> 
> 

Janne
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ