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
af03e7d5
Commit
af03e7d5
authored
Apr 11, 2013
by
Pavel Emelyanov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
page-pipe: Print full layout of page-pipe in log (in debug loglevel)
Signed-off-by:
Pavel Emelyanov
<
xemul@parallels.com
>
parent
3307bfd8
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
32 additions
and
0 deletions
+32
-0
page-pipe.h
include/page-pipe.h
+2
-0
mem.c
mem.c
+2
-0
page-pipe.c
page-pipe.c
+28
-0
No files found.
include/page-pipe.h
View file @
af03e7d5
...
@@ -28,4 +28,6 @@ struct page_pipe *create_page_pipe(unsigned int nr, struct iovec *);
...
@@ -28,4 +28,6 @@ struct page_pipe *create_page_pipe(unsigned int nr, struct iovec *);
void
destroy_page_pipe
(
struct
page_pipe
*
p
);
void
destroy_page_pipe
(
struct
page_pipe
*
p
);
int
page_pipe_add_page
(
struct
page_pipe
*
p
,
unsigned
long
addr
);
int
page_pipe_add_page
(
struct
page_pipe
*
p
,
unsigned
long
addr
);
int
page_pipe_add_hole
(
struct
page_pipe
*
p
,
unsigned
long
addr
);
int
page_pipe_add_hole
(
struct
page_pipe
*
p
,
unsigned
long
addr
);
void
debug_show_page_pipe
(
struct
page_pipe
*
pp
);
#endif
#endif
mem.c
View file @
af03e7d5
...
@@ -315,6 +315,8 @@ static int __parasite_dump_pages_seized(struct parasite_ctl *ctl,
...
@@ -315,6 +315,8 @@ static int __parasite_dump_pages_seized(struct parasite_ctl *ctl,
goto
out_pp
;
goto
out_pp
;
}
}
debug_show_page_pipe
(
pp
);
args
->
off
=
0
;
args
->
off
=
0
;
list_for_each_entry
(
ppb
,
&
pp
->
bufs
,
l
)
{
list_for_each_entry
(
ppb
,
&
pp
->
bufs
,
l
)
{
ret
=
parasite_send_fd
(
ctl
,
ppb
->
p
[
1
]);
ret
=
parasite_send_fd
(
ctl
,
ppb
->
p
[
1
]);
...
...
page-pipe.c
View file @
af03e7d5
...
@@ -172,3 +172,31 @@ int page_pipe_add_hole(struct page_pipe *pp, unsigned long addr)
...
@@ -172,3 +172,31 @@ int page_pipe_add_hole(struct page_pipe *pp, unsigned long addr)
out:
out:
return
0
;
return
0
;
}
}
void
debug_show_page_pipe
(
struct
page_pipe
*
pp
)
{
struct
page_pipe_buf
*
ppb
;
int
i
;
struct
iovec
*
iov
;
if
(
log_get_loglevel
()
<
LOG_DEBUG
)
return
;
pr_debug
(
"Page pipe:
\n
"
);
pr_debug
(
"* %u pipes %u/%u iovs:
\n
"
,
pp
->
nr_pipes
,
pp
->
free_iov
,
pp
->
nr_iovs
);
list_for_each_entry
(
ppb
,
&
pp
->
bufs
,
l
)
{
pr_debug
(
"
\t
buf %u pages, %u iovs:
\n
"
,
ppb
->
pages_in
,
ppb
->
nr_segs
);
for
(
i
=
0
;
i
<
ppb
->
nr_segs
;
i
++
)
{
iov
=
&
ppb
->
iov
[
i
];
pr_debug
(
"
\t\t
%p %lu
\n
"
,
iov
->
iov_base
,
iov
->
iov_len
/
PAGE_SIZE
);
}
}
pr_debug
(
"* %u holes:
\n
"
,
pp
->
free_hole
);
for
(
i
=
0
;
i
<
pp
->
free_hole
;
i
++
)
{
iov
=
&
pp
->
holes
[
i
];
pr_debug
(
"
\t
%p %lu
\n
"
,
iov
->
iov_base
,
iov
->
iov_len
/
PAGE_SIZE
);
}
}
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