diff options
author | Matt Ranostay <matt.ranostay@konsulko.com> | 2017-07-25 22:42:42 -0700 |
---|---|---|
committer | Matt Ranostay <matt.ranostay@konsulko.com> | 2017-08-04 15:30:52 -0700 |
commit | ae84f859b95b5b32524529e2e0a0f8c93a5ad3e0 (patch) | |
tree | 10248bced5dd399dee7c3519600ddbcad5200e6c /binding-bluetooth/bluetooth-manager.h | |
parent | 3587e397424285df38d28b1572ce9118724d5122 (diff) |
binding: bluetooth: listen for rfkill bluetooth events
On certain platforms like RPI3 and Porter there is a possible
race condition to systemd-rfkill service if using a USB BT device,
and this patchset listens for rfkill events, unblocks and brings
up hci interface.
Change-Id: I336e496b589a23767003e186473c4aed49471fba
Bug-AGL: SPEC-569
Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com>
Diffstat (limited to 'binding-bluetooth/bluetooth-manager.h')
-rw-r--r-- | binding-bluetooth/bluetooth-manager.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/binding-bluetooth/bluetooth-manager.h b/binding-bluetooth/bluetooth-manager.h index b11b11d..ed02b28 100644 --- a/binding-bluetooth/bluetooth-manager.h +++ b/binding-bluetooth/bluetooth-manager.h @@ -20,6 +20,7 @@ #include <glib.h> #include <gio/gio.h> #include <glib-object.h> +#include <sys/ioctl.h> /* Debug Trace Level */ #define DT_LEVEL_ERROR (1 << 1) @@ -119,6 +120,12 @@ #define ERROR_BLUEZ_REJECT "org.bluez.Error.Rejected" #define ERROR_BLUEZ_CANCELED "org.bluez.Error.Canceled" + +#define HCIDEVUP _IOW('H', 201, int) + +#define AF_BLUETOOTH 31 +#define BTPROTO_HCI 1 + #if 0 void DebugTraceSendMsg(int level, gchar* message); #else @@ -153,6 +160,7 @@ struct btd_device { typedef struct { gboolean inited; GMutex m; + gint watch; GSList * device; } stBluetoothManage; |