From 29309f101a4828842c377ff11a3a59908aab05f2 Mon Sep 17 00:00:00 2001 From: edolomb Date: Thu, 17 Jan 2019 15:19:20 +0000 Subject: Updated SAMA drivers (still incomplete) git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@12543 110e8d01-0319-4d1e-a829-52ad28d1bb01 --- os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_macros.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_macros.h') diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_macros.h b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_macros.h index 52f82fd03..c973d1e4a 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_macros.h +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_macros.h @@ -2,12 +2,21 @@ #define CH_SDMMC_MACROS_H_ - +#if !defined(CACHE_ALIGNED) #define CACHE_ALIGNED __attribute__((aligned(L1_CACHE_BYTES))) +#endif +/* + * @brief NO CACHE attribute + */ +#if !defined(NO_CACHE) +#define NO_CACHE __attribute__((section (".nocache"))) +#endif #define IS_CACHE_ALIGNED(x) ((((uint32_t)(x)) & (L1_CACHE_BYTES - 1)) == 0) +#if !defined(ROUND_INT_DIV) #define ROUND_INT_DIV(n,d) (((n) + ((d)-1)) / (d)) +#endif #define ROUND_UP_MULT(x,m) (((x) + ((m)-1)) & ~((m)-1)) #define CEIL_INT_DIV(n,d) (((n) + (d) - 1) / (d)) #define ABS_DIFF(a,b) ((a) < (b) ? (b) - (a) : (a) - (b)) -- cgit v1.2.3