Declare DMA Handler State as volatile
Not doing so causes issues when optimizations are enabled, the flag can change at any time by the DMA interrupt, but the compiler is unaware.
This commit is contained in:
parent
156741e067
commit
218b5100dd
|
@ -116,7 +116,7 @@ typedef struct __DMA_HandleTypeDef
|
||||||
|
|
||||||
HAL_LockTypeDef Lock; /*!< DMA locking object */
|
HAL_LockTypeDef Lock; /*!< DMA locking object */
|
||||||
|
|
||||||
HAL_DMA_StateTypeDef State; /*!< DMA transfer state */
|
__IO HAL_DMA_StateTypeDef State; /*!< DMA transfer state */
|
||||||
|
|
||||||
void *Parent; /*!< Parent object state */
|
void *Parent; /*!< Parent object state */
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue