summaryrefslogtreecommitdiffstats
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index 692bdfbd..057634a4 100644
--- a/src/main.c
+++ b/src/main.c
@@ -329,6 +329,7 @@ static void at_child_exit(void)
static void configure_device(int dev_id)
{
struct hci_dev_info di;
+ uint16_t policy;
int dd;
if (hci_devinfo(dev_id, &di) < 0)
@@ -344,6 +345,11 @@ static void configure_device(int dev_id)
return;
}
+ /* Set default link policy */
+ policy = htobs(main_opts.link_policy);
+ hci_send_cmd(dd, OGF_LINK_POLICY,
+ OCF_WRITE_DEFAULT_LINK_POLICY, 2, &policy);
+
/* Set device name */
if ((main_opts.flags & (1 << HCID_SET_NAME)) && main_opts.name) {
change_local_name_cp cp;