drivers/gpio: stm32: Add semaphore on gpio_configure

Protect gpio_configure function in dual core context.
This operation is not needed for other fuctions of the api:
* init
* read
* write

Protecting gpio_configure also protects access to
interrupt_controller IP.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
This commit is contained in:
Erwan Gouriou 2019-07-01 14:27:08 +02:00 committed by Anas Nashif
commit 0914f1031d
2 changed files with 11 additions and 0 deletions

View file

@ -21,6 +21,8 @@
#define LL_HSEM_ID_0 (0U) /* HW semaphore 0 */
#define LL_HSEM_MASK_0 (1 << LL_HSEM_ID_0)
#define LL_HSEM_ID_1 (1U) /* HW semaphore 1 */
#define LL_HSEM_MASK_1 (1 << LL_HSEM_ID_1)
#include <stm32h7xx_ll_hsem.h>