forked from Minki/linux
65cc1a59d1
The number of register we can safely pass to at91_pm_suspend_in_sram is limited. Instead, pass the address to the at91_pm_data structure. The offsets are automatically generated to avoid hardcoding them. Acked-by: Wenyou Yang <wenyou.yang@atmel.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
14 lines
415 B
C
14 lines
415 B
C
#include <linux/stddef.h>
|
|
#include <linux/kbuild.h>
|
|
#include "pm.h"
|
|
|
|
int main(void)
|
|
{
|
|
DEFINE(PM_DATA_PMC, offsetof(struct at91_pm_data, pmc));
|
|
DEFINE(PM_DATA_RAMC0, offsetof(struct at91_pm_data, ramc[0]));
|
|
DEFINE(PM_DATA_RAMC1, offsetof(struct at91_pm_data, ramc[1]));
|
|
DEFINE(PM_DATA_MEMCTRL, offsetof(struct at91_pm_data, memctrl));
|
|
DEFINE(PM_DATA_MODE, offsetof(struct at91_pm_data, mode));
|
|
return 0;
|
|
}
|