Commit a9a54cae authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Robert Jarzmik

ARM: pxa: move extern declarations to pm.h

When CONFIG_IWMMXT is disabled, we get a warning in pxa3xx.c:

arch/arm/mach-pxa/pxa3xx.c: In function 'pxa3xx_cpu_pm_suspend':
arch/arm/mach-pxa/pxa3xx.c:109:2: error: ISO C90 forbids mixed declarations and code [-Werror=declaration-after-statement]

It turns out that there is an 'extern' declaration in the
middle of a function.

For consistency, this moves the declaration and two others from
the same file into pm.h.
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarRobert Jarzmik <robert.jarzmik@free.fr>
parent 2f202861
...@@ -29,6 +29,9 @@ extern int pxa_pm_enter(suspend_state_t state); ...@@ -29,6 +29,9 @@ extern int pxa_pm_enter(suspend_state_t state);
extern int pxa_pm_prepare(void); extern int pxa_pm_prepare(void);
extern void pxa_pm_finish(void); extern void pxa_pm_finish(void);
extern const char pm_enter_standby_start[], pm_enter_standby_end[];
extern int pxa3xx_finish_suspend(unsigned long);
/* NOTE: this is for PM debugging on Lubbock, it's really a big /* NOTE: this is for PM debugging on Lubbock, it's really a big
* ugly, but let's keep the crap minimum here, instead of direct * ugly, but let's keep the crap minimum here, instead of direct
* accessing the LUBBOCK CPLD registers in arch/arm/mach-pxa/pm.c * accessing the LUBBOCK CPLD registers in arch/arm/mach-pxa/pm.c
......
...@@ -68,7 +68,6 @@ static unsigned long wakeup_src; ...@@ -68,7 +68,6 @@ static unsigned long wakeup_src;
*/ */
static void pxa3xx_cpu_standby(unsigned int pwrmode) static void pxa3xx_cpu_standby(unsigned int pwrmode)
{ {
extern const char pm_enter_standby_start[], pm_enter_standby_end[];
void (*fn)(unsigned int) = (void __force *)(sram + 0x8000); void (*fn)(unsigned int) = (void __force *)(sram + 0x8000);
memcpy_toio(sram + 0x8000, pm_enter_standby_start, memcpy_toio(sram + 0x8000, pm_enter_standby_start,
...@@ -106,8 +105,6 @@ static void pxa3xx_cpu_pm_suspend(void) ...@@ -106,8 +105,6 @@ static void pxa3xx_cpu_pm_suspend(void)
asm volatile("mra %Q0, %R0, acc0" : "=r" (acc0)); asm volatile("mra %Q0, %R0, acc0" : "=r" (acc0));
#endif #endif
extern int pxa3xx_finish_suspend(unsigned long);
/* resuming from D2 requires the HSIO2/BOOT/TPM clocks enabled */ /* resuming from D2 requires the HSIO2/BOOT/TPM clocks enabled */
CKENA |= (1 << CKEN_BOOT) | (1 << CKEN_TPM); CKENA |= (1 << CKEN_BOOT) | (1 << CKEN_TPM);
CKENB |= 1 << (CKEN_HSIO2 & 0x1f); CKENB |= 1 << (CKEN_HSIO2 & 0x1f);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment