* @brief Increments the reference count of a lightweight process * * @param[in,out] lwp The lightweight process whose reference count is to be incremented * * @return int The updated reference count after incrementing * * @note the reference is not for synchronization, but for the release of resource. the synchronization is done through lwp & pid lock. */
| 956 | * @note the reference is not for synchronization, but for the release of resource. the synchronization is done through lwp & pid lock. |
| 957 | */ |
| 958 | int lwp_ref_inc(struct rt_lwp *lwp) |
| 959 | { |
| 960 | int ref; |
| 961 | ref = rt_atomic_add(&lwp->ref, 1); |
| 962 | LOG_D("%s(%p(%s)): before %d", __func__, lwp, lwp->cmd, ref); |
| 963 | |
| 964 | return ref; |
| 965 | } |
| 966 | |
| 967 | /** |
| 968 | * @brief Decrements the reference count of a lightweight process (LWP) |
no outgoing calls
no test coverage detected