aboutsummaryrefslogtreecommitdiff
path: root/lib/stm32/f1
diff options
context:
space:
mode:
authorJeff Ciesielski2012-10-19 16:33:38 -0700
committerJeff Ciesielski2012-10-19 16:33:38 -0700
commit1cb373464cbd43e55fecbebcf9f8120fda36a6d0 (patch)
tree679e42d9c7bcf23a170988aeb72adf943ea16285 /lib/stm32/f1
parent32924fcc159c2e55b589ea7f54402c5ddc89097d (diff)
stm32/f1/gpio: use |= instead of = when setting up registers
Diffstat (limited to 'lib/stm32/f1')
-rw-r--r--lib/stm32/f1/gpio.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/stm32/f1/gpio.c b/lib/stm32/f1/gpio.c
index 0602012..e513d29 100644
--- a/lib/stm32/f1/gpio.c
+++ b/lib/stm32/f1/gpio.c
@@ -292,7 +292,7 @@ value cannot be ascertained from the hardware.
*/
void gpio_primary_remap(u8 swjdisable, u32 maps)
{
- AFIO_MAPR = swjdisable | (maps & 0x1FFFFF);
+ AFIO_MAPR |= swjdisable | (maps & 0x1FFFFF);
}
/*-----------------------------------------------------------------------------*/
@@ -310,7 +310,7 @@ The AFIO remapping feature is used only with the STM32F10x series.
*/
void gpio_secondary_remap(u32 maps)
{
- AFIO_MAPR2 = maps;
+ AFIO_MAPR2 |= maps;
}
/**@}*/