Lines Matching defs:val
966 if (cp->val == 0x01)
968 else if (cp->val == 0x02)
991 return cp->val;
1341 if (cp->val) {
1353 if (cp->val)
1370 return hci_set_powered_sync(hdev, cp->val);
1382 if (cp->val != 0x00 && cp->val != 0x01)
1394 if (!!cp->val == hdev_is_powered(hdev)) {
1406 if (cp->val == 0x00) {
1561 if (cp->val != 0x00 && cp->val != 0x01 && cp->val != 0x02)
1570 if ((cp->val == 0x00 && timeout > 0) ||
1571 (cp->val == 0x02 && timeout == 0))
1609 if (!!cp->val != hci_dev_test_flag(hdev, HCI_DISCOVERABLE)) {
1628 if (!!cp->val == hci_dev_test_flag(hdev, HCI_DISCOVERABLE) &&
1629 (cp->val == 0x02) == hci_dev_test_flag(hdev,
1634 if (cp->val && hdev->discov_timeout > 0) {
1657 if (cp->val)
1663 if (cp->val == 0x02)
1709 struct sock *sk, u8 val)
1714 if (!!val != hci_dev_test_flag(hdev, HCI_CONNECTABLE))
1717 if (val) {
1758 if (cp->val != 0x00 && cp->val != 0x01)
1765 err = set_connectable_update_settings(hdev, sk, cp->val);
1782 if (cp->val) {
1813 if (cp->val != 0x00 && cp->val != 0x01)
1819 if (cp->val)
1847 u8 val, status;
1857 if (cp->val != 0x00 && cp->val != 0x01)
1866 if (!!cp->val != hci_dev_test_flag(hdev, HCI_LINK_SECURITY)) {
1887 val = !!cp->val;
1889 if (test_bit(HCI_AUTH, &hdev->flags) == val) {
1900 err = hci_send_cmd(hdev, HCI_OP_WRITE_AUTH_ENABLE, sizeof(val), &val);
1916 u8 enable = cp->val;
1960 if (cp->val)
1963 err = hci_write_ssp_mode_sync(hdev, cp->val);
1988 if (cp->val != 0x00 && cp->val != 0x01)
1997 if (cp->val) {
2021 if (!!cp->val == hci_dev_test_flag(hdev, HCI_SSP_ENABLED)) {
2079 u8 val = !!cp->val;
2082 if (!val) {
2094 err = hci_write_le_host_supported_sync(hdev, val, 0);
2435 u8 val, enabled;
2443 if (cp->val != 0x00 && cp->val != 0x01)
2457 if (cp->val == 0x01)
2466 val = !!cp->val;
2469 if (!hdev_is_powered(hdev) || val == enabled) {
2472 if (val != hci_dev_test_flag(hdev, HCI_LE_ENABLED)) {
2477 if (!val && hci_dev_test_flag(hdev, HCI_ADVERTISING)) {
2549 u32 val;
2554 val = get_unaligned_le32(&uuid[12]);
2555 if (val > 0xffff)
2857 key->val)) {
2869 hci_add_link_key(hdev, NULL, &key->addr.bdaddr, key->val,
4165 memcpy(b->val, keys->keys[i].val, sizeof(b->val));
4188 if (cp->val != 0x00 && cp->val != 0x01)
4196 !!cp->val != hci_dev_test_flag(hdev,
4204 if (cp->val)
4523 bool val, changed;
4544 val = !!cp->param[0];
4545 changed = val ? !bt_dbg_get() : bt_dbg_get();
4546 bt_dbg_set(val);
4549 rp.flags = cpu_to_le32(val ? BIT(0) : 0);
4558 exp_feature_changed(hdev, debug_uuid, val, sk);
4568 bool val, changed;
4589 val = !!cp->param[0];
4591 if (val) {
4601 rp.flags = cpu_to_le32(val ? BIT(0) : 0);
4610 exp_feature_changed(hdev, mgmt_mesh_uuid, val, sk);
4620 bool val, changed;
4648 val = !!cp->param[0];
4650 if (val) {
4675 exp_ll_privacy_feature_changed(val, hdev, sk);
4685 bool val, changed;
4708 val = !!cp->param[0];
4709 changed = (val != hci_dev_test_flag(hdev, HCI_QUALITY_REPORT));
4720 err = hdev->set_quality_report(hdev, val);
4722 err = aosp_set_quality_report(hdev, val);
4731 if (val)
4737 bt_dev_dbg(hdev, "quality report enable %d changed %d", val, changed);
4740 rp.flags = cpu_to_le32(val ? BIT(0) : 0);
4747 exp_feature_changed(hdev, quality_report_uuid, val, sk);
4758 bool val, changed;
4780 val = !!cp->param[0];
4781 changed = (val != hci_dev_test_flag(hdev, HCI_OFFLOAD_CODECS_ENABLED));
4790 if (val)
4797 val, changed);
4800 rp.flags = cpu_to_le32(val ? BIT(0) : 0);
4807 exp_feature_changed(hdev, offload_codecs_uuid, val, sk);
4816 bool val, changed;
4838 val = !!cp->param[0];
4839 changed = (val != hci_dev_test_flag(hdev, HCI_LE_SIMULTANEOUS_ROLES));
4848 if (val)
4855 val, changed);
4858 rp.flags = cpu_to_le32(val ? BIT(0) : 0);
4865 exp_feature_changed(hdev, le_simultaneous_roles_uuid, val, sk);
4875 bool val, changed = false;
4896 val = cp->param[0] ? true : false;
4897 if (val)
4906 rp.flags = cpu_to_le32(val ? BIT(0) : 0);
4915 exp_feature_changed(hdev, iso_socket_uuid, val, sk);
6330 u8 val = !!cp->val;
6332 if (cp->val == 0x02)
6339 if (val) {
6365 u8 val, status;
6375 if (cp->val != 0x00 && cp->val != 0x01 && cp->val != 0x02)
6385 val = !!cp->val;
6393 (val == hci_dev_test_flag(hdev, HCI_ADVERTISING) &&
6394 (cp->val == 0x02) == hci_dev_test_flag(hdev, HCI_ADVERTISING_CONNECTABLE)) ||
6401 if (cp->val) {
6404 if (cp->val == 0x02)
6550 if (cp->val)
6567 return hci_write_fast_connectable_sync(hdev, cp->val);
6585 if (cp->val != 0x00 && cp->val != 0x01)
6592 if (!!cp->val == hci_dev_test_flag(hdev, HCI_FAST_CONNECTABLE)) {
6683 if (cp->val != 0x00 && cp->val != 0x01)
6689 if (cp->val == hci_dev_test_flag(hdev, HCI_BREDR_ENABLED)) {
6695 if (!cp->val) {
6713 if (!cp->val) {
6783 switch (cp->val) {
6809 u8 val = !!cp->val;
6811 /* Force write of val */
6814 return hci_write_sc_support_sync(hdev, val);
6822 u8 val;
6838 if (cp->val != 0x00 && cp->val != 0x01 && cp->val != 0x02)
6848 if (cp->val) {
6851 if (cp->val == 0x02)
6871 val = !!cp->val;
6873 if (val == hci_dev_test_flag(hdev, HCI_SC_ENABLED) &&
6874 (cp->val == 0x02) == hci_dev_test_flag(hdev, HCI_SC_ONLY)) {
6907 if (cp->val != 0x00 && cp->val != 0x01 && cp->val != 0x02)
6913 if (cp->val)
6919 if (cp->val == 0x02)
6928 u8 mode = (cp->val == 0x02) ? 0x01 : 0x00;
7070 irk->val)) {
7081 addr_type, irk->val,
7166 key->val)) {
7203 key->val, key->enc_size, key->ediv, key->rand);
9471 memcpy(ev.key.val, key->val, HCI_LINK_KEY_SIZE);
9532 memcpy(ev.key.val, key->val, key->enc_size);
9533 memset(ev.key.val + key->enc_size, 0,
9534 sizeof(ev.key.val) - key->enc_size);
9550 memcpy(ev.irk.val, irk->val, sizeof(irk->val));
9580 memcpy(ev.key.val, csrk->val, sizeof(csrk->val));
9689 if (!cp->val)