函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:pagetypeinfo_showblockcount_print

函数原型:static void pagetypeinfo_showblockcount_print(struct seq_file *m, pg_data_t *pgdat, struct zone *zone)

返回类型:void

参数:

类型参数名称
struct seq_file *m
pg_data_t *pgdat
struct zone *zone
1437  start_pfn等于内存域第一个页帧的索引
1438  end_pfn等于zone_end_pfn(zone)
1439  unsigned long count[MIGRATE_TYPES] = {0, }
1441 pfn小于end_pfn循环
1444  page等于Return page for the valid pfn only if the page is online. All pfn* walkers which rely on the fully initialized page->flags and others* should use this rather than pfn_valid && pfn_to_page(pfn)
1445  如果非page则继续下一循环
1449  如果非memmap_valid_within(pfn, page, zone)则继续下一循环
1452  如果page_zone(page)不等于zone则继续下一循环
1455  mtype等于get_pageblock_migratetype(page)
1457  如果mtype小于MIGRATE_TYPEScount[mtype]自加
1462  seq_printf(m, "Node %d, zone %8s ", 全局结点ID, 内存域的惯用名称(NORMAL DMA HIGHMEM))
1463 mtype小于MIGRATE_TYPES循环seq_printf(m, "%12lu ", count[mtype])
1465  seq_putc(m, '\n')