diff --git a/nimble/host/src/ble_gap.c b/nimble/host/src/ble_gap.c index 1fea884aa..645bc21e5 100644 --- a/nimble/host/src/ble_gap.c +++ b/nimble/host/src/ble_gap.c @@ -2304,6 +2304,9 @@ void ble_gap_rx_subrate_change(const struct ble_hci_ev_le_subev_subrate_change *ev) { struct ble_gap_event event; + uint16_t conn_handle; + + conn_handle = le16toh(ev->conn_handle); memset(&event, 0x0, sizeof event); @@ -2316,6 +2319,7 @@ ble_gap_rx_subrate_change(const struct ble_hci_ev_le_subev_subrate_change *ev) event.subrate_change.supervision_tmo = le16toh(ev->supervision_tmo); ble_gap_event_listener_call(&event); + ble_gap_call_conn_event_cb(&event, conn_handle); } #endif diff --git a/nimble/host/src/ble_hs_startup.c b/nimble/host/src/ble_hs_startup.c index 3f04325be..66a04677f 100644 --- a/nimble/host/src/ble_hs_startup.c +++ b/nimble/host/src/ble_hs_startup.c @@ -267,6 +267,7 @@ ble_hs_startup_le_set_evmask_tx(void) * 0x0000000400000000 LE Subrate change event */ mask |= 0x0000000400000000; + } #endif #if MYNEWT_VAL(BLE_POWER_CONTROL) diff --git a/nimble/include/nimble/hci_common.h b/nimble/include/nimble/hci_common.h index f005796c4..7a271d67c 100644 --- a/nimble/include/nimble/hci_common.h +++ b/nimble/include/nimble/hci_common.h @@ -1232,6 +1232,7 @@ struct ble_hci_le_subrate_req_cp { uint16_t conn_handle; uint16_t subrate_min; uint16_t subrate_max; + uint16_t max_latency; uint16_t cont_num; uint16_t supervision_tmo; } __attribute__((packed));