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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20090811175341.GA6328@in.ibm.com>
Date:	Tue, 11 Aug 2009 23:23:41 +0530
From:	Dipankar Sarma <dipankar@...ibm.com>
To:	"Pallipadi, Venkatesh" <venkatesh.pallipadi@...el.com>
Cc:	Pavel Machek <pavel@....cz>, "Rafael J. Wysocki" <rjw@...k.pl>,
	"Li, Shaohua" <shaohua.li@...el.com>,
	Gautham R Shenoy <ego@...ibm.com>,
	Joel Schopp <jschopp@...tin.ibm.com>,
	"Brown, Len" <len.brown@...el.com>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>,
	Balbir Singh <balbir@...ibm.com>,
	Benjamin Herrenschmidt <benh@...nel.crashing.org>,
	Ingo Molnar <mingo@...e.hu>,
	Vaidyanathan Srinivasan <svaidy@...ux.vnet.ibm.com>,
	"Darrick J. Wong" <djwong@...ibm.com>,
	"linuxppc-dev@...ts.ozlabs.org" <linuxppc-dev@...ts.ozlabs.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 0/3] cpu: idle state framework for offline CPUs.

On Mon, Aug 10, 2009 at 05:22:17PM -0700, Pallipadi, Venkatesh wrote:
> Also, I don't think using just the ACPI/BIOS supplied states in _CST is
> right thing to do for offline. _CST is meant for C-state and BIOS may
> not include some C-state in _CST if the system manufacturer thinks that
> the latency is too high for the state to be used as a C-state. That
> limitation applies for C-state as the cpu is expected to come out of
> C-state often and execute code handle interrupts etc. But, that
> restriction does not apply for offline online which is not as frequent
> as C-state entry and it already has big latency with startup IPI, and a
> whole baggage of CPU setup code. So, using BIOS CST info for CPU offline
> state doesn't seem right.
> 
> May be having (to pick a number) 3 possible offline states for all
> platforms with one for halt equivalent and one for deepest possible that
> CPU can handle and one for deepest possible that platform likes for
> C-states may make sense. Will keeps things simpler in terms of usage
> expectations and possibly reduce the misuse oppurtubity?

Yes, I think we should let specific archs advertise a small set
of possible offline states and let the cpu state be set to one of
those only keeping the platform implementation robust.

Here is variant of the original proposal from Gautham -

/sys/devices/system/cpu/cpu<number>/available_states

For example, available state for an Intel platform could be exported as
"online dealloc C1 C6"

online = fully up
dealloc = offline and de-allocated (as in virtualized environment)
C1 = C1 or C1E halt
C6 = C6 sleep

/sys/devices/system/cpu/cpu<number>/state

Writing any of the available states to this file triggers transition to that 
state barring some transitions that are disallowed to keep things simple
(e.g. dealloc cpus support only transition to online).

/sys/devices/system/cpu/cpu<number>/online

Backward compatibility - online = 0 changes state to C6 or dealloc depending
on the platform. online = 1 changes state to online.

Would this make sense ?

Thanks
Dipankar




--
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