Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
criu
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhul
criu
Commits
7405f88c
Commit
7405f88c
authored
Jul 25, 2013
by
Pavel Emelyanov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rst: Add some comments to VMAs inheritance procedure
Signed-off-by:
Pavel Emelyanov
<
xemul@parallels.com
>
parent
fa66d926
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
cr-restore.c
cr-restore.c
+12
-0
No files found.
cr-restore.c
View file @
7405f88c
...
...
@@ -237,6 +237,10 @@ static int map_private_vma(pid_t pid, struct vma_area *vma, void *tgt_addr,
*
pvma
=
p
;
if
(
paddr
==
NULL
)
{
/*
* The respective memory area was NOT found in the parent.
* Map a new one.
*/
pr_info
(
"Map 0x%016"
PRIx64
"-0x%016"
PRIx64
" 0x%016"
PRIx64
" vma
\n
"
,
vma
->
vma
.
start
,
vma
->
vma
.
end
,
vma
->
vma
.
pgoff
);
...
...
@@ -250,6 +254,10 @@ static int map_private_vma(pid_t pid, struct vma_area *vma, void *tgt_addr,
return
-
1
;
}
}
else
{
/*
* This region was found in parent -- remap it to inherit physical
* pages (if any) from it (and COW them later if required).
*/
vma
->
ppage_bitmap
=
p
->
page_bitmap
;
addr
=
mremap
(
paddr
,
vma_area_len
(
vma
),
vma_area_len
(
vma
),
...
...
@@ -411,6 +419,10 @@ static int read_vmas(int pid)
unsigned
long
old_premmapped_len
,
pstart
=
0
;
rst_vmas
.
nr
=
0
;
/*
* Keep parent vmas at hands to check whether we can "inherit" them.
* See comments in map_private_vma.
*/
list_replace_init
(
&
rst_vmas
.
h
,
&
parent_vmas
);
/* Skip errors, because a zombie doesn't have an image of vmas */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment