函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\lru_cache.c Create Date:2022-07-27 08:15:18
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:lc_prepare_for_change

函数原型:static struct lc_element *lc_prepare_for_change(struct lru_cache *lc, unsigned new_number)

返回类型:struct lc_element

参数:

类型参数名称
struct lru_cache *lc
unsignednew_number
326  如果非链表为空n等于链表后项
328  否则如果非链表为空n等于链表前项
330  否则返回:NULL
333  e等于list_entry - get the struct for this entry*@ptr: the &struct list_head pointer.*@type: the type of the struct this is embedded in.*@member: the name of the list_head within the struct.(n, structlc_element, list)
334  BUG() if e is not one of the elements tracked by lc (lc, e)
336  r pending changes 等于new_number
337  如果非hlist_unhashed( & colision)则__hlist_del( & colision)
339  hlist_add_head( & colision, lc_hash_slot(lc, new_number))
340  链表项移动到头部
342  返回:e
调用者
名称描述
__lc_get