Bluetooth: Remove #ifdefs from public header files
These prevent the documentation from being included in the generated doxygen output. Change-Id: Iffe38c15055b8283d4b9f16b1c830c9f269ba6e4 Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This commit is contained in:
parent
c2ece8aec2
commit
58a1568943
5 changed files with 6 additions and 43 deletions
|
@ -381,7 +381,6 @@ static inline int bt_addr_le_to_str(const bt_addr_le_t *addr, char *str,
|
||||||
addr->a.val[2], addr->a.val[1], addr->a.val[0], type);
|
addr->a.val[2], addr->a.val[1], addr->a.val[0], type);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
/** @brief Enable/disable set controller in discoverable state.
|
/** @brief Enable/disable set controller in discoverable state.
|
||||||
*
|
*
|
||||||
* Allows make local controller to listen on INQUIRY SCAN channel and responds
|
* Allows make local controller to listen on INQUIRY SCAN channel and responds
|
||||||
|
@ -407,7 +406,6 @@ int bt_br_set_discoverable(bool enable);
|
||||||
* already set. Zero if done successfully.
|
* already set. Zero if done successfully.
|
||||||
*/
|
*/
|
||||||
int bt_br_set_connectable(bool enable);
|
int bt_br_set_connectable(bool enable);
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,6 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_CENTRAL) || defined(CONFIG_BLUETOOTH_PERIPHERAL)
|
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
|
|
||||||
#include <bluetooth/bluetooth.h>
|
#include <bluetooth/bluetooth.h>
|
||||||
|
@ -113,9 +112,7 @@ const bt_addr_le_t *bt_conn_get_dst(const struct bt_conn *conn);
|
||||||
/** Connection Type */
|
/** Connection Type */
|
||||||
enum {
|
enum {
|
||||||
BT_CONN_TYPE_LE, /** LE Connection Type */
|
BT_CONN_TYPE_LE, /** LE Connection Type */
|
||||||
#if defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
BT_CONN_TYPE_BR, /** BR/EDR Connection Type */
|
BT_CONN_TYPE_BR, /** BR/EDR Connection Type */
|
||||||
#endif
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/** LE Connection Info Structure */
|
/** LE Connection Info Structure */
|
||||||
|
@ -127,12 +124,10 @@ struct bt_conn_le_info {
|
||||||
uint16_t timeout; /** Connection supervision timeout */
|
uint16_t timeout; /** Connection supervision timeout */
|
||||||
};
|
};
|
||||||
|
|
||||||
#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 */
|
const bt_addr_t *dst; /** Destination BR/EDR address */
|
||||||
};
|
};
|
||||||
#endif
|
|
||||||
|
|
||||||
/** Connection role (master or slave) */
|
/** Connection role (master or slave) */
|
||||||
enum {
|
enum {
|
||||||
|
@ -151,9 +146,9 @@ struct bt_conn_info {
|
||||||
union {
|
union {
|
||||||
/** LE Connection specific Info */
|
/** LE Connection specific Info */
|
||||||
struct bt_conn_le_info le;
|
struct bt_conn_le_info le;
|
||||||
#if defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
|
/** BR/EDR Connection specific Info */
|
||||||
struct bt_conn_br_info br;
|
struct bt_conn_br_info br;
|
||||||
#endif
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -188,7 +183,6 @@ int bt_conn_le_param_update(struct bt_conn *conn,
|
||||||
*/
|
*/
|
||||||
int bt_conn_disconnect(struct bt_conn *conn, uint8_t reason);
|
int bt_conn_disconnect(struct bt_conn *conn, uint8_t reason);
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_CENTRAL)
|
|
||||||
/** @brief Initiate an LE connection to a remote device.
|
/** @brief Initiate an LE connection to a remote device.
|
||||||
*
|
*
|
||||||
* Allows initiate new LE link to remote peer using its address.
|
* Allows initiate new LE link to remote peer using its address.
|
||||||
|
@ -216,9 +210,7 @@ struct bt_conn *bt_conn_create_le(const bt_addr_le_t *peer,
|
||||||
*/
|
*/
|
||||||
int bt_le_set_auto_conn(bt_addr_le_t *addr,
|
int bt_le_set_auto_conn(bt_addr_le_t *addr,
|
||||||
const struct bt_le_conn_param *param);
|
const struct bt_le_conn_param *param);
|
||||||
#endif /* CONFIG_BLUETOOTH_CENTRAL */
|
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_PERIPHERAL)
|
|
||||||
/** @brief Initiate directed advertising to a remote device
|
/** @brief Initiate directed advertising to a remote device
|
||||||
*
|
*
|
||||||
* Allows initiating a new LE connection to remote peer with the remote
|
* Allows initiating a new LE connection to remote peer with the remote
|
||||||
|
@ -241,7 +233,6 @@ int bt_le_set_auto_conn(bt_addr_le_t *addr,
|
||||||
*/
|
*/
|
||||||
struct bt_conn *bt_conn_create_slave_le(const bt_addr_le_t *peer,
|
struct bt_conn *bt_conn_create_slave_le(const bt_addr_le_t *peer,
|
||||||
const struct bt_le_adv_param *param);
|
const struct bt_le_adv_param *param);
|
||||||
#endif /* CONFIG_BLUETOOTH_PERIPHERAL */
|
|
||||||
|
|
||||||
/** Security level. */
|
/** Security level. */
|
||||||
typedef enum __packed {
|
typedef enum __packed {
|
||||||
|
@ -253,7 +244,6 @@ typedef enum __packed {
|
||||||
*/
|
*/
|
||||||
} bt_security_t;
|
} bt_security_t;
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_SMP) || defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
/** @brief Set security level for a connection.
|
/** @brief Set security level for a connection.
|
||||||
*
|
*
|
||||||
* This function enable security (encryption) for a connection. If device is
|
* This function enable security (encryption) for a connection. If device is
|
||||||
|
@ -286,7 +276,6 @@ int bt_conn_security(struct bt_conn *conn, bt_security_t sec);
|
||||||
* @return Encryption key size.
|
* @return Encryption key size.
|
||||||
*/
|
*/
|
||||||
uint8_t bt_conn_enc_key_size(struct bt_conn *conn);
|
uint8_t bt_conn_enc_key_size(struct bt_conn *conn);
|
||||||
#endif /* CONFIG_BLUETOOTH_SMP || CONFIG_BLUETOOTH_BREDR */
|
|
||||||
|
|
||||||
/** Connection callback structure */
|
/** Connection callback structure */
|
||||||
struct bt_conn_cb {
|
struct bt_conn_cb {
|
||||||
|
@ -313,9 +302,6 @@ struct bt_conn_cb {
|
||||||
*/
|
*/
|
||||||
void bt_conn_cb_register(struct bt_conn_cb *cb);
|
void bt_conn_cb_register(struct bt_conn_cb *cb);
|
||||||
|
|
||||||
#endif /* CONFIG_BLUETOOTH_CENTRAL || CONFIG_BLUETOOTH_PERIPHERAL */
|
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_SMP) || defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
/** Authenticated pairing callback structure */
|
/** Authenticated pairing callback structure */
|
||||||
struct bt_conn_auth_cb {
|
struct bt_conn_auth_cb {
|
||||||
void (*passkey_display)(struct bt_conn *conn, unsigned int passkey);
|
void (*passkey_display)(struct bt_conn *conn, unsigned int passkey);
|
||||||
|
@ -383,7 +369,6 @@ int bt_conn_auth_passkey_confirm(struct bt_conn *conn);
|
||||||
*/
|
*/
|
||||||
int bt_conn_auth_pairing_confirm(struct bt_conn *conn);
|
int bt_conn_auth_pairing_confirm(struct bt_conn *conn);
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
/** @brief Reply with entered PIN code.
|
/** @brief Reply with entered PIN code.
|
||||||
*
|
*
|
||||||
* This function should be called only after PIN code callback from
|
* This function should be called only after PIN code callback from
|
||||||
|
@ -395,10 +380,7 @@ int bt_conn_auth_pairing_confirm(struct bt_conn *conn);
|
||||||
* @return Zero on success or negative error code otherwise
|
* @return Zero on success or negative error code otherwise
|
||||||
*/
|
*/
|
||||||
int bt_conn_auth_pincode_entry(struct bt_conn *conn, const char *pin);
|
int bt_conn_auth_pincode_entry(struct bt_conn *conn, const char *pin);
|
||||||
#endif /* CONFIG_BLUETOOTH_BREDR */
|
|
||||||
#endif /* CONFIG_BLUETOOTH_SMP || CONFIG_BLUETOOTH_BREDR */
|
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
/** Connection parameters for BR/EDR connections */
|
/** Connection parameters for BR/EDR connections */
|
||||||
struct bt_br_conn_param {
|
struct bt_br_conn_param {
|
||||||
bool allow_role_switch;
|
bool allow_role_switch;
|
||||||
|
@ -431,7 +413,6 @@ struct bt_br_conn_param {
|
||||||
*/
|
*/
|
||||||
struct bt_conn *bt_conn_create_br(const bt_addr_t *peer,
|
struct bt_conn *bt_conn_create_br(const bt_addr_t *peer,
|
||||||
const struct bt_br_conn_param *param);
|
const struct bt_br_conn_param *param);
|
||||||
#endif /* CONFIG_BLUETOOTH_BREDR */
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,12 +34,11 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_HOST_BUFFERS)
|
|
||||||
|
|
||||||
/** Allocate a buffer for an HCI event
|
/** Allocate a buffer for an HCI event
|
||||||
*
|
*
|
||||||
* This will set the BT_BUF_EVT buffer type so bt_buf_set_type()
|
* This will set the BT_BUF_EVT buffer type so bt_buf_set_type()
|
||||||
* doesn't need to be explicitly called.
|
* doesn't need to be explicitly called. Only available when
|
||||||
|
* CONFIG_BLUETOOTH_HOST_BUFFERS has been selected.
|
||||||
*
|
*
|
||||||
* @return A new buffer with the BT_BUF_EVT type.
|
* @return A new buffer with the BT_BUF_EVT type.
|
||||||
*/
|
*/
|
||||||
|
@ -48,14 +47,13 @@ struct net_buf *bt_buf_get_evt(void);
|
||||||
/** Allocate a buffer for incoming ACL data
|
/** Allocate a buffer for incoming ACL data
|
||||||
*
|
*
|
||||||
* This will set the BT_BUF_ACL_IN buffer type so bt_buf_set_type()
|
* This will set the BT_BUF_ACL_IN buffer type so bt_buf_set_type()
|
||||||
* doesn't need to be explicitly called.
|
* doesn't need to be explicitly called. Only available when
|
||||||
|
* CONFIG_BLUETOOTH_HOST_BUFFERS has been selected.
|
||||||
*
|
*
|
||||||
* @return A new buffer with the BT_BUF_ACL_IN type.
|
* @return A new buffer with the BT_BUF_ACL_IN type.
|
||||||
*/
|
*/
|
||||||
struct net_buf *bt_buf_get_acl(void);
|
struct net_buf *bt_buf_get_acl(void);
|
||||||
|
|
||||||
#endif /* CONFIG_BLUETOOTH_HOST_BUFFERS */
|
|
||||||
|
|
||||||
/* Receive data from the controller/HCI driver */
|
/* Receive data from the controller/HCI driver */
|
||||||
int bt_recv(struct net_buf *buf);
|
int bt_recv(struct net_buf *buf);
|
||||||
|
|
||||||
|
|
|
@ -31,7 +31,6 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_CENTRAL) || defined(CONFIG_BLUETOOTH_PERIPHERAL)
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <misc/util.h>
|
#include <misc/util.h>
|
||||||
|
@ -714,7 +713,6 @@ struct bt_gatt_indicate_params {
|
||||||
int bt_gatt_indicate(struct bt_conn *conn,
|
int bt_gatt_indicate(struct bt_conn *conn,
|
||||||
struct bt_gatt_indicate_params *params);
|
struct bt_gatt_indicate_params *params);
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_GATT_CLIENT)
|
|
||||||
/* Client API */
|
/* Client API */
|
||||||
|
|
||||||
/** @brief Response callback function
|
/** @brief Response callback function
|
||||||
|
@ -967,9 +965,6 @@ int bt_gatt_unsubscribe(struct bt_conn *conn,
|
||||||
*/
|
*/
|
||||||
void bt_gatt_cancel(struct bt_conn *conn);
|
void bt_gatt_cancel(struct bt_conn *conn);
|
||||||
|
|
||||||
#endif /* CONFIG_BLUETOOTH_GATT_CLIENT */
|
|
||||||
#endif /* CONFIG_BLUETOOTH_CENTRAL || CONFIG_BLUETOOTH_PERIPHERAL */
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -45,7 +45,6 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_CENTRAL) || defined(CONFIG_BLUETOOTH_PERIPHERAL)
|
|
||||||
#include <bluetooth/buf.h>
|
#include <bluetooth/buf.h>
|
||||||
#include <bluetooth/conn.h>
|
#include <bluetooth/conn.h>
|
||||||
|
|
||||||
|
@ -85,7 +84,6 @@ struct bt_l2cap_le_chan {
|
||||||
uint16_t _sdu_len;
|
uint16_t _sdu_len;
|
||||||
};
|
};
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
/** @brief BREDR L2CAP Endpoint structure. */
|
/** @brief BREDR L2CAP Endpoint structure. */
|
||||||
struct bt_l2cap_br_endpoint {
|
struct bt_l2cap_br_endpoint {
|
||||||
/** Endpoint CID */
|
/** Endpoint CID */
|
||||||
|
@ -103,7 +101,6 @@ struct bt_l2cap_br_chan {
|
||||||
/** Channel Transmission Endpoint */
|
/** Channel Transmission Endpoint */
|
||||||
struct bt_l2cap_br_endpoint tx;
|
struct bt_l2cap_br_endpoint tx;
|
||||||
};
|
};
|
||||||
#endif /* CONFIG_BLUETOOTH_BREDR */
|
|
||||||
|
|
||||||
/** @brief L2CAP Channel operations structure. */
|
/** @brief L2CAP Channel operations structure. */
|
||||||
struct bt_l2cap_chan_ops {
|
struct bt_l2cap_chan_ops {
|
||||||
|
@ -154,7 +151,6 @@ struct bt_l2cap_chan_ops {
|
||||||
void (*recv)(struct bt_l2cap_chan *chan, struct net_buf *buf);
|
void (*recv)(struct bt_l2cap_chan *chan, struct net_buf *buf);
|
||||||
};
|
};
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_L2CAP_DYNAMIC_CHANNEL)
|
|
||||||
/** @def BT_L2CAP_CHAN_SEND_RESERVE
|
/** @def BT_L2CAP_CHAN_SEND_RESERVE
|
||||||
* @brief Headroom needed for outgoing buffers
|
* @brief Headroom needed for outgoing buffers
|
||||||
*/
|
*/
|
||||||
|
@ -193,7 +189,6 @@ struct bt_l2cap_server {
|
||||||
*/
|
*/
|
||||||
int bt_l2cap_server_register(struct bt_l2cap_server *server);
|
int bt_l2cap_server_register(struct bt_l2cap_server *server);
|
||||||
|
|
||||||
#if defined(CONFIG_BLUETOOTH_BREDR)
|
|
||||||
/** @brief Register L2CAP server on BR/EDR oriented connection.
|
/** @brief Register L2CAP server on BR/EDR oriented connection.
|
||||||
*
|
*
|
||||||
* Register L2CAP server for a PSM, each new connection is authorized using
|
* Register L2CAP server for a PSM, each new connection is authorized using
|
||||||
|
@ -205,7 +200,6 @@ int bt_l2cap_server_register(struct bt_l2cap_server *server);
|
||||||
* @return 0 in case of success or negative value in case of error.
|
* @return 0 in case of success or negative value in case of error.
|
||||||
*/
|
*/
|
||||||
int bt_l2cap_br_server_register(struct bt_l2cap_server *server);
|
int bt_l2cap_br_server_register(struct bt_l2cap_server *server);
|
||||||
#endif /* CONFIG_BLUETOOTH_BREDR */
|
|
||||||
|
|
||||||
/** @brief Connect L2CAP channel
|
/** @brief Connect L2CAP channel
|
||||||
*
|
*
|
||||||
|
@ -253,9 +247,6 @@ int bt_l2cap_chan_disconnect(struct bt_l2cap_chan *chan);
|
||||||
*/
|
*/
|
||||||
int bt_l2cap_chan_send(struct bt_l2cap_chan *chan, struct net_buf *buf);
|
int bt_l2cap_chan_send(struct bt_l2cap_chan *chan, struct net_buf *buf);
|
||||||
|
|
||||||
#endif /* CONFIG_BLUETOOTH_L2CAP_DYNAMIC_CHANNEL */
|
|
||||||
#endif /* CONFIG_BLUETOOTH_CENTRAL || CONFIG_BLUETOOTH_PERIPHERAL */
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue