Linux bluetooth development
 help / color / mirror / Atom feed
* [PATCH] gatt-server: Fix mutlpile definition of same func
@ 2015-02-06 12:47 Gowtham Anandha Babu
  2015-02-13 11:20 ` Gowtham Anandha Babu
  2015-02-13 11:33 ` Johan Hedberg
  0 siblings, 2 replies; 6+ messages in thread
From: Gowtham Anandha Babu @ 2015-02-06 12:47 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: bharat.panda, cpgs, Gowtham Anandha Babu

Removed 'put_uuid_le' func from gatt-server,
which was already defined in gatt-helpers.
---
 src/shared/gatt-helpers.c |  2 +-
 src/shared/gatt-helpers.h |  2 ++
 src/shared/gatt-server.c  | 21 ---------------------
 3 files changed, 3 insertions(+), 22 deletions(-)

diff --git a/src/shared/gatt-helpers.c b/src/shared/gatt-helpers.c
index a33f960..6dfc24f 100644
--- a/src/shared/gatt-helpers.c
+++ b/src/shared/gatt-helpers.c
@@ -567,7 +567,7 @@ bool bt_gatt_exchange_mtu(struct bt_att *att, uint16_t client_rx_mtu,
 	return true;
 }
 
-static void put_uuid_le(const bt_uuid_t *src, void *dst)
+void put_uuid_le(const bt_uuid_t *src, void *dst)
 {
 	bt_uuid_t uuid;
 
diff --git a/src/shared/gatt-helpers.h b/src/shared/gatt-helpers.h
index 0217e82..7a2076b 100644
--- a/src/shared/gatt-helpers.h
+++ b/src/shared/gatt-helpers.h
@@ -105,3 +105,5 @@ bool bt_gatt_read_by_type(struct bt_att *att, uint16_t start, uint16_t end,
 					bt_gatt_discovery_callback_t callback,
 					void *user_data,
 					bt_gatt_destroy_func_t destroy);
+
+void put_uuid_le(const bt_uuid_t *src, void *dst);
diff --git a/src/shared/gatt-server.c b/src/shared/gatt-server.c
index 8f7b5cd..0652d3d 100644
--- a/src/shared/gatt-server.c
+++ b/src/shared/gatt-server.c
@@ -499,27 +499,6 @@ error:
 	queue_destroy(q, NULL);
 }
 
-static void put_uuid_le(const bt_uuid_t *src, void *dst)
-{
-	bt_uuid_t uuid;
-
-	switch (src->type) {
-	case BT_UUID16:
-		put_le16(src->value.u16, dst);
-		break;
-	case BT_UUID128:
-		bswap_128(&src->value.u128, dst);
-		break;
-	case BT_UUID32:
-		bt_uuid_to_uuid128(src, &uuid);
-		bswap_128(&uuid.value.u128, dst);
-		break;
-	case BT_UUID_UNSPEC:
-	default:
-		break;
-	}
-}
-
 static bool encode_find_info_rsp(struct gatt_db *db, struct queue *q,
 						uint16_t mtu,
 						uint8_t *pdu, uint16_t *len)
-- 
1.9.1


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

end of thread, other threads:[~2015-02-13 14:25 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-06 12:47 [PATCH] gatt-server: Fix mutlpile definition of same func Gowtham Anandha Babu
2015-02-13 11:20 ` Gowtham Anandha Babu
2015-02-13 12:53   ` Luiz Augusto von Dentz
2015-02-13 11:33 ` Johan Hedberg
2015-02-13 13:49   ` Luiz Augusto von Dentz
2015-02-13 14:25     ` Gowtham Anandha Babu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox