summaryrefslogtreecommitdiff
path: root/emulator/hciemu.c
diff options
context:
space:
mode:
authorTedd Ho-Jeong An <tedd.an@intel.com>2021-10-25 13:31:17 -0700
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>2021-10-25 13:38:35 -0700
commitf669f9bd1a64d7ef28a1cf98d41647200db74e92 (patch)
treef195d5b0c6cb8bcf85de0c25502547260a1d2f0c /emulator/hciemu.c
parent0626b79214ed72806283adfa70163e4a8e97eff5 (diff)
downloadbluez-f669f9bd1a64d7ef28a1cf98d41647200db74e92.tar.gz
emulator: Add support to config the accept and resolve list
This patch adds interfaces to config the accept list and resolve list in the btdev.
Diffstat (limited to 'emulator/hciemu.c')
-rw-r--r--emulator/hciemu.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/emulator/hciemu.c b/emulator/hciemu.c
index 4752c8a4d..1f7af3b93 100644
--- a/emulator/hciemu.c
+++ b/emulator/hciemu.c
@@ -601,6 +601,34 @@ void hciemu_set_central_le_states(struct hciemu *hciemu,
btdev_set_le_states(dev, le_states);
}
+void hciemu_set_central_le_al_len(struct hciemu *hciemu, uint8_t len)
+{
+ struct btdev *dev;
+
+ if (!hciemu || !hciemu->vhci)
+ return;
+
+ dev = vhci_get_btdev(hciemu->vhci);
+ if (!dev)
+ return;
+
+ btdev_set_al_len(dev, len);
+}
+
+void hciemu_set_central_le_rl_len(struct hciemu *hciemu, uint8_t len)
+{
+ struct btdev *dev;
+
+ if (!hciemu || !hciemu->vhci)
+ return;
+
+ dev = vhci_get_btdev(hciemu->vhci);
+ if (!dev)
+ return;
+
+ btdev_set_rl_len(dev, len);
+}
+
bool hciemu_add_central_post_command_hook(struct hciemu *hciemu,
hciemu_command_func_t function, void *user_data)
{