OMAP: powerdomain: split pwrdm_init() into two functions
authorPaul Walmsley <paul@pwsan.com>
Wed, 14 Sep 2011 22:01:21 +0000 (16:01 -0600)
committerPaul Walmsley <paul@pwsan.com>
Wed, 14 Sep 2011 23:20:44 +0000 (17:20 -0600)
commit129c65ee66a97fbf663f2f5fce26aacdc7348736
tree50c732a7a31d8443212d95a428515952c839592f
parenta5ffef6af127721a813d70f87cd8cc348ea9d6ab
OMAP: powerdomain: split pwrdm_init() into two functions

In preparation for OMAP_CHIP() removal, split pwrdm_init() into three
functions.  This allows some of them to be called multiple times: for
example, pwrdm_register_pwrdms() can be called once to register
powerdomains that are common to a group of SoCs, and once to register
powerdomains that are specific to a single SoC.

The appropriate order to call these functions - which is enforced
by the code - is:

1. pwrdm_register_platform_funcs()
2. pwrdm_register_pwrdms() (can be called multiple times)
3. pwrdm_complete_init()

Convert the OMAP2, 3, and 4 powerdomain init code to use these new
functions.

While here, improve documentation, and increase CodingStyle
conformance by shortening some local variable names.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
arch/arm/mach-omap2/powerdomain.c
arch/arm/mach-omap2/powerdomain.h
arch/arm/mach-omap2/powerdomains2xxx_data.c
arch/arm/mach-omap2/powerdomains3xxx_data.c
arch/arm/mach-omap2/powerdomains44xx_data.c