mirror of
https://github.com/espressif/esp-idf.git
synced 2025-09-30 19:19:21 +00:00
ble_mesh: stack: Make some internal static functions inline
This commit is contained in:
@@ -356,7 +356,7 @@ int bt_mesh_client_send_msg(bt_mesh_client_common_param_t *param,
|
||||
|
||||
static bt_mesh_mutex_t client_model_lock;
|
||||
|
||||
static void bt_mesh_client_model_mutex_new(void)
|
||||
static inline void bt_mesh_client_model_mutex_new(void)
|
||||
{
|
||||
if (!client_model_lock.mutex) {
|
||||
bt_mesh_mutex_create(&client_model_lock);
|
||||
@@ -364,7 +364,7 @@ static void bt_mesh_client_model_mutex_new(void)
|
||||
}
|
||||
|
||||
#if CONFIG_BLE_MESH_DEINIT
|
||||
static void bt_mesh_client_model_mutex_free(void)
|
||||
static inline void bt_mesh_client_model_mutex_free(void)
|
||||
{
|
||||
bt_mesh_mutex_free(&client_model_lock);
|
||||
}
|
||||
|
@@ -111,7 +111,7 @@ static const bt_mesh_client_op_pair_t gen_op_pair[] = {
|
||||
|
||||
static bt_mesh_mutex_t generic_client_lock;
|
||||
|
||||
static void bt_mesh_generic_client_mutex_new(void)
|
||||
static inline void bt_mesh_generic_client_mutex_new(void)
|
||||
{
|
||||
if (!generic_client_lock.mutex) {
|
||||
bt_mesh_mutex_create(&generic_client_lock);
|
||||
@@ -119,18 +119,18 @@ static void bt_mesh_generic_client_mutex_new(void)
|
||||
}
|
||||
|
||||
#if CONFIG_BLE_MESH_DEINIT
|
||||
static void bt_mesh_generic_client_mutex_free(void)
|
||||
static inline void bt_mesh_generic_client_mutex_free(void)
|
||||
{
|
||||
bt_mesh_mutex_free(&generic_client_lock);
|
||||
}
|
||||
#endif /* CONFIG_BLE_MESH_DEINIT */
|
||||
|
||||
static void bt_mesh_generic_client_lock(void)
|
||||
static inline void bt_mesh_generic_client_lock(void)
|
||||
{
|
||||
bt_mesh_mutex_lock(&generic_client_lock);
|
||||
}
|
||||
|
||||
static void bt_mesh_generic_client_unlock(void)
|
||||
static inline void bt_mesh_generic_client_unlock(void)
|
||||
{
|
||||
bt_mesh_mutex_unlock(&generic_client_lock);
|
||||
}
|
||||
|
@@ -49,7 +49,7 @@ static const bt_mesh_client_op_pair_t sensor_op_pair[] = {
|
||||
|
||||
static bt_mesh_mutex_t sensor_client_lock;
|
||||
|
||||
static void bt_mesh_sensor_client_mutex_new(void)
|
||||
static inline void bt_mesh_sensor_client_mutex_new(void)
|
||||
{
|
||||
if (!sensor_client_lock.mutex) {
|
||||
bt_mesh_mutex_create(&sensor_client_lock);
|
||||
@@ -57,18 +57,18 @@ static void bt_mesh_sensor_client_mutex_new(void)
|
||||
}
|
||||
|
||||
#if CONFIG_BLE_MESH_DEINIT
|
||||
static void bt_mesh_sensor_client_mutex_free(void)
|
||||
static inline void bt_mesh_sensor_client_mutex_free(void)
|
||||
{
|
||||
bt_mesh_mutex_free(&sensor_client_lock);
|
||||
}
|
||||
#endif /* CONFIG_BLE_MESH_DEINIT */
|
||||
|
||||
static void bt_mesh_sensor_client_lock(void)
|
||||
static inline void bt_mesh_sensor_client_lock(void)
|
||||
{
|
||||
bt_mesh_mutex_lock(&sensor_client_lock);
|
||||
}
|
||||
|
||||
static void bt_mesh_sensor_client_unlock(void)
|
||||
static inline void bt_mesh_sensor_client_unlock(void)
|
||||
{
|
||||
bt_mesh_mutex_unlock(&sensor_client_lock);
|
||||
}
|
||||
|
@@ -65,7 +65,7 @@ static const bt_mesh_client_op_pair_t time_scene_op_pair[] = {
|
||||
|
||||
static bt_mesh_mutex_t time_scene_client_lock;
|
||||
|
||||
static void bt_mesh_time_scene_client_mutex_new(void)
|
||||
static inline void bt_mesh_time_scene_client_mutex_new(void)
|
||||
{
|
||||
if (!time_scene_client_lock.mutex) {
|
||||
bt_mesh_mutex_create(&time_scene_client_lock);
|
||||
@@ -73,18 +73,18 @@ static void bt_mesh_time_scene_client_mutex_new(void)
|
||||
}
|
||||
|
||||
#if CONFIG_BLE_MESH_DEINIT
|
||||
static void bt_mesh_time_scene_client_mutex_free(void)
|
||||
static inline void bt_mesh_time_scene_client_mutex_free(void)
|
||||
{
|
||||
bt_mesh_mutex_free(&time_scene_client_lock);
|
||||
}
|
||||
#endif /* CONFIG_BLE_MESH_DEINIT */
|
||||
|
||||
static void bt_mesh_time_scene_client_lock(void)
|
||||
static inline void bt_mesh_time_scene_client_lock(void)
|
||||
{
|
||||
bt_mesh_mutex_lock(&time_scene_client_lock);
|
||||
}
|
||||
|
||||
static void bt_mesh_time_scene_client_unlock(void)
|
||||
static inline void bt_mesh_time_scene_client_unlock(void)
|
||||
{
|
||||
bt_mesh_mutex_unlock(&time_scene_client_lock);
|
||||
}
|
||||
|
Reference in New Issue
Block a user