函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\slab.c Create Date:2022-07-27 17:17:39
Last Modify:2022-05-23 17:02:55 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:slab_memory_callback

函数原型:static int __meminit slab_memory_callback(struct notifier_block *self, unsigned long action, void *arg)

返回类型:int

参数:

类型参数名称
struct notifier_block *self
unsigned longaction
void *arg
1169  mnb等于arg
1170  ret等于0
1173  nid等于status_change_nid
1174  如果nid小于0则转到:out
1178  :action恒等于MEM_GOING_ONLINE
1179  mutex_lock( & slab_mutex)
1180  ret等于Allocates and initializes node for a node on each slab cache, used for* either memory or cpu hotplug
1181  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
1182  退出
1183  :action恒等于xposed to userspace
1184  mutex_lock( & slab_mutex)
1185  ret等于Drains freelist for a node on each slab cache, used for memory hot-remove.* Returns -EBUSY if all objects cannot be drained so that the node is not* removed.* Must hold slab_mutex.
1186  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
1187  退出
1188  :action恒等于xposed to userspace
1189  :action恒等于xposed to userspace
1190  :action恒等于MEM_CANCEL_ONLINE
1191  :action恒等于MEM_CANCEL_OFFLINE
1192  退出
1194  out :
1195  返回:Encapsulate (negative) errno value (in particular, NOTIFY_BAD <=> EPERM).