Re: [PATCH v2 2/2] ARM: at91: pm: switch to the PIE infrastructure

2016-06-29 Thread Alexander Stein
On Wednesday 29 June 2016 09:57:14, Alexandre Belloni wrote: > On 29/06/2016 at 08:12:21 +0200, Alexander Stein wrote : > > > +#if defined(CONFIG_CPU_V7) > > > + dsb(); > > > + wfi(); > > > +#else > > > + asm volatile ("mcr p15, 0, %0, c7, c0, 4" \ > > > + : : "r" (0) : "memory")

Re: [PATCH v2 2/2] ARM: at91: pm: switch to the PIE infrastructure

2016-06-29 Thread Alexandre Belloni
On 29/06/2016 at 08:12:21 +0200, Alexander Stein wrote : > > +#if defined(CONFIG_CPU_V7) > > + dsb(); > > + wfi(); > > +#else > > + asm volatile ("mcr p15, 0, %0, c7, c0, 4" \ > > + : : "r" (0) : "memory"); > > +#endif > > Why not defining wfi() for __LINUX_ARM_ARCH__ <

Re: [PATCH v2 2/2] ARM: at91: pm: switch to the PIE infrastructure

2016-06-28 Thread Alexander Stein
On Wednesday 29 June 2016 00:44:46, Alexandre Belloni wrote: > Using the PIE infrastructure allows to write the whole suspend/resume > functions in C instead of assembly. > > The only remaining assembly instruction is wfi for armv5 > It makes the code shorter and clearer. > > Signed-off-by: Alexa

[PATCH v2 2/2] ARM: at91: pm: switch to the PIE infrastructure

2016-06-28 Thread Alexandre Belloni
Using the PIE infrastructure allows to write the whole suspend/resume functions in C instead of assembly. The only remaining assembly instruction is wfi for armv5 It makes the code shorter and clearer. Signed-off-by: Alexandre Belloni --- arch/arm/mach-at91/Kconfig | 1 + arch/arm/mach-