Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:ksm_do_scan - the ksm scanner main worker function.*@scan_npages: number of pages we want to scan before we return.

Proto:static void ksm_do_scan(unsigned int scan_npages)

Type:void

Parameter:

TypeParameterName
unsigned intscan_npages
2382  struct page * page = page
2384  When scan_npages-- && Value is more likely to compile time(!freezing(current process)) cycle
2385  cond_resched()
2386  rmap_item = scan_get_next_rmap_item( & page)
2387  If Not rmap_item Then Return
2389  mp_and_merge_page - first see if page can be merged into the stable tree;* if not, compare checksum to previous and if it's the same, see if page can* be inserted into the unstable tree, or merged with a page already there and
2390  Perform a free_page(), also freeing any swap cache associated with* this page if it is the last user of the page.
Caller
NameDescribe
ksm_scan_thread