mirror of
https://github.com/apache/nuttx.git
synced 2026-06-08 01:42:58 +08:00
mm/shm: Clean up the System-V shm driver
Move shmdt functionality into shm_unmap, and use shm_unmap as the common detach function. Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
This commit is contained in:
committed by
Xiang Xiao
parent
eef818e51f
commit
3ea7a6fb77
@@ -164,23 +164,5 @@ FAR void *shm_alloc(FAR struct task_group_s *group, FAR void *vaddr,
|
||||
|
||||
void shm_free(FAR struct task_group_s *group, FAR void *vaddr, size_t size);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: shmdt_priv
|
||||
*
|
||||
* Description:
|
||||
* This is the shmdt internal implementation of the shm driver. It takes
|
||||
* the task group struct as a parameter and can handle both normal detach
|
||||
* and cleanup during process exit.
|
||||
*
|
||||
* Input Parameters:
|
||||
* group - A reference to the group structure from which to detach
|
||||
* shmaddr - Virtual start address where the allocation starts.
|
||||
* shmid - Id of the allocation
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int shmdt_priv(FAR struct task_group_s *group, FAR const void *shmaddr,
|
||||
int shmid);
|
||||
|
||||
#endif /* CONFIG_MM_SHM */
|
||||
#endif /* __INCLUDE_NUTTX_MM_SHM_H */
|
||||
|
||||
Reference in New Issue
Block a user