summaryrefslogtreecommitdiffstats
path: root/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch
diff options
context:
space:
mode:
authorPatrick Williams <patrick@stwcx.xyz>2015-09-15 14:41:29 -0500
committerPatrick Williams <patrick@stwcx.xyz>2015-09-15 14:41:29 -0500
commit21f9b84b4b729fbd7acbd465e7a3f726e4d20f91 (patch)
treeeb2d091d427ca0813b445509d59cc8e27e8ad25f /yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch
parent101cef31e2bf54c678501155cd2106251acbd076 (diff)
parentc124f4f2e04dca16a428a76c89677328bc7bf908 (diff)
downloadblackbird-openbmc-21f9b84b4b729fbd7acbd465e7a3f726e4d20f91.tar.gz
blackbird-openbmc-21f9b84b4b729fbd7acbd465e7a3f726e4d20f91.zip
Merge commit 'c124f4f2e04dca16a428a76c89677328bc7bf908' as 'yocto-poky'
Diffstat (limited to 'yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch')
-rw-r--r--yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch64
1 files changed, 64 insertions, 0 deletions
diff --git a/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch
new file mode 100644
index 000000000..2d36158f5
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch
@@ -0,0 +1,64 @@
+From b856ff35c20124ceae40bbc4d32584df47618c96 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 25 Feb 2015 09:28:26 +0000
+Subject: [PATCH] hashtable: Remove duplicate hashtable_iterator_value/hashtable_iterator_key
+
+gcc5 is defaulting to gnu11 instead of gnu89 like previous versions
+as a result the semantics of 'extern inline' changes where in gnu89 for 'extern inline' no external
+visible function is generated,in c99 'external inline' generates externally visible function
+there is no equivalent in c99+ because redefinitions arent allowed
+but 'static inline' remains same for for c89 and c99+, thats why we change the semantics
+so we make the functions static inline, and achieve the same effect
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: pending
+
+---
+ mkfs.ubifs/hashtable/hashtable_itr.c | 12 ------------
+ 1 file changed, 12 deletions(-)
+
+Index: git/mkfs.ubifs/hashtable/hashtable_itr.h
+===================================================================
+--- git.orig/mkfs.ubifs/hashtable/hashtable_itr.h
++++ git/mkfs.ubifs/hashtable/hashtable_itr.h
+@@ -28,7 +28,7 @@ hashtable_iterator(struct hashtable *h);
+ /* hashtable_iterator_key
+ * - return the value of the (key,value) pair at the current position */
+
+-extern inline void *
++static inline void *
+ hashtable_iterator_key(struct hashtable_itr *i)
+ {
+ return i->e->k;
+@@ -37,7 +37,7 @@ hashtable_iterator_key(struct hashtable_
+ /*****************************************************************************/
+ /* value - return the value of the (key,value) pair at the current position */
+
+-extern inline void *
++static inline void *
+ hashtable_iterator_value(struct hashtable_itr *i)
+ {
+ return i->e->v;
+Index: git/mkfs.ubifs/hashtable/hashtable_itr.c
+===================================================================
+--- git.orig/mkfs.ubifs/hashtable/hashtable_itr.c
++++ git/mkfs.ubifs/hashtable/hashtable_itr.c
+@@ -35,18 +35,6 @@ hashtable_iterator(struct hashtable *h)
+ }
+
+ /*****************************************************************************/
+-/* key - return the key of the (key,value) pair at the current position */
+-/* value - return the value of the (key,value) pair at the current position */
+-
+-void *
+-hashtable_iterator_key(struct hashtable_itr *i)
+-{ return i->e->k; }
+-
+-void *
+-hashtable_iterator_value(struct hashtable_itr *i)
+-{ return i->e->v; }
+-
+-/*****************************************************************************/
+ /* advance - advance the iterator to the next element
+ * returns zero if advanced to end of table */
+
OpenPOWER on IntegriCloud