Bluetooth: BR/EDR: Extend bt_conn_info type

Enables get basic connection info support for non-LE connections.

Change-Id: If295b552567886256cfc1e215bfe3149d2f1f60c
Signed-off-by: Arkadiusz Lichwa <arkadiusz.lichwa@tieto.com>
This commit is contained in:
Arkadiusz Lichwa 2015-12-16 12:32:09 +01:00 committed by Anas Nashif
commit d34e498d04
2 changed files with 8 additions and 1 deletions

View file

@ -114,7 +114,9 @@ struct bt_conn_le_info {
#if defined(CONFIG_BLUETOOTH_BREDR)
/** BR/EDR Connection Info Structure */
struct bt_conn_br_info {};
struct bt_conn_br_info {
const bt_addr_t *dst; /** Destination BR/EDR address */
};
#endif
/** Connection Info Structure */

View file

@ -783,6 +783,11 @@ int bt_conn_get_info(const struct bt_conn *conn, struct bt_conn_info *info)
info->le.dst = &conn->le.init_addr;
}
return 0;
#if defined(CONFIG_BLUETOOTH_BREDR)
case BT_CONN_TYPE_BR:
info->br.dst = &conn->br.dst;
return 0;
#endif
}
return -EINVAL;