函数逻辑报告 | 
Source Code:ipc\sem.c | 
Create Date:2022-07-27 18:20:37 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| 首页 | 函数Tree | 
| 注解内核,赢得工具 | 下载SCCT | English | 
函数名称:d_alloc_undo - lookup (and if not present create) undo array*@ns: namespace*@semid: semaphore array id* The function looks up (and if not present creates) the undo structure.* The size of the undo structure depends on the size of the semaphore
函数原型:static struct sem_undo *find_alloc_undo(struct ipc_namespace *ns, int semid)
返回类型:struct sem_undo
参数:
| 类型 | 参数 | 名称 | 
|---|---|---|
| struct ipc_namespace * | ns | |
| int | semid | 
| 1900 | 加自旋锁 | 
| 1901 | un等于lookup_undo(ulp, semid) | 
| 1902 | 自旋锁解锁 | 
| 1903 | 如果此条件成立可能性大(为编译器优化)(un != NULL)则转到:out | 
| 1908 | sma等于sem_obtain_object_check(ns, semid) | 
| 1909 | 如果是错误则 | 
| 1911 | 返回:错误指示 | 
| 1915 | 如果非ipc_rcu_getref( & permissions .. see ipc.h )则 | 
| 1918 | 转到:out | 
| 1924 | 如果非new则 | 
| 1925 | ipc_rcu_putref( & permissions .. see ipc.h , sem_rcu_free) | 
| 1926 | 返回:错误号 | 
| 1931 | sem_lock_and_putref(sma) | 
| 1939 | 加自旋锁 | 
| 1944 | un等于lookup_undo(ulp, semid) | 
| 1945 | 如果un则 | 
| 1950 | array of adjustments = (short * ) & new[1] | 
| 1951 | ack ptr to sem_undo_list 等于ulp | 
| 1952 | semaphore set identifier 等于semid | 
| 1953 | assert_spin_locked( & lock) | 
| 1954 | 添加RCU保护项 | 
| 1956 | 添加链表项 | 
| 1959 | success : | 
| 1960 | 自旋锁解锁 | 
| 1961 | sem_unlock(sma, - 1) | 
| 1962 | out : | 
| 1963 | 返回:un | 
| 名称 | 描述 | 
|---|---|
| do_semtimedop | 
| 源代码转换工具 开放的插件接口  | X | 
|---|---|
| 支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码  |