[RFC v2] [PATCH 1/3] Export tdb_hash()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



For now, I simply export tdb_hash() from qdict.h for use by tracing 
framework.
Luiz suggested renaming and exporting it from a location other than 
qdict.h . Would "qemu-common.h" be a better place?


Signed-off-by: Prerna Saxena <prerna@xxxxxxxxxxxxxxxxxx>
---
 qdict.c |    2 +-
 qdict.h |    2 ++
 2 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/qdict.c b/qdict.c
index 175bc17..5261872 100644
--- a/qdict.c
+++ b/qdict.c
@@ -56,7 +56,7 @@ QDict *qobject_to_qdict(const QObject *obj)
  * tdb_hash(): based on the hash agorithm from gdbm, via tdb
  * (from module-init-tools)
  */
-static unsigned int tdb_hash(const char *name)
+unsigned int tdb_hash(const char *name)
 {
     unsigned value;	/* Used to compute the hash value.  */
     unsigned   i;	/* Used to cycle through random values. */
diff --git a/qdict.h b/qdict.h
index 5e5902c..d221c18 100644
--- a/qdict.h
+++ b/qdict.h
@@ -59,4 +59,6 @@ int64_t qdict_get_try_int(const QDict *qdict, const char *key,
                           int64_t err_value);
 const char *qdict_get_try_str(const QDict *qdict, const char *key);
 
+/* Export tdb_hash() for use by trace framework */
+unsigned int tdb_hash(const char *name);
 #endif /* QDICT_H */
-- 
1.6.2.5



-- 
Prerna Saxena

Linux Technology Centre,
IBM Systems and Technology Lab,
Bangalore, India

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux