ARM: at91: pm: fix SRAM allocation
authorAlexandre Belloni <alexandre.belloni@free-electrons.com>
Tue, 3 Mar 2015 07:38:07 +0000 (08:38 +0100)
committerNicolas Ferre <nicolas.ferre@atmel.com>
Tue, 3 Mar 2015 19:07:13 +0000 (20:07 +0100)
commit4a031f7dbe497a66cd18b33fc6e5ce2e889d89c7
treeb8ccfa8b22924c250f4ee4725813c498582fb174
parent84e871660bebfddb9a62ebd6f19d02536e782f0a
ARM: at91: pm: fix SRAM allocation

On some platforms, there are multiple SRAM nodes defined in the device tree but
some of them are disabled, leading to allocation failure. Try to find the first
enabled SRAM node and allocate from it.

Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Tested-by: Wenyou Yang <wenyou.yang@atmel.com>
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
arch/arm/mach-at91/pm.c