函数逻辑报告 |
Source Code:mm\page_alloc.c |
Create Date:2022-07-27 16:34:52 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:Spill all the per-cpu pages from all CPUs back into the buddy allocator.* When zone parameter is non-NULL, spill just the single zone's pages.* Note that this can be extremely slow as the draining happens in a workqueue.
函数原型:void drain_all_pages(struct zone *zone)
返回类型:void
参数:
类型 | 参数 | 名称 |
---|---|---|
struct zone * | zone |
2894 | 如果WARN_ON_ONCE(!mm_percpu_wq)则返回 |
2903 | 如果非zone则返回 |
2905 | mutex_lock( & pcpu_drain_mutex) |
2917 | bool has_pcps = false |
2919 | 如果zone则 |
2920 | pcp等于per_cpu_ptr(CPU热/冷页帧列表, cpu) |
2921 | 如果 number of pages in the list 则has_pcps = true |
2923 | 否则 |
2924 | do nothing (z) |
2925 | pcp等于per_cpu_ptr(CPU热/冷页帧列表, cpu) |
2926 | 如果 number of pages in the list 则 |
2935 | 否则清空CPU信息 |
2940 | drain等于per_cpu_ptr( & pcpu_drain, cpu) |
2943 | INIT_WORK( & work, drain_local_pages_wq) |
2946 | 遍历CPU(cpu, & cpus_with_pcps) |
名称 | 描述 |
---|---|
__alloc_pages_direct_reclaim | The really slow allocator path where we enter direct reclaim |
madvise_inject_error | Error injection support for memory error handling. |
shake_page | When a unknown page type is encountered drain as many buffers as possible* in the hope to turn the page into a LRU or free page, which we can handle. |
read_page_owner | |
set_migratetype_isolate | |
pagetypeinfo_showmixedcount | Print out the number of pageblocks for each migratetype that contain pages* of other types. This gives an indication of how well fallbacks are being* contained by rmqueue_fallback(). It requires information from PAGE_OWNER* to determine what is going on |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |