diff --git a/os/hal/platforms/LPC11xx/pal_lld.h b/os/hal/platforms/LPC11xx/pal_lld.h index d1a711868..f1f223b3b 100644 --- a/os/hal/platforms/LPC11xx/pal_lld.h +++ b/os/hal/platforms/LPC11xx/pal_lld.h @@ -268,7 +268,7 @@ typedef LPC_GPIO_TypeDef *ioportid_t; * @notapi */ #define pal_lld_writepad(port, pad, bit) \ - ((port)->MASKED_ACCESS[(mask) << (pad)] = (bit) << (pad)) + ((port)->MASKED_ACCESS[1 << (pad)] = (bit) << (pad)) /** * @brief Sets a pad logical state to @p PAL_HIGH. diff --git a/os/hal/platforms/LPC13xx/pal_lld.h b/os/hal/platforms/LPC13xx/pal_lld.h index 3b64a0c38..7ddd604d8 100644 --- a/os/hal/platforms/LPC13xx/pal_lld.h +++ b/os/hal/platforms/LPC13xx/pal_lld.h @@ -268,7 +268,7 @@ typedef LPC_GPIO_TypeDef *ioportid_t; * @notapi */ #define pal_lld_writepad(port, pad, bit) \ - ((port)->MASKED_ACCESS[(mask) << (pad)] = (bit) << (pad)) + ((port)->MASKED_ACCESS[1 << (pad)] = (bit) << (pad)) /** * @brief Sets a pad logical state to @p PAL_HIGH. diff --git a/readme.txt b/readme.txt index 507be741f..9d1020c99 100644 --- a/readme.txt +++ b/readme.txt @@ -82,6 +82,8 @@ ***************************************************************************** *** 2.5.1 *** +- FIX: Fixed error in palWritePad() macro (bug 3586230)(backported to 2.2.10 + and 2.4.3). - FIX: Fixed missing ; in testmbox.c (bug 3585979)(backported to 2.4.3). - FIX: Fixed STM32F4xx: Wrong CAN1 SCE interrupt number definition (bug 3581571).