函数逻辑报告 |
Source Code:mm\page_alloc.c |
Create Date:2022-07-27 16:33:44 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| 首页 | 函数Tree |
| 注解内核,赢得工具 | 下载SCCT | English |
函数名称:Frees a number of pages from the PCP lists* Assumes all pages on list are in same zone, and of same order.* count is the number of pages to free.* If the zone was previously in an "all pages pinned" state then look to
函数原型:static void free_pcppages_bulk(struct zone *zone, int count, struct per_cpu_pages *pcp)
返回类型:void
参数:
| 类型 | 参数 | 名称 |
|---|---|---|
| struct zone * | zone | |
| int | count | |
| struct per_cpu_pages * | pcp |
| 1252 | migratetype等于0 |
| 1253 | batch_free等于0 |
| 1254 | prefetch_nr等于0 |
| 1269 | 循环 |
| 1270 | batch_free自加 |
| 1271 | 如果migratetype先自加恒等于MIGRATE_PCPTYPES则migratetype等于0 |
| 1277 | 如果batch_free恒等于MIGRATE_PCPTYPES则batch_free等于count |
| 1280 | 循环 |
| 1283 | 删除链表项 |
| 1284 | number of pages in the list 自减 |
| 1286 | 如果bulkfree_pcp_prepare(page)则继续下一循环 |
| 1289 | 添加链表项 |
| 1300 | 如果prefetch_nr自加小于 chunk size for buddy add/remove 则prefetch_buddy(page) |
| 1302 | 当count先自减且batch_free先自减且非链表为空循环 |
| 1305 | 加自旋锁 |
| 1313 | mt等于A cached value of the page's pageblock's migratetype, used when the page is* put on a pcplist |
| 1315 | VM_BUG_ON_PAGE(is_migrate_isolate(mt), page) |
| 1321 | trace_mm_page_pcpu_drain(page, 0, mt) |
| 1323 | 自旋锁解锁 |
| 名称 | 描述 |
|---|---|
| drain_zone_pages | Called from the vmstat counter updater to drain pagesets of this* currently executing processor on remote nodes after they have* expired.* Note that this function must be called with the thread pinned to* a single processor. |
| drain_pages_zone | Drain pcplists of the indicated processor and zone.* The processor must either be the current processor and the* thread pinned to the current processor or a processor that* is not online. |
| free_unref_page_commit |
| 源代码转换工具 开放的插件接口 | X |
|---|---|
| 支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |