summaryrefslogtreecommitdiffstats
path: root/audio/avdtp.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2008-10-09 15:00:09 +0200
committerJohan Hedberg <johan.hedberg@nokia.com>2008-10-09 15:13:28 +0200
commit17541956196b13ee083852fd4124cd8cfd0928a4 (patch)
treecc258c9f0ff98572036eea7879e79fb443053913 /audio/avdtp.c
parent548026e08bd9b83b3685d515a916e2cf674184f3 (diff)
Add mechanism for adding new UUIDs from the driver side
With this patch drivers can notify the core daemon that a device supports some UUID. This is useful in case we don't have a service record for a profile which the remote device initiates a connection for.
Diffstat (limited to 'audio/avdtp.c')
-rw-r--r--audio/avdtp.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/audio/avdtp.c b/audio/avdtp.c
index 1c6f8e67..affc7fe7 100644
--- a/audio/avdtp.c
+++ b/audio/avdtp.c
@@ -42,7 +42,9 @@
#include "logging.h"
-#include "adapter.h"
+#include "../src/adapter.h"
+#include "../src/device.h"
+
#include "device.h"
#include "manager.h"
#include "control.h"
@@ -1061,7 +1063,7 @@ static gboolean avdtp_setconf_cmd(struct avdtp *session,
}
avdtp_get_peers(session, &src, &dst);
- dev = manager_get_device(&src, &dst, NULL);
+ dev = manager_get_device(&src, &dst);
if (!dev) {
error("Unable to get a audio device object");
goto failed;
@@ -1070,7 +1072,7 @@ static gboolean avdtp_setconf_cmd(struct avdtp *session,
switch (sep->info.type) {
case AVDTP_SEP_TYPE_SOURCE:
if (!dev->sink)
- dev->sink = sink_init(dev);
+ btd_device_add_uuid(dev->btd_dev, A2DP_SINK_UUID);
break;
case AVDTP_SEP_TYPE_SINK:
/* Do source_init() here when it's implemented */
@@ -2804,7 +2806,7 @@ static void avdtp_server_cb(GIOChannel *chan, int err, const bdaddr_t *src,
goto drop;
}
- dev = manager_get_device(src, dst, NULL);
+ dev = manager_get_device(src, dst);
if (!dev) {
error("Unable to get audio device object for %s", address);
goto drop;