Function report |
Source Code:mm\mempolicy.c |
Create Date:2022-07-28 15:32:19 |
Last Modify:2020-03-17 22:28:11 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:kernel_migrate_pages
Proto:static int kernel_migrate_pages(pid_t pid, unsigned long maxnode, const unsigned long __user *old_nodes, const unsigned long __user *new_nodes)
Type:int
Parameter:
Type | Parameter | Name |
---|---|---|
pid_t | pid | |
unsigned long | maxnode | |
const unsigned long __user * | old_nodes | |
const unsigned long __user * | new_nodes |
1484 | NODEMASK_SCRATCH(scratch) |
1502 | task = If pid Then find_task_by_vpid(pid) Else current process |
1503 | If Not task Then |
1506 | Go to out |
1508 | get_task_struct(task) |
1516 | If Not ptrace_may_access(task, PTRACE_MODE_READ_REALCREDS) Then |
1519 | Go to out_put |
1523 | task_nodes = cpuset_mems_allowed(task) |
1525 | If Not nodes_subset( * new, task_nodes) && Not Check operation authority Then |
1531 | nodes_and( * new, * new, task_nodes) |
1532 | If nodes_empty( * new) Then Go to out_put |
1535 | err = security_task_movememory(task) |
1540 | put_task_struct(task) |
1542 | If Not mm Then |
1547 | err = Move pages between the two nodesets so as to preserve the physical* layout as much as possible.* Returns the number of page that could not be moved. |
1551 | out : |
1552 | NODEMASK_SCRATCH_FREE(scratch) |
1554 | Return err |
1556 | out_put : |
1557 | put_task_struct(task) |
1558 | Go to out |
Name | Describe |
---|---|
SYSCALL_DEFINE4 | |
COMPAT_SYSCALL_DEFINE4 |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |