summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@intel.com>2012-09-10 15:38:55 +0300
committerJohan Hedberg <johan.hedberg@intel.com>2012-09-11 11:29:58 +0300
commit96f60e1411514fb4b0d8690aca1c02b3c6b32b9c (patch)
tree26a57e8ae5236125db5485ff6284a6fa5e6ee26a
parentb1cde69a66270076ff5afb86250b29dd4fa53256 (diff)
profile: Add asynchronous completion functions for connect/disconnect
-rw-r--r--src/profile.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/profile.h b/src/profile.h
index 9088c322..a2974624 100644
--- a/src/profile.h
+++ b/src/profile.h
@@ -23,6 +23,10 @@
#define BTD_UUIDS(args...) ((const char *[]) { args, NULL } )
+struct btd_profile;
+
+typedef void (*btd_profile_cb)(struct btd_profile *profile, void *data);
+
struct btd_profile {
const char *name;
@@ -34,8 +38,10 @@ struct btd_profile {
int (*device_probe) (struct btd_device *device, GSList *uuids);
void (*device_remove) (struct btd_device *device);
- void (*connect) (struct btd_device *device);
- void (*disconnect) (struct btd_device *device);
+ void (*connect) (struct btd_device *device, btd_profile_cb cb,
+ void *data);
+ void (*disconnect) (struct btd_device *device, btd_profile_cb cb,
+ void *data);
int (*adapter_probe) (struct btd_adapter *adapter);
void (*adapter_remove) (struct btd_adapter *adapter);