OMAP3: cpuidle: re-organize the C-states data
authorJean Pihet <j-pihet@ti.com>
Mon, 9 May 2011 10:02:14 +0000 (12:02 +0200)
committerKevin Hilman <khilman@ti.com>
Fri, 20 May 2011 15:15:53 +0000 (17:15 +0200)
commitbadc303a862ba6c5fd3d324f5332db07877f8159
treecc6fead2e9a18924b85a56d68b7fcd63f744cac4
parent866ba0ef967c693dae952afafcb1582a390a82a0
OMAP3: cpuidle: re-organize the C-states data

The current implementation defines an internal structure and a
C-states array. Using those structures is redundant to the
structs used by the cpuidle framework.

This patch provides a clean-up of the internal struct, removes the
internal C-states array, stores the data using the existing cpuidle
per C-state struct and registers the mach specific data to cpuidle
C-state driver_data (accessed using cpuidle_[gs]et_statedata).
Also removes unused macros, fields and code and compacts the repeating
code using an inline helper function.

The result is more compact and more readable code as well as
reduced data RAM usage.

Also retain C1 as the only always valid C-state and system safe state.

Signed-off-by: Jean Pihet <j-pihet@ti.com>
Signed-off-by: Kevin Hilman <khilman@ti.com>
arch/arm/mach-omap2/cpuidle34xx.c