函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:xas_nomem() - Allocate memory if needed.*@xas: XArray operation state.*@gfp: Memory allocation flags.* If we need to add new nodes to the XArray, we try to allocate memory* with GFP_NOWAIT while holding the lock, which will usually succeed.

函数原型:bool xas_nomem(struct xa_state *xas, gfp_t gfp)

返回类型:bool

参数:

类型参数名称
struct xa_state *xas
gfp_tgfp
298  如果xa_node不等于We encode errnos in the xas->xa_node. If an error has happened, we need to* drop the lock to fix it, and once we've done so the xa_state is invalid.( - ENOMEM)则
299  xas_destroy() - Free any resources allocated during the XArray operation.*@xas: XArray operation state.* This function is now internal-only.
300  返回:false
302  如果private: The rest of the data structure is not to be used directly. 按位与XA_FLAGS_ACCOUNTgfp或等于__GFP_ACCOUNT
304  xa_alloc等于kmem_cache_alloc(Move the radix tree node cache here , gfp)
305  如果非xa_alloc则返回:false
307  XA_NODE_BUG_ON(xa_alloc, !链表为空)
308  xa_node等于XAS_RESTART
309  返回:true
调用者
名称描述
xa_store_rangexa_store_range() - Store this entry at a range of indices in the XArray
ida_alloc_rangeda_alloc_range() - Allocate an unused ID.*@ida: IDA handle.*@min: Lowest ID to allocate.*@max: Highest ID to allocate.*@gfp: Memory allocation flags.* Allocate an ID between @min and @max, inclusive. The allocated ID will
xa_store_orderIf anyone needs this, please move it to xarray.c. We have no current* users outside the test suite because all current multislot users want* to use the advanced API.
check_xas_erase
__check_store_iter
xa_store_many_order
check_create_range_4
check_workingset
add_to_swap_cacheadd_to_swap_cache resembles add_to_page_cache_locked on swapper_space,* but sets SwapCache flag and private instead of mapping and index.
__add_to_page_cache_locked
grab_mapping_entryFind page cache entry at given index. If it is a DAX entry, return it* with the entry locked. If the page cache doesn't contain an entry at* that index, add a locked empty entry.* When requesting an entry with size DAX_PMD, grab_mapping_entry() will