Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\zswap.c Create Date:2022-07-28 15:22:27
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Carries out the common pattern of freeing and entry's zpool allocation,* freeing the entry itself, and decrementing the number of stored pages.

Proto:static void zswap_free_entry(struct zswap_entry *entry)

Type:void

Parameter:

TypeParameterName
struct zswap_entry *entry
325  If Not the length in bytes of the compressed page data. Needed during Then atomic_dec( & The number of same-value filled pages currently stored in zswap )
327  Else
328  zpool_free(zpool, zpool allocation handle that stores the compressed page data)
329  zswap_pool_put( the zswap_pool the entry's data is in)
331  zswap_entry_cache_free(entry)
332  atomic_dec( & The number of compressed pages currently stored in zswap )
333  zswap_update_total_size()
Caller
NameDescribe
zswap_entry_putaller must hold the tree lock* remove from the tree and free it, if nobody reference the entry
zswap_frontswap_invalidate_areas all zswap entries for the given swap type