From 49d71a01abeefa000a4cd7a556052d826b096d49 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Sat, 20 Jul 2013 10:12:44 +0000 Subject: Renamed or added prefix to all hernel configuration options. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/kernel_3_dev@6010 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/platforms/AT91SAM7/adc_lld.h | 4 ++-- os/hal/platforms/AT91SAM7/i2c_lld.h | 4 ++-- os/hal/platforms/AT91SAM7/spi_lld.h | 4 ++-- os/hal/platforms/AVR/i2c_lld.h | 4 ++-- os/hal/platforms/LPC11Uxx/hal_lld.c | 2 +- os/hal/platforms/LPC11Uxx/spi_lld.h | 4 ++-- os/hal/platforms/LPC11xx/hal_lld.c | 2 +- os/hal/platforms/LPC11xx/i2c_lld.h | 4 ++-- os/hal/platforms/LPC11xx/spi_lld.h | 4 ++-- os/hal/platforms/LPC122x/hal_lld.c | 2 +- os/hal/platforms/LPC122x/i2c_lld.h | 4 ++-- os/hal/platforms/LPC122x/spi_lld.h | 4 ++-- os/hal/platforms/LPC13xx/hal_lld.c | 2 +- os/hal/platforms/LPC13xx/spi_lld.h | 4 ++-- os/hal/platforms/LPC214x/spi_lld.h | 4 ++-- os/hal/platforms/LPC8xx/hal_lld.c | 2 +- os/hal/platforms/LPC8xx/spi_lld.h | 4 ++-- os/hal/platforms/Posix/hal_lld.c | 2 +- os/hal/platforms/SPC560BCxx/hal_lld.c | 2 +- os/hal/platforms/SPC560Dxx/hal_lld.c | 2 +- os/hal/platforms/SPC560Pxx/hal_lld.c | 2 +- os/hal/platforms/SPC563Mxx/hal_lld.c | 2 +- os/hal/platforms/SPC564Axx/hal_lld.c | 2 +- os/hal/platforms/SPC56ELxx/hal_lld.c | 2 +- os/hal/platforms/SPC5xx/DSPI_v1/spi_lld.h | 4 ++-- os/hal/platforms/SPC5xx/EQADC_v1/adc_lld.h | 4 ++-- os/hal/platforms/STM32/I2Cv1/i2c_lld.h | 4 ++-- os/hal/platforms/STM32/I2Cv2/i2c_lld.h | 4 ++-- os/hal/platforms/STM32/SPIv1/spi_lld.h | 4 ++-- os/hal/platforms/STM32/SPIv2/spi_lld.h | 4 ++-- os/hal/platforms/STM32F0xx/adc_lld.h | 4 ++-- os/hal/platforms/STM32F0xx/hal_lld.c | 2 +- os/hal/platforms/STM32F1xx/adc_lld.h | 4 ++-- os/hal/platforms/STM32F1xx/hal_lld.c | 2 +- os/hal/platforms/STM32F30x/adc_lld.h | 4 ++-- os/hal/platforms/STM32F30x/hal_lld.c | 2 +- os/hal/platforms/STM32F37x/adc_lld.h | 4 ++-- os/hal/platforms/STM32F37x/hal_lld.c | 2 +- os/hal/platforms/STM32F4xx/adc_lld.h | 4 ++-- os/hal/platforms/STM32F4xx/hal_lld.c | 2 +- os/hal/platforms/STM32L1xx/adc_lld.h | 4 ++-- os/hal/platforms/STM32L1xx/hal_lld.c | 2 +- os/hal/platforms/STM8S/spi_lld.h | 4 ++-- os/hal/platforms/Win32/hal_lld.c | 2 +- 44 files changed, 69 insertions(+), 69 deletions(-) (limited to 'os/hal/platforms') diff --git a/os/hal/platforms/AT91SAM7/adc_lld.h b/os/hal/platforms/AT91SAM7/adc_lld.h index e27931819..fcdd9ecf6 100644 --- a/os/hal/platforms/AT91SAM7/adc_lld.h +++ b/os/hal/platforms/AT91SAM7/adc_lld.h @@ -257,12 +257,12 @@ struct ADCDriver { Thread *thread; #endif #if ADC_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the peripheral. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* ADC_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/AT91SAM7/i2c_lld.h b/os/hal/platforms/AT91SAM7/i2c_lld.h index 8e22acaf6..be4e2f1be 100644 --- a/os/hal/platforms/AT91SAM7/i2c_lld.h +++ b/os/hal/platforms/AT91SAM7/i2c_lld.h @@ -137,12 +137,12 @@ struct I2CDriver{ */ size_t txbytes; #if I2C_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* I2C_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/AT91SAM7/spi_lld.h b/os/hal/platforms/AT91SAM7/spi_lld.h index 18299391a..fda7adbbf 100644 --- a/os/hal/platforms/AT91SAM7/spi_lld.h +++ b/os/hal/platforms/AT91SAM7/spi_lld.h @@ -159,12 +159,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/AVR/i2c_lld.h b/os/hal/platforms/AVR/i2c_lld.h index 9e49cefbe..88a9eb4b9 100644 --- a/os/hal/platforms/AVR/i2c_lld.h +++ b/os/hal/platforms/AVR/i2c_lld.h @@ -125,12 +125,12 @@ struct I2CDriver { */ i2cflags_t errors; #if I2C_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* I2C_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/LPC11Uxx/hal_lld.c b/os/hal/platforms/LPC11Uxx/hal_lld.c index 0e795c1a0..6a16de6f5 100644 --- a/os/hal/platforms/LPC11Uxx/hal_lld.c +++ b/os/hal/platforms/LPC11Uxx/hal_lld.c @@ -54,7 +54,7 @@ void hal_lld_init(void) { /* SysTick initialization using the system clock.*/ nvicSetSystemHandlerPriority(HANDLER_SYSTICK, CORTEX_PRIORITY_SYSTICK); - SysTick->LOAD = LPC_SYSCLK / CH_FREQUENCY - 1; + SysTick->LOAD = LPC_SYSCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/LPC11Uxx/spi_lld.h b/os/hal/platforms/LPC11Uxx/spi_lld.h index 9d15dcee2..46d2e657c 100644 --- a/os/hal/platforms/LPC11Uxx/spi_lld.h +++ b/os/hal/platforms/LPC11Uxx/spi_lld.h @@ -235,12 +235,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/LPC11xx/hal_lld.c b/os/hal/platforms/LPC11xx/hal_lld.c index af14d406a..2c10e3404 100644 --- a/os/hal/platforms/LPC11xx/hal_lld.c +++ b/os/hal/platforms/LPC11xx/hal_lld.c @@ -59,7 +59,7 @@ void hal_lld_init(void) { /* SysTick initialization using the system clock.*/ nvicSetSystemHandlerPriority(HANDLER_SYSTICK, CORTEX_PRIORITY_SYSTICK); - SysTick->LOAD = LPC11xx_SYSCLK / CH_FREQUENCY - 1; + SysTick->LOAD = LPC11xx_SYSCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/LPC11xx/i2c_lld.h b/os/hal/platforms/LPC11xx/i2c_lld.h index b908ba6e4..b33dfe235 100644 --- a/os/hal/platforms/LPC11xx/i2c_lld.h +++ b/os/hal/platforms/LPC11xx/i2c_lld.h @@ -138,12 +138,12 @@ struct I2CDriver { */ i2cflags_t errors; #if I2C_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* I2C_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/LPC11xx/spi_lld.h b/os/hal/platforms/LPC11xx/spi_lld.h index 4d6c56027..677e18062 100644 --- a/os/hal/platforms/LPC11xx/spi_lld.h +++ b/os/hal/platforms/LPC11xx/spi_lld.h @@ -263,12 +263,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/LPC122x/hal_lld.c b/os/hal/platforms/LPC122x/hal_lld.c index 9069434ba..d457c7aea 100644 --- a/os/hal/platforms/LPC122x/hal_lld.c +++ b/os/hal/platforms/LPC122x/hal_lld.c @@ -54,7 +54,7 @@ void hal_lld_init(void) { /* SysTick initialization using the system clock.*/ nvicSetSystemHandlerPriority(HANDLER_SYSTICK, CORTEX_PRIORITY_SYSTICK); - SysTick->LOAD = LPC122x_SYSCLK / CH_FREQUENCY - 1; + SysTick->LOAD = LPC122x_SYSCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/LPC122x/i2c_lld.h b/os/hal/platforms/LPC122x/i2c_lld.h index edff13a95..1603da79c 100644 --- a/os/hal/platforms/LPC122x/i2c_lld.h +++ b/os/hal/platforms/LPC122x/i2c_lld.h @@ -138,12 +138,12 @@ struct I2CDriver { */ i2cflags_t errors; #if I2C_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* I2C_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/LPC122x/spi_lld.h b/os/hal/platforms/LPC122x/spi_lld.h index 0cb48f89f..d53ed620a 100644 --- a/os/hal/platforms/LPC122x/spi_lld.h +++ b/os/hal/platforms/LPC122x/spi_lld.h @@ -209,12 +209,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/LPC13xx/hal_lld.c b/os/hal/platforms/LPC13xx/hal_lld.c index 561537537..553e5f445 100644 --- a/os/hal/platforms/LPC13xx/hal_lld.c +++ b/os/hal/platforms/LPC13xx/hal_lld.c @@ -59,7 +59,7 @@ void hal_lld_init(void) { /* SysTick initialization using the system clock.*/ nvicSetSystemHandlerPriority(HANDLER_SYSTICK, CORTEX_PRIORITY_SYSTICK); - SysTick->LOAD = LPC13xx_SYSCLK / CH_FREQUENCY - 1; + SysTick->LOAD = LPC13xx_SYSCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/LPC13xx/spi_lld.h b/os/hal/platforms/LPC13xx/spi_lld.h index 9328cd69d..ac5621b04 100644 --- a/os/hal/platforms/LPC13xx/spi_lld.h +++ b/os/hal/platforms/LPC13xx/spi_lld.h @@ -263,12 +263,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/LPC214x/spi_lld.h b/os/hal/platforms/LPC214x/spi_lld.h index 9def6f16a..528e7ca88 100644 --- a/os/hal/platforms/LPC214x/spi_lld.h +++ b/os/hal/platforms/LPC214x/spi_lld.h @@ -135,12 +135,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/LPC8xx/hal_lld.c b/os/hal/platforms/LPC8xx/hal_lld.c index e5170fcc4..026205706 100644 --- a/os/hal/platforms/LPC8xx/hal_lld.c +++ b/os/hal/platforms/LPC8xx/hal_lld.c @@ -54,7 +54,7 @@ void hal_lld_init(void) { /* SysTick initialization using the system clock.*/ nvicSetSystemHandlerPriority(HANDLER_SYSTICK, CORTEX_PRIORITY_SYSTICK); - SysTick->LOAD = LPC8xx_SYSCLK / CH_FREQUENCY - 1; + SysTick->LOAD = LPC8xx_SYSCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/LPC8xx/spi_lld.h b/os/hal/platforms/LPC8xx/spi_lld.h index 4acd52547..f4e6192fc 100644 --- a/os/hal/platforms/LPC8xx/spi_lld.h +++ b/os/hal/platforms/LPC8xx/spi_lld.h @@ -209,12 +209,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/Posix/hal_lld.c b/os/hal/platforms/Posix/hal_lld.c index fb1bed779..ae9a6574c 100644 --- a/os/hal/platforms/Posix/hal_lld.c +++ b/os/hal/platforms/Posix/hal_lld.c @@ -38,7 +38,7 @@ /*===========================================================================*/ static struct timeval nextcnt; -static struct timeval tick = {0, 1000000 / CH_FREQUENCY}; +static struct timeval tick = {0, 1000000 / CH_CFG_FREQUENCY}; /*===========================================================================*/ /* Driver local functions. */ diff --git a/os/hal/platforms/SPC560BCxx/hal_lld.c b/os/hal/platforms/SPC560BCxx/hal_lld.c index 5d14daf27..e0d22bfa5 100644 --- a/os/hal/platforms/SPC560BCxx/hal_lld.c +++ b/os/hal/platforms/SPC560BCxx/hal_lld.c @@ -90,7 +90,7 @@ void hal_lld_init(void) { INTC.PSR[59].R = SPC5_PIT0_IRQ_PRIORITY; halSPCSetPeripheralClockMode(92, SPC5_ME_PCTL_RUN(2) | SPC5_ME_PCTL_LP(2)); - reg = halSPCGetSystemClock() / CH_FREQUENCY - 1; + reg = halSPCGetSystemClock() / CH_CFG_FREQUENCY - 1; PIT.PITMCR.R = 1; /* PIT clock enabled, stop while debugging. */ PIT.CH[0].LDVAL.R = reg; PIT.CH[0].CVAL.R = reg; diff --git a/os/hal/platforms/SPC560Dxx/hal_lld.c b/os/hal/platforms/SPC560Dxx/hal_lld.c index 229051979..4ecdc2b4a 100644 --- a/os/hal/platforms/SPC560Dxx/hal_lld.c +++ b/os/hal/platforms/SPC560Dxx/hal_lld.c @@ -90,7 +90,7 @@ void hal_lld_init(void) { INTC.PSR[59].R = SPC5_PIT0_IRQ_PRIORITY; halSPCSetPeripheralClockMode(92, SPC5_ME_PCTL_RUN(2) | SPC5_ME_PCTL_LP(2)); - reg = halSPCGetSystemClock() / CH_FREQUENCY - 1; + reg = halSPCGetSystemClock() / CH_CFG_FREQUENCY - 1; PIT.PITMCR.R = 1; /* PIT clock enabled, stop while debugging. */ PIT.CH[0].LDVAL.R = reg; PIT.CH[0].CVAL.R = reg; diff --git a/os/hal/platforms/SPC560Pxx/hal_lld.c b/os/hal/platforms/SPC560Pxx/hal_lld.c index 799908d46..38519095b 100644 --- a/os/hal/platforms/SPC560Pxx/hal_lld.c +++ b/os/hal/platforms/SPC560Pxx/hal_lld.c @@ -90,7 +90,7 @@ void hal_lld_init(void) { INTC.PSR[59].R = SPC5_PIT0_IRQ_PRIORITY; halSPCSetPeripheralClockMode(92, SPC5_ME_PCTL_RUN(2) | SPC5_ME_PCTL_LP(2)); - reg = halSPCGetSystemClock() / CH_FREQUENCY - 1; + reg = halSPCGetSystemClock() / CH_CFG_FREQUENCY - 1; PIT.PITMCR.R = 1; /* PIT clock enabled, stop while debugging. */ PIT.CH[0].LDVAL.R = reg; PIT.CH[0].CVAL.R = reg; diff --git a/os/hal/platforms/SPC563Mxx/hal_lld.c b/os/hal/platforms/SPC563Mxx/hal_lld.c index 22979e61b..105193b87 100644 --- a/os/hal/platforms/SPC563Mxx/hal_lld.c +++ b/os/hal/platforms/SPC563Mxx/hal_lld.c @@ -77,7 +77,7 @@ void hal_lld_init(void) { /* Downcounter timer initialized for system tick use, TB enabled for debug and measurements.*/ - n = SPC5_SYSCLK / CH_FREQUENCY; + n = SPC5_SYSCLK / CH_CFG_FREQUENCY; asm volatile ("li %%r3, 0 \t\n" "mtspr 284, %%r3 \t\n" /* Clear TBL register. */ "mtspr 285, %%r3 \t\n" /* Clear TBU register. */ diff --git a/os/hal/platforms/SPC564Axx/hal_lld.c b/os/hal/platforms/SPC564Axx/hal_lld.c index f6b220c85..55d8331db 100644 --- a/os/hal/platforms/SPC564Axx/hal_lld.c +++ b/os/hal/platforms/SPC564Axx/hal_lld.c @@ -89,7 +89,7 @@ void hal_lld_init(void) { /* Decrementer timer initialized for system tick use, note, it is initialized here because in the OSAL layer the system clock frequency is not yet known.*/ - n = SPC5_SYSCLK / CH_FREQUENCY; + n = SPC5_SYSCLK / CH_CFG_FREQUENCY; asm volatile ("mtspr 22, %[n] \t\n" /* Init. DEC register. */ "mtspr 54, %[n] \t\n" /* Init. DECAR register.*/ "lis %%r3, 0x0440 \t\n" /* DIE ARE bits. */ diff --git a/os/hal/platforms/SPC56ELxx/hal_lld.c b/os/hal/platforms/SPC56ELxx/hal_lld.c index 4a3976f50..6fec560bd 100644 --- a/os/hal/platforms/SPC56ELxx/hal_lld.c +++ b/os/hal/platforms/SPC56ELxx/hal_lld.c @@ -62,7 +62,7 @@ void hal_lld_init(void) { /* Decrementer timer initialized for system tick use, note, it is initialized here because in the OSAL layer the system clock frequency is not yet known.*/ - n = halSPCGetSystemClock() / CH_FREQUENCY; + n = halSPCGetSystemClock() / CH_CFG_FREQUENCY; asm volatile ("mtspr 22, %[n] \t\n" /* Init. DEC register. */ "mtspr 54, %[n] \t\n" /* Init. DECAR register.*/ "lis %%r3, 0x0440 \t\n" /* DIE ARE bits. */ diff --git a/os/hal/platforms/SPC5xx/DSPI_v1/spi_lld.h b/os/hal/platforms/SPC5xx/DSPI_v1/spi_lld.h index b79e13a8e..1e2e9fd1c 100644 --- a/os/hal/platforms/SPC5xx/DSPI_v1/spi_lld.h +++ b/os/hal/platforms/SPC5xx/DSPI_v1/spi_lld.h @@ -438,12 +438,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/SPC5xx/EQADC_v1/adc_lld.h b/os/hal/platforms/SPC5xx/EQADC_v1/adc_lld.h index 6be4ca5d4..f8713c9e8 100644 --- a/os/hal/platforms/SPC5xx/EQADC_v1/adc_lld.h +++ b/os/hal/platforms/SPC5xx/EQADC_v1/adc_lld.h @@ -585,12 +585,12 @@ struct ADCDriver { Thread *thread; #endif #if ADC_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the peripheral. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* ADC_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32/I2Cv1/i2c_lld.h b/os/hal/platforms/STM32/I2Cv1/i2c_lld.h index dcadb3278..1701a6e24 100644 --- a/os/hal/platforms/STM32/I2Cv1/i2c_lld.h +++ b/os/hal/platforms/STM32/I2Cv1/i2c_lld.h @@ -365,12 +365,12 @@ struct I2CDriver { */ i2cflags_t errors; #if I2C_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* I2C_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32/I2Cv2/i2c_lld.h b/os/hal/platforms/STM32/I2Cv2/i2c_lld.h index 810c7be84..a26665278 100644 --- a/os/hal/platforms/STM32/I2Cv2/i2c_lld.h +++ b/os/hal/platforms/STM32/I2Cv2/i2c_lld.h @@ -243,12 +243,12 @@ struct I2CDriver{ */ i2cflags_t errors; #if I2C_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* I2C_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32/SPIv1/spi_lld.h b/os/hal/platforms/STM32/SPIv1/spi_lld.h index fe37c8f66..bc940f2cd 100644 --- a/os/hal/platforms/STM32/SPIv1/spi_lld.h +++ b/os/hal/platforms/STM32/SPIv1/spi_lld.h @@ -331,12 +331,12 @@ struct SPIDriver{ Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32/SPIv2/spi_lld.h b/os/hal/platforms/STM32/SPIv2/spi_lld.h index f4cc67da5..cc1676f00 100644 --- a/os/hal/platforms/STM32/SPIv2/spi_lld.h +++ b/os/hal/platforms/STM32/SPIv2/spi_lld.h @@ -344,12 +344,12 @@ struct SPIDriver{ Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32F0xx/adc_lld.h b/os/hal/platforms/STM32F0xx/adc_lld.h index 411e31581..0f432f3c7 100644 --- a/os/hal/platforms/STM32F0xx/adc_lld.h +++ b/os/hal/platforms/STM32F0xx/adc_lld.h @@ -267,12 +267,12 @@ struct ADCDriver { Thread *thread; #endif #if ADC_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the peripheral. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* ADC_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32F0xx/hal_lld.c b/os/hal/platforms/STM32F0xx/hal_lld.c index debc51ea3..b67156f10 100644 --- a/os/hal/platforms/STM32F0xx/hal_lld.c +++ b/os/hal/platforms/STM32F0xx/hal_lld.c @@ -104,7 +104,7 @@ void hal_lld_init(void) { rccResetAPB2(~RCC_APB2RSTR_DBGMCURST); /* SysTick initialization using the system clock.*/ - SysTick->LOAD = STM32_HCLK / CH_FREQUENCY - 1; + SysTick->LOAD = STM32_HCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/STM32F1xx/adc_lld.h b/os/hal/platforms/STM32F1xx/adc_lld.h index a4966d99d..9903f7dda 100644 --- a/os/hal/platforms/STM32F1xx/adc_lld.h +++ b/os/hal/platforms/STM32F1xx/adc_lld.h @@ -279,12 +279,12 @@ struct ADCDriver { Thread *thread; #endif #if ADC_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the peripheral. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* ADC_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32F1xx/hal_lld.c b/os/hal/platforms/STM32F1xx/hal_lld.c index eb87a1a84..1fee67cd3 100644 --- a/os/hal/platforms/STM32F1xx/hal_lld.c +++ b/os/hal/platforms/STM32F1xx/hal_lld.c @@ -103,7 +103,7 @@ void hal_lld_init(void) { rccResetAPB2(0xFFFFFFFF); /* SysTick initialization using the system clock.*/ - SysTick->LOAD = STM32_HCLK / CH_FREQUENCY - 1; + SysTick->LOAD = STM32_HCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/STM32F30x/adc_lld.h b/os/hal/platforms/STM32F30x/adc_lld.h index 85dd429f1..c4e0cb272 100644 --- a/os/hal/platforms/STM32F30x/adc_lld.h +++ b/os/hal/platforms/STM32F30x/adc_lld.h @@ -478,12 +478,12 @@ struct ADCDriver { Thread *thread; #endif #if ADC_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the peripheral. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* ADC_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32F30x/hal_lld.c b/os/hal/platforms/STM32F30x/hal_lld.c index 5c1d1efb1..64b691ade 100644 --- a/os/hal/platforms/STM32F30x/hal_lld.c +++ b/os/hal/platforms/STM32F30x/hal_lld.c @@ -104,7 +104,7 @@ void hal_lld_init(void) { rccResetAPB2(0xFFFFFFFF); /* SysTick initialization using the system clock.*/ - SysTick->LOAD = STM32_HCLK / CH_FREQUENCY - 1; + SysTick->LOAD = STM32_HCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/STM32F37x/adc_lld.h b/os/hal/platforms/STM32F37x/adc_lld.h index 2258952b1..302c65462 100644 --- a/os/hal/platforms/STM32F37x/adc_lld.h +++ b/os/hal/platforms/STM32F37x/adc_lld.h @@ -524,12 +524,12 @@ struct ADCDriver { Thread *thread; #endif #if ADC_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the peripheral. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* ADC_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32F37x/hal_lld.c b/os/hal/platforms/STM32F37x/hal_lld.c index a47ab59fc..c40c9e0e1 100644 --- a/os/hal/platforms/STM32F37x/hal_lld.c +++ b/os/hal/platforms/STM32F37x/hal_lld.c @@ -104,7 +104,7 @@ void hal_lld_init(void) { rccResetAPB2(0xFFFFFFFF); /* SysTick initialization using the system clock.*/ - SysTick->LOAD = STM32_HCLK / CH_FREQUENCY - 1; + SysTick->LOAD = STM32_HCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/STM32F4xx/adc_lld.h b/os/hal/platforms/STM32F4xx/adc_lld.h index 7cda791ac..cc173b42d 100644 --- a/os/hal/platforms/STM32F4xx/adc_lld.h +++ b/os/hal/platforms/STM32F4xx/adc_lld.h @@ -440,12 +440,12 @@ struct ADCDriver { Thread *thread; #endif #if ADC_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the peripheral. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* ADC_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32F4xx/hal_lld.c b/os/hal/platforms/STM32F4xx/hal_lld.c index f72812da9..cfffbb3da 100644 --- a/os/hal/platforms/STM32F4xx/hal_lld.c +++ b/os/hal/platforms/STM32F4xx/hal_lld.c @@ -102,7 +102,7 @@ void hal_lld_init(void) { rccResetAPB2(~0); /* SysTick initialization using the system clock.*/ - SysTick->LOAD = STM32_HCLK / CH_FREQUENCY - 1; + SysTick->LOAD = STM32_HCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/STM32L1xx/adc_lld.h b/os/hal/platforms/STM32L1xx/adc_lld.h index 2ac857c16..0f7864c37 100644 --- a/os/hal/platforms/STM32L1xx/adc_lld.h +++ b/os/hal/platforms/STM32L1xx/adc_lld.h @@ -346,12 +346,12 @@ struct ADCDriver { Thread *thread; #endif #if ADC_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the peripheral. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* ADC_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/STM32L1xx/hal_lld.c b/os/hal/platforms/STM32L1xx/hal_lld.c index 529099e6a..c1c61bbcd 100644 --- a/os/hal/platforms/STM32L1xx/hal_lld.c +++ b/os/hal/platforms/STM32L1xx/hal_lld.c @@ -99,7 +99,7 @@ void hal_lld_init(void) { rccResetAPB2(~0); /* SysTick initialization using the system clock.*/ - SysTick->LOAD = STM32_HCLK / CH_FREQUENCY - 1; + SysTick->LOAD = STM32_HCLK / CH_CFG_FREQUENCY - 1; SysTick->VAL = 0; SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk | diff --git a/os/hal/platforms/STM8S/spi_lld.h b/os/hal/platforms/STM8S/spi_lld.h index 8b87b81fc..443be68e4 100644 --- a/os/hal/platforms/STM8S/spi_lld.h +++ b/os/hal/platforms/STM8S/spi_lld.h @@ -119,12 +119,12 @@ struct SPIDriver { Thread *thread; #endif /* SPI_USE_WAIT */ #if SPI_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__) -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @brief Mutex protecting the bus. */ Mutex mutex; -#elif CH_USE_SEMAPHORES +#elif CH_CFG_USE_SEMAPHORES Semaphore semaphore; #endif #endif /* SPI_USE_MUTUAL_EXCLUSION */ diff --git a/os/hal/platforms/Win32/hal_lld.c b/os/hal/platforms/Win32/hal_lld.c index c86e84de7..c494bc96c 100644 --- a/os/hal/platforms/Win32/hal_lld.c +++ b/os/hal/platforms/Win32/hal_lld.c @@ -64,7 +64,7 @@ void hal_lld_init(void) { printf("QueryPerformanceFrequency() error"); exit(1); } - slice.QuadPart /= CH_FREQUENCY; + slice.QuadPart /= CH_CFG_FREQUENCY; QueryPerformanceCounter(&nextcnt); nextcnt.QuadPart += slice.QuadPart; -- cgit v1.2.3