diff --git a/include/bluetooth/bluetooth.h b/include/bluetooth/bluetooth.h index b4311f613d4..98c5fe65302 100644 --- a/include/bluetooth/bluetooth.h +++ b/include/bluetooth/bluetooth.h @@ -322,6 +322,7 @@ struct bt_le_adv_param { */ #define BT_LE_ADV_PARAM(_options, _int_min, _int_max) \ ((struct bt_le_adv_param[]) { { \ + .id = BT_ID_DEFAULT, \ .options = (_options), \ .interval_min = (_int_min), \ .interval_max = (_int_max), \ diff --git a/include/bluetooth/gatt.h b/include/bluetooth/gatt.h index b05ff532d62..2acee2adbfe 100644 --- a/include/bluetooth/gatt.h +++ b/include/bluetooth/gatt.h @@ -817,10 +817,11 @@ ssize_t bt_gatt_attr_read_cpf(struct bt_conn *conn, #define BT_GATT_ATTRIBUTE(_uuid, _perm, _read, _write, _value) \ { \ .uuid = _uuid, \ - .perm = _perm, \ .read = _read, \ .write = _write, \ .user_data = _value, \ + .handle = 0, \ + .perm = _perm, \ } /** @brief Notification complete result callback.