[CRIU] Re: [PATCH cr] mm: mark a vma as stack, if a value of sp is in it

Cyrill Gorcunov gorcunov at openvz.org
Fri Sep 7 08:03:36 EDT 2012


On Fri, Sep 07, 2012 at 03:51:54PM +0400, Andrey Vagin wrote:
> 
> /proc/PID/maps can contains not up to date information about a stack vma.
> A kernel marks a VMA as stack, if thread_struct->usersp is in it,
> but usersp is updated, when a process calls a syscall.
> 
> This problem is occured, when we try to dump/restore a process in a loop.
> When a restorer resumes a process, a restorer vma will be marked as stack.
> 
> A thread stack should not be marked as stack, because its vma is mapped
> w/o MAP_GROWSDOWN.
> 
> Signed-off-by: Andrey Vagin <avagin at openvz.org>

Looks good to me, thanks Andrew!

Acked-by: Cyrill Gorcunov <gorcunov at openvz.org>


More information about the CRIU mailing list