Bluetooth: Add connection role to bt_conn_info
This can be useful for both LE and BR/EDR connections so it sits outside of those specific structs. The values are intentionally matching the HCI values so for the HCI case we can just do a direct assignment. Change-Id: Id78d304bb61e5fd941f2c35351758c1eecc6ab6a Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This commit is contained in:
parent
9632d46ae7
commit
500513b5f0
2 changed files with 11 additions and 0 deletions
|
@ -127,10 +127,20 @@ struct bt_conn_br_info {
|
|||
};
|
||||
#endif
|
||||
|
||||
/** Connection role (master or slave) */
|
||||
enum {
|
||||
BT_CONN_ROLE_MASTER,
|
||||
BT_CONN_ROLE_SLAVE,
|
||||
};
|
||||
|
||||
/** Connection Info Structure */
|
||||
struct bt_conn_info {
|
||||
/** Connection Type */
|
||||
uint8_t type;
|
||||
|
||||
/** Connection Role */
|
||||
uint8_t role;
|
||||
|
||||
union {
|
||||
/** LE Connection specific Info */
|
||||
struct bt_conn_le_info le;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue