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:
parent
1fb522d0ff
commit
d34e498d04
2 changed files with 8 additions and 1 deletions
|
@ -114,7 +114,9 @@ struct bt_conn_le_info {
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_BREDR)
|
#if defined(CONFIG_BLUETOOTH_BREDR)
|
||||||
/** BR/EDR Connection Info Structure */
|
/** 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
|
#endif
|
||||||
|
|
||||||
/** Connection Info Structure */
|
/** Connection Info Structure */
|
||||||
|
|
|
@ -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;
|
info->le.dst = &conn->le.init_addr;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
#if defined(CONFIG_BLUETOOTH_BREDR)
|
||||||
|
case BT_CONN_TYPE_BR:
|
||||||
|
info->br.dst = &conn->br.dst;
|
||||||
|
return 0;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue