Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\migrate.c Create Date:2022-07-28 15:59:40
Last Modify:2022-05-20 09:53:13 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Determine the nodes of a user array of pages and store it in* a user array of status.

Proto:static int do_pages_stat(struct mm_struct *mm, unsigned long nr_pages, const void __user *__user *pages, int __user *status)

Type:int

Parameter:

TypeParameterName
struct mm_struct *mm
unsigned longnr_pages
const void __user *__user *pages
int __user *status
1753  __user * chunk_pages[16]
1756  When nr_pages cycle
1759  chunk_nr = nr_pages
1760  If chunk_nr > Determine the nodes of a user array of pages and store it in* a user array of status. Then chunk_nr = Determine the nodes of a user array of pages and store it in* a user array of status.
1763  If copy_from_user(chunk_pages, pages, chunk_nr * size of chunk_pages ) Then Break
1766  Determine the nodes of an array of pages and store it in an array of status.
1768  If copy_to_user(status, chunk_status, chunk_nr * size of status ) Then Break
1771  pages += chunk_nr
1772  status += chunk_nr
1773  nr_pages -= chunk_nr
1775  Return If nr_pages Then -EFAULT Else 0
Caller
NameDescribe
kernel_move_pagesMove a list of pages in the address space of the currently executing* process.