[Style] Global style fix run.
This commit is contained in:
parent
67efedec54
commit
a909b5ca9e
@ -161,9 +161,12 @@ static inline bool __cm_atomic_set(bool* val)
|
|||||||
return cm_mask_interrupts(*val);
|
return cm_mask_interrupts(*val);
|
||||||
}
|
}
|
||||||
|
|
||||||
#define __CM_SAVER(state) __val = state, \
|
#define __CM_SAVER(state) \
|
||||||
|
do { \
|
||||||
|
__val = state, \
|
||||||
__save __attribute__((__cleanup__(__cm_atomic_set))) = \
|
__save __attribute__((__cleanup__(__cm_atomic_set))) = \
|
||||||
__cm_atomic_set(&__val)
|
__cm_atomic_set(&__val); \
|
||||||
|
} while (0)
|
||||||
|
|
||||||
#endif /* !defined(__DOXYGEN) */
|
#endif /* !defined(__DOXYGEN) */
|
||||||
|
|
||||||
@ -214,7 +217,9 @@ static inline bool __cm_atomic_set(bool* val)
|
|||||||
#define CM_ATOMIC_BLOCK()
|
#define CM_ATOMIC_BLOCK()
|
||||||
#else /* defined(__DOXYGEN__) */
|
#else /* defined(__DOXYGEN__) */
|
||||||
#define CM_ATOMIC_BLOCK() \
|
#define CM_ATOMIC_BLOCK() \
|
||||||
for (bool ___CM_SAVER(true), __my = true; __my; __my = false)
|
do { \
|
||||||
|
for (bool ___CM_SAVER(true), __my = true; __my; __my = false); \
|
||||||
|
} while (0)
|
||||||
#endif /* defined(__DOXYGEN__) */
|
#endif /* defined(__DOXYGEN__) */
|
||||||
|
|
||||||
/*---------------------------------------------------------------------------*/
|
/*---------------------------------------------------------------------------*/
|
||||||
|
@ -749,5 +749,4 @@ END_DECLS
|
|||||||
|
|
||||||
/**@}*/
|
/**@}*/
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -93,7 +93,8 @@ void rcc_peripheral_reset(volatile uint32_t *reg, uint32_t reset)
|
|||||||
*
|
*
|
||||||
* @param[in] *reg Unsigned int32. Pointer to a Reset Register
|
* @param[in] *reg Unsigned int32. Pointer to a Reset Register
|
||||||
* (either RCC_AHBENR, RCC_APB1ENR or RCC_APB2ENR)
|
* (either RCC_AHBENR, RCC_APB1ENR or RCC_APB2ENR)
|
||||||
* @param[in] clear_reset Unsigned int32. Logical OR of all resets to be removed:
|
* @param[in] clear_reset Unsigned int32. Logical OR of all resets to be
|
||||||
|
* removed:
|
||||||
* @li If register is RCC_AHBRSTR, from @ref rcc_ahbrstr_rst
|
* @li If register is RCC_AHBRSTR, from @ref rcc_ahbrstr_rst
|
||||||
* @li If register is RCC_APB1RSTR, from @ref rcc_apb1rstr_rst
|
* @li If register is RCC_APB1RSTR, from @ref rcc_apb1rstr_rst
|
||||||
* @li If register is RCC_APB2RSTR, from @ref rcc_apb2rstr_rst
|
* @li If register is RCC_APB2RSTR, from @ref rcc_apb2rstr_rst
|
||||||
|
@ -788,7 +788,7 @@ void adc_enable_analog_watchdog_on_all_channels(uint32_t adc)
|
|||||||
|
|
||||||
void adc_enable_analog_watchdog_on_selected_channel(uint32_t adc, uint8_t chan)
|
void adc_enable_analog_watchdog_on_selected_channel(uint32_t adc, uint8_t chan)
|
||||||
{
|
{
|
||||||
ADC_CFGR1(adc) = (ADC_CFGR1(adc) & ~ADC_CFGR1_AWDCH) | \
|
ADC_CFGR1(adc) = (ADC_CFGR1(adc) & ~ADC_CFGR1_AWDCH) |
|
||||||
ADC_CFGR1_AWDCH_VAL(chan);
|
ADC_CFGR1_AWDCH_VAL(chan);
|
||||||
|
|
||||||
ADC_CFGR1(adc) |= ADC_CFGR1_AWDEN | ADC_CFGR1_AWDSGL;
|
ADC_CFGR1(adc) |= ADC_CFGR1_AWDEN | ADC_CFGR1_AWDSGL;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user