All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] bluez5: Add role parameter to bt_register_profile
@ 2013-02-25 20:36 Paulo Borges
  2013-02-25 20:36 ` [PATCH 2/3] hfp_hf_bluez5: Change register profile call Paulo Borges
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Paulo Borges @ 2013-02-25 20:36 UTC (permalink / raw)
  To: ofono

[-- Attachment #1: Type: text/plain, Size: 1556 bytes --]

This commit allows asymmetric profiles that do not have UUIDs
available to uniquely identify which role is been registered.
---
 plugins/bluez5.c |    5 ++++-
 plugins/bluez5.h |    2 +-
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/plugins/bluez5.c b/plugins/bluez5.c
index 788f3a2..04dd39d 100644
--- a/plugins/bluez5.c
+++ b/plugins/bluez5.c
@@ -110,7 +110,7 @@ done:
 
 int bt_register_profile(DBusConnection *conn, const char *uuid,
 					uint16_t version, const char *name,
-					const char *object)
+					const char *object, const char* role)
 {
 	DBusMessageIter iter, dict;
 	DBusPendingCall *c;
@@ -129,6 +129,9 @@ int bt_register_profile(DBusConnection *conn, const char *uuid,
 	ofono_dbus_dict_append(&dict, "Name", DBUS_TYPE_STRING, &name);
 	ofono_dbus_dict_append(&dict, "Version", DBUS_TYPE_UINT16, &version);
 
+	if (role)
+		ofono_dbus_dict_append(&dict, "Role", DBUS_TYPE_STRING, &role);
+
 	dbus_message_iter_close_container(&iter, &dict);
 
 	if (!dbus_connection_send_with_reply(conn, msg, &c, -1)) {
diff --git a/plugins/bluez5.h b/plugins/bluez5.h
index 1432068..17e925f 100644
--- a/plugins/bluez5.h
+++ b/plugins/bluez5.h
@@ -71,7 +71,7 @@ int bt_bacmp(const bdaddr_t *ba1, const bdaddr_t *ba2);
 
 int bt_register_profile(DBusConnection *conn, const char *uuid,
 					uint16_t version, const char *name,
-					const char *object);
+					const char *object, const char *role);
 
 void bt_unregister_profile(DBusConnection *conn, const char *object);
 
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2013-03-01 20:02 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-25 20:36 [PATCH 1/3] bluez5: Add role parameter to bt_register_profile Paulo Borges
2013-02-25 20:36 ` [PATCH 2/3] hfp_hf_bluez5: Change register profile call Paulo Borges
2013-02-25 20:36 ` [PATCH 3/3] hfp_ag_bluez5: " Paulo Borges
2013-02-27 21:48 ` [PATCH 1/3] bluez5: Add role parameter to bt_register_profile Paulo Borges
2013-02-27 21:54 ` [PATCH v2] " Paulo Borges
2013-03-01 19:42   ` Denis Kenzior
2013-03-01 20:02     ` Paulo Borges

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.