aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/db/db-5.1.19/arm-thumb-mutex_db5.patch
diff options
context:
space:
mode:
authorTom Rini <tom_rini@mentor.com>2011-02-16 14:18:53 -0700
committerTom Rini <tom_rini@mentor.com>2011-02-17 09:52:31 -0700
commit87a92185e87fa62f4595db6e125ef100368772a7 (patch)
tree749e2d7cfc105a41429031d5f48675da752e082e /recipes/db/db-5.1.19/arm-thumb-mutex_db5.patch
parent1cf4010dfc6703516353b275fed6e6a452f9161b (diff)
downloadopenembedded-87a92185e87fa62f4595db6e125ef100368772a7.tar.gz
db: Bring in 5.1.19 from poky
Based on e77207ccdf15f34651a086099ed4816712e3656b in poky, bring in 5.1.19 (no RPATH issues when using libtool 2.2) and drop un-pinned 4.3.29 and 5.0.21 as this is backwards compatible. Acked-by: Marco Cavallini <m.cavallini@koansoftware.com> Signed-off-by: Tom Rini <tom_rini@mentor.com>
Diffstat (limited to 'recipes/db/db-5.1.19/arm-thumb-mutex_db5.patch')
-rw-r--r--recipes/db/db-5.1.19/arm-thumb-mutex_db5.patch36
1 files changed, 36 insertions, 0 deletions
diff --git a/recipes/db/db-5.1.19/arm-thumb-mutex_db5.patch b/recipes/db/db-5.1.19/arm-thumb-mutex_db5.patch
new file mode 100644
index 0000000000..37d0d93abd
--- /dev/null
+++ b/recipes/db/db-5.1.19/arm-thumb-mutex_db5.patch
@@ -0,0 +1,36 @@
+--- db-5.1.19/../src/dbinc/mutex_int.h.orig 2011-01-05 19:21:42.181805366 -0600
++++ db-5.1.19/../src/dbinc/mutex_int.h 2011-01-05 19:24:53.141853117 -0600
+@@ -474,6 +474,25 @@
+
+ #ifdef LOAD_ACTUAL_MUTEX_CODE
+ /* gcc/arm: 0 is clear, 1 is set. */
++#if defined __thumb__
++#define MUTEX_SET(tsl) ({ \
++ int __r, __p; \
++ __asm__ volatile( \
++ ".align 2\n\t" \
++ "bx pc\n\t" \
++ "nop\n\t" \
++ ".arm\n\t" \
++ "swpb %0, %2, [%3]\n\t" \
++ "eor %0, %0, #1\n\t" \
++ "orr %1, pc, #1\n\t" \
++ "bx %1\n\t" \
++ ".force_thumb" \
++ : "=&r" (__r), "=r" (__p) \
++ : "r" (1), "r" (tsl) \
++ ); \
++ __r & 1; \
++})
++#else
+ #define MUTEX_SET(tsl) ({ \
+ int __r; \
+ __asm__ volatile( \
+@@ -484,6 +503,7 @@
+ ); \
+ __r & 1; \
+ })
++#endif
+
+ #define MUTEX_UNSET(tsl) (*(volatile tsl_t *)(tsl) = 0)
+ #define MUTEX_INIT(tsl) (MUTEX_UNSET(tsl), 0)