Locking interface used in nm core. More...
#include <pthread.h>

Go to the source code of this file.
Functions | |
| static void | nm_core_lock (struct nm_core *p_core) |
| acquire the nm core lock | |
| static int | nm_core_trylock (struct nm_core *p_core) |
| try to lock the nm core core return 1 is lock is successfully acquired, 0 otherwise | |
| static void | nm_core_unlock (struct nm_core *p_core) |
| unlock the nm core lock | |
| static void | nm_core_lock_init (struct nm_core *p_core) |
| init the core lock | |
| static void | nm_core_lock_destroy (struct nm_core *p_core) |
| destroy the core lock | |
| static void | nm_core_nolock_assert (struct nm_core *p_core) |
| assert that current thread doesn't hold the lock | |
| static void | nm_core_lock_assert (struct nm_core *p_core) |
| assert that current thread holds the lock | |
| static void | nm_core_lock (struct nm_core *p_core __attribute__((unused))) |
| static int | nm_core_trylock (struct nm_core *p_core __attribute__((unused))) |
| static void | nm_core_unlock (struct nm_core *p_core __attribute__((unused))) |
| static void | nm_core_lock_init (struct nm_core *p_core __attribute__((unused))) |
| static void | nm_core_lock_destroy (struct nm_core *p_core __attribute__((unused))) |
| static void | nm_core_lock_assert (struct nm_core *p_core __attribute__((unused))) |
| static void | nm_core_nolock_assert (struct nm_core *p_core __attribute__((unused))) |
Detailed Description
Locking interface used in nm core.
This is not part of the public API and may not be used to lock something else than nmad core.
Definition in file nm_lock.h.
Function Documentation
◆ nm_core_lock() [1/2]
|
inlinestatic |
Definition at line 58 of file nm_lock.h.
References nm_profile_inc, and nm_spin_lock().

◆ nm_core_lock() [2/2]
|
inlinestatic |
acquire the nm core lock
◆ nm_core_lock_assert() [1/2]
|
inlinestatic |
Definition at line 87 of file nm_lock.h.
References nm_spin_assert_locked().

◆ nm_core_lock_assert() [2/2]
|
inlinestatic |
assert that current thread holds the lock
Referenced by nm_core_polling_level(), nm_core_post_ctrl(), nm_core_post_req_chunk(), nm_core_task_enqueue(), nm_gate_set_active(), nm_pw_ref_dec(), and nm_tactic_pack_ctrl().
◆ nm_core_lock_destroy() [1/2]
|
inlinestatic |
Definition at line 82 of file nm_lock.h.
References nm_spin_destroy().

◆ nm_core_lock_destroy() [2/2]
|
inlinestatic |
destroy the core lock
◆ nm_core_lock_init() [1/2]
|
inlinestatic |
Definition at line 77 of file nm_lock.h.
References nm_spin_init().

◆ nm_core_lock_init() [2/2]
|
inlinestatic |
init the core lock
◆ nm_core_nolock_assert() [1/2]
|
inlinestatic |
Definition at line 92 of file nm_lock.h.
References nm_spin_assert_notlocked().

◆ nm_core_nolock_assert() [2/2]
|
inlinestatic |
assert that current thread doesn't hold the lock
Referenced by nm_core_task_enqueue(), nm_pw_completed_enqueue(), and nm_req_chunk_submit().
◆ nm_core_trylock() [1/2]
|
inlinestatic |
Definition at line 64 of file nm_lock.h.
References nm_profile_inc, and nm_spin_trylock().

◆ nm_core_trylock() [2/2]
|
inlinestatic |
try to lock the nm core core return 1 is lock is successfully acquired, 0 otherwise
Referenced by nm_core_task_enqueue().
◆ nm_core_unlock() [1/2]
|
inlinestatic |
Definition at line 72 of file nm_lock.h.
References nm_spin_unlock().

◆ nm_core_unlock() [2/2]
|
inlinestatic |
unlock the nm core lock
Referenced by nm_core_task_enqueue().