From 6f3d4e0790fda22ded54940778a243c9a9a49b58 Mon Sep 17 00:00:00 2001 From: areviu Date: Sat, 13 Jan 2018 12:11:08 +0000 Subject: fixed missing check for HAL_USE_SDMMC git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@11266 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc.c | 4 ++++ os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_cmds.c | 4 ++++ os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_device.c | 5 +++++ os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_ff.c | 5 +++++ os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_mmc.c | 4 ++++ os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_pmc.c | 4 ++++ os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sd.c | 3 +++ os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sdio.c | 5 +++++ os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_tc.c | 4 ++++ 9 files changed, 38 insertions(+) (limited to 'os/hal/ports/SAMA/LLD/SDMMCv1') diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc.c index c47c520af..aabf0d153 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc.c @@ -1,5 +1,8 @@ #include #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) + #include "sama_sdmmc_lld.h" #include "ch_sdmmc_device.h" #include "ch_sdmmc_cmds.h" @@ -502,4 +505,5 @@ uint32_t SdmmcDecodeTransSpeed(uint32_t code, return speed; } +#endif diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_cmds.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_cmds.c index 2a9b8a529..cfe49ebea 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_cmds.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_cmds.c @@ -1,5 +1,8 @@ #include #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) + #include "sama_sdmmc_lld.h" #include "ch_sdmmc_device.h" #include "ch_sdmmc_cmds.h" @@ -1249,3 +1252,4 @@ static void _ResetCmd(sSdmmcCommand * pCmd) memset(pCmd, 0, sizeof (sSdmmcCommand)); } +#endif diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_device.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_device.c index 8c05bf133..9c1163d95 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_device.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_device.c @@ -1,5 +1,8 @@ #include #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) + #include "sama_sdmmc_lld.h" #include "ch_sdmmc_device.h" #include "ch_sdmmc_cmds.h" @@ -2008,3 +2011,5 @@ static uint8_t sdmmc_set_bus_width(SdmmcDriver *driver, uint8_t bits) } return rc; } + +#endif diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_ff.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_ff.c index 49b667bd7..7d764886d 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_ff.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_ff.c @@ -39,6 +39,9 @@ */ #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) + #include "ccportab.h" #include "ffconf.h" #include "diskio.h" @@ -305,3 +308,5 @@ DRESULT disk_ioctl(BYTE slot, BYTE cmd, void* buff) } return res; } +#endif + diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_mmc.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_mmc.c index 601c95f2a..99ad68962 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_mmc.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_mmc.c @@ -1,5 +1,8 @@ #include #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) + #include "sama_sdmmc_lld.h" #include "ch_sdmmc_device.h" #include "ch_sdmmc_cmds.h" @@ -373,3 +376,4 @@ uint8_t MmcInit(SdmmcDriver *driver) return SDMMC_OK; } #endif +#endif diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_pmc.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_pmc.c index 8a75a8656..0d4c2616b 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_pmc.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_pmc.c @@ -1,4 +1,7 @@ #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) + #include "sama_sdmmc_lld.h" #include "ch_sdmmc_pmc.h" @@ -828,4 +831,5 @@ void pmc_disable_internal_osc(void) } +#endif diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sd.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sd.c index 6363a0fac..a27d0b819 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sd.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sd.c @@ -1,5 +1,7 @@ #include #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) #include "sama_sdmmc_lld.h" #include "ch_sdmmc_device.h" #include "ch_sdmmc_cmds.h" @@ -1169,3 +1171,4 @@ static uint8_t _WaitUntilReady(SdmmcDriver *driver, uint32_t last_dev_status) return SDMMC_BUSY; } +#endif diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sdio.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sdio.c index 871788f0a..c9916620a 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sdio.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_sdio.c @@ -1,4 +1,7 @@ #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) + #include "sama_sdmmc_lld.h" #include "ch_sdmmc_device.h" #include "ch_sdmmc_sdio.h" @@ -286,3 +289,5 @@ void SDIO_DumpCardInformation(SdmmcDriver *sdmmcp) } } #endif + +#endif diff --git a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_tc.c b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_tc.c index 9b66742c7..00f8a998e 100644 --- a/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_tc.c +++ b/os/hal/ports/SAMA/LLD/SDMMCv1/ch_sdmmc_tc.c @@ -1,4 +1,7 @@ #include "hal.h" + +#if (HAL_USE_SDMMC == TRUE) + #include "sama_sdmmc_lld.h" #include "ch_sdmmc_pmc.h" #include "ch_sdmmc_tc.h" @@ -252,3 +255,4 @@ uint32_t tc_get_cv(Tc* tc, uint32_t channel) } #endif +#endif -- cgit v1.2.3