Bluetooth: ATT: Handle Find Info response

This adds function handler for Find Info Response PDU which call the
request callback:

< ACL Data TX: Handle 3585 flags 0x00 dlen 9
      ATT: Find Information Request (0x04) len 4
        Handle range: 0x0010-0x0011
> ACL Data RX: Handle 3585 flags 0x02 dlen 14
      ATT: Find Information Response (0x05) len 9
        Format: UUID-16 (0x01)
        Handle: 0x0010
        UUID: Characteristic (0x2803)
        Handle: 0x0011
        UUID: Heart Rate Control Point (0x2a39)

Change-Id: I981e9efe75f6eb032d9468549272c82720cb133d
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
This commit is contained in:
Luiz Augusto von Dentz 2015-07-07 17:21:03 +03:00 committed by Anas Nashif
commit 001d29218a

View file

@ -1193,6 +1193,14 @@ static uint8_t att_error_rsp(struct bt_conn *conn, struct bt_buf *data)
return att_handle_rsp(conn, NULL, 0, err); return att_handle_rsp(conn, NULL, 0, err);
} }
static uint8_t att_handle_find_info_rsp(struct bt_conn *conn,
struct bt_buf *buf)
{
BT_DBG("\n");
return att_handle_rsp(conn, buf->data, buf->len, 0);
}
static uint8_t att_handle_find_type_rsp(struct bt_conn *conn, static uint8_t att_handle_find_type_rsp(struct bt_conn *conn,
struct bt_buf *buf) struct bt_buf *buf)
{ {
@ -1222,6 +1230,8 @@ static const struct {
sizeof(struct bt_att_exchange_mtu_rsp) }, sizeof(struct bt_att_exchange_mtu_rsp) },
{ BT_ATT_OP_FIND_INFO_REQ, att_find_info_req, { BT_ATT_OP_FIND_INFO_REQ, att_find_info_req,
sizeof(struct bt_att_find_info_req) }, sizeof(struct bt_att_find_info_req) },
{ BT_ATT_OP_FIND_INFO_RSP, att_handle_find_info_rsp,
sizeof(struct bt_att_find_info_rsp) },
{ BT_ATT_OP_FIND_TYPE_REQ, att_find_type_req, { BT_ATT_OP_FIND_TYPE_REQ, att_find_type_req,
sizeof(struct bt_att_find_type_req) }, sizeof(struct bt_att_find_type_req) },
{ BT_ATT_OP_FIND_TYPE_RSP, att_handle_find_type_rsp, { BT_ATT_OP_FIND_TYPE_RSP, att_handle_find_type_rsp,