函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:aller must hold the tree lock* remove from the tree and free it, if nobody reference the entry

函数原型:static void zswap_entry_put(struct zswap_tree *tree, struct zswap_entry *entry)

返回类型:void

参数:

类型参数名称
struct zswap_tree *tree
struct zswap_entry *entry
348  refcount等于 the number of outstanding reference to the entry. This is needed先自减
350  BUG_ON(refcount < 0)
351  如果refcount恒等于0则
352  zswap_rb_erase( & rbroot, entry)
353  Carries out the common pattern of freeing and entry's zpool allocation,* freeing the entry itself, and decrementing the number of stored pages.
调用者
名称描述
zswap_writeback_entry
zswap_frontswap_storeattempts to compress and store an single page
zswap_frontswap_loadrns 0 if the page was successfully decompressed* return -1 on entry not found or error
zswap_frontswap_invalidate_pages an entry in zswap