summaryrefslogtreecommitdiff
path: root/android/hal-hidhost.c
diff options
context:
space:
mode:
authorRavi kumar Veeramally <ravikumar.veeramally@linux.intel.com>2013-10-23 00:41:55 -0700
committerJohan Hedberg <johan.hedberg@intel.com>2013-10-23 10:55:21 +0300
commit3590e6b8e953c8dc309ebc4e06f9fcd9fa3c41a8 (patch)
treefebae14bfe49a19be998c725e958860dd2c41f65 /android/hal-hidhost.c
parent66b6ea20ade8f3ac822c6602951e061e5c3c910f (diff)
downloadbluez-3590e6b8e953c8dc309ebc4e06f9fcd9fa3c41a8.tar.gz
android: Add initial code for hidhost virtual unplug
This adds initial code for hidhost .virtual_unplug interface
Diffstat (limited to 'android/hal-hidhost.c')
-rw-r--r--android/hal-hidhost.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/android/hal-hidhost.c b/android/hal-hidhost.c
index b51fec61f..dd2a88ff5 100644
--- a/android/hal-hidhost.c
+++ b/android/hal-hidhost.c
@@ -69,6 +69,8 @@ static bt_status_t hh_disconnect(bt_bdaddr_t *bd_addr)
static bt_status_t hh_virtual_unplug(bt_bdaddr_t *bd_addr)
{
+ struct hal_msg_cmd_bt_hid_vp cmd;
+
DBG("");
if (!interface_ready())
@@ -77,7 +79,10 @@ static bt_status_t hh_virtual_unplug(bt_bdaddr_t *bd_addr)
if (!bd_addr)
return BT_STATUS_PARM_INVALID;
- return BT_STATUS_UNSUPPORTED;
+ memcpy(cmd.bdaddr, bd_addr, sizeof(cmd.bdaddr));
+
+ return hal_ipc_cmd(HAL_SERVICE_ID_HIDHOST, HAL_MSG_OP_BT_HID_VP,
+ sizeof(cmd), &cmd, 0, NULL, NULL);
}
static bt_status_t hh_set_info(bt_bdaddr_t *bd_addr, bthh_hid_info_t hid_info)