[PATCH 1/3] at91sam9: add detection of low power sdram
Jean-Christophe PLAGNIOL-VILLARD
plagnioj at jcrosoft.com
Tue Nov 13 16:13:16 EST 2012
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj at jcrosoft.com>
---
arch/arm/mach-at91/include/mach/at91sam9_sdramc.h | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/arm/mach-at91/include/mach/at91sam9_sdramc.h b/arch/arm/mach-at91/include/mach/at91sam9_sdramc.h
index 1ab61e9..971a772 100644
--- a/arch/arm/mach-at91/include/mach/at91sam9_sdramc.h
+++ b/arch/arm/mach-at91/include/mach/at91sam9_sdramc.h
@@ -110,6 +110,11 @@ static inline u32 at91_get_sdram_size(void)
return size;
}
+
+static inline bool at91_is_low_power_sdram(void)
+{
+ return at91_sys_read(AT91_SDRAMC_MDR) & AT91_SDRAMC_MD_LOW_POWER_SDRAM;
+}
#endif
#endif
--
1.7.10.4
More information about the barebox
mailing list