diff --git a/emulator/btdev.c b/emulator/btdev.c
index 76bae5e..cf5c36b 100644
--- a/emulator/btdev.c
+++ b/emulator/btdev.c
return ext_adv_addr(btdev, ext_adv);
}
+void btdev_get_mtu(struct btdev *btdev, uint16_t *acl, uint16_t *sco,
+ uint16_t *iso)
+{
+ if (acl)
+ *acl = btdev->acl_mtu;
+ if (sco)
+ *acl = btdev->sco_mtu;
+ if (iso)
+ *iso = btdev->iso_mtu;
+}
+
void btdev_set_le_states(struct btdev *btdev, const uint8_t *le_states)
{
memcpy(btdev->le_states, le_states, sizeof(btdev->le_states));
diff --git a/emulator/btdev.h b/emulator/btdev.h
index a96c1a3..c7b3b46 100644
--- a/emulator/btdev.h
+++ b/emulator/btdev.h
const uint8_t *btdev_get_adv_addr(struct btdev *btdev, uint8_t handle);
+void btdev_get_mtu(struct btdev *btdev, uint16_t *acl, uint16_t *sco,
+ uint16_t *iso);
+
void btdev_set_le_states(struct btdev *btdev, const uint8_t *le_states);
void btdev_set_al_len(struct btdev *btdev, uint8_t len);
diff --git a/emulator/hciemu.c b/emulator/hciemu.c
index ccc57aa..8529caa 100644
--- a/emulator/hciemu.c
+++ b/emulator/hciemu.c
{
struct hciemu_client *client;
int sv[2];
+ uint16_t mtu;
client = new0(struct hciemu_client, 1);
if (!client)
client->host_source = create_source_bthost(sv[1], client->host);
client->start_source = g_idle_add(start_host, client);
+ btdev_get_mtu(client->dev, &mtu, NULL, NULL);
+ bthost_set_acl_mtu(client->host, mtu);
+
return client;
}