Skip to content

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Patch for stlink issue 65
From 7341a316c38a61cc745ce04e618916677007883b Mon Sep 17 00:00:00 2001
From: Timothy Brom <thb@timbrom.com>
Date: Wed, 29 Feb 2012 11:29:55 -0500
Subject: [PATCH] Fixed error about strexh and strexb using the same register
---
example/libs_stm/inc/core_support/core_cm3.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/example/libs_stm/inc/core_support/core_cm3.c b/example/libs_stm/inc/core_support/core_cm3.c
index 56fddc5..0e8c3c4 100644
--- a/example/libs_stm/inc/core_support/core_cm3.c
+++ b/example/libs_stm/inc/core_support/core_cm3.c
@@ -733,7 +733,7 @@ uint32_t __STREXB(uint8_t value, uint8_t *addr)
{
uint32_t result=0;
- __ASM volatile ("strexb %0, %2, [%1]" : "=r" (result) : "r" (addr), "r" (value) );
+ __ASM volatile ("strexb %0, %2, [%1]" : "=&r" (result) : "r" (addr), "r" (value) );
return(result);
}
@@ -750,7 +750,7 @@ uint32_t __STREXH(uint16_t value, uint16_t *addr)
{
uint32_t result=0;
- __ASM volatile ("strexh %0, %2, [%1]" : "=r" (result) : "r" (addr), "r" (value) );
+ __ASM volatile ("strexh %0, %2, [%1]" : "=&r" (result) : "r" (addr), "r" (value) );
return(result);
}
--
1.7.5.4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.