From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from psmtp.com (na3sys010amx162.postini.com [74.125.245.162]) by kanga.kvack.org (Postfix) with SMTP id F37736B0031 for ; Fri, 9 Aug 2013 10:49:24 -0400 (EDT) Received: by mail-vb0-f54.google.com with SMTP id q14so4091038vbe.41 for ; Fri, 09 Aug 2013 07:49:23 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20130809144601.159CAE0090@blue.fi.intel.com> References: <1375582645-29274-1-git-send-email-kirill.shutemov@linux.intel.com> <1375582645-29274-21-git-send-email-kirill.shutemov@linux.intel.com> <20130809144601.159CAE0090@blue.fi.intel.com> Date: Fri, 9 Aug 2013 07:49:23 -0700 Message-ID: Subject: Re: [PATCH 20/23] thp: handle file pages in split_huge_page() From: Ning Qu Content-Type: multipart/alternative; boundary=001a11339c6c68499904e384e1b8 Sender: owner-linux-mm@kvack.org List-ID: To: "Kirill A. Shutemov" Cc: Matthew Wilcox , "Kirill A. Shutemov" , linux-fsdevel@vger.kernel.org, Hugh Dickins , Mel Gorman , Al Viro , Andrew Morton , Andrea Arcangeli , linux-kernel@vger.kernel.org, Andi Kleen , Wu Fengguang , Jan Kara , Dave Hansen , linux-mm@kvack.org, Hillf Danton --001a11339c6c68499904e384e1b8 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Sure! On Aug 9, 2013 7:42 AM, "Kirill A. Shutemov" < kirill.shutemov@linux.intel.com> wrote: > Ning Qu wrote: > > I just tried, and it seems working fine now without the deadlock > anymore. I > > can run some big internal test with about 40GB files in sysv shm. Just > move > > the line before the locking happens in vma_adjust, something as below, > the > > line number is not accurate because my patch is based on another tree > right > > now. > > Looks okay to me. Could you prepare real patch (description, etc.). I'll > add it to my patchset. > > > > > --- a/mm/mmap.c > > +++ b/mm/mmap.c > > @@ -581,6 +581,8 @@ again: remove_next =3D 1 + (en= d > > > next->vm_end); > > } > > } > > > > + vma_adjust_trans_huge(vma, start, end, adjust_next); > > + > > if (file) { > > mapping =3D file->f_mapping; > > if (!(vma->vm_flags & VM_NONLINEAR)) > > @@ -597,8 +599,6 @@ again: remove_next =3D 1 + (en= d > > > next->vm_end); > > } > > } > > > > - vma_adjust_trans_huge(vma, start, end, adjust_next); > > - > > anon_vma =3D vma->anon_vma; > > if (!anon_vma && adjust_next) > > anon_vma =3D next->anon_vma; > > > > > > Best wishes, > > -- > > Ning Qu (=E6=9B=B2=E5=AE=81) | Software Engineer | quning@google.com | = +1-408-418-6066 > > -- > Kirill A. Shutemov > --001a11339c6c68499904e384e1b8 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

Sure!

On Aug 9, 2013 7:42 AM, "Kirill A. Shutemov= " <kirill.shutem= ov@linux.intel.com> wrote:
Ning Qu wrote:
> I just tried, and it seems working fine now without the deadlock anymo= re. I
> can run some big internal test with about 40GB files in sysv shm. Just= move
> the line before the locking happens in vma_adjust, something as below,= the
> line number is not accurate because my patch is based on another tree = right
> now.

Looks okay to me. Could you prepare real patch (description, etc.). I'l= l
add it to my patchset.

>
> --- a/mm/mmap.c
> +++ b/mm/mmap.c
> @@ -581,6 +581,8 @@ again: =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0remove_next =3D 1 + (end >
> next->vm_end);
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 }
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 }
>
> + =C2=A0 =C2=A0 =C2=A0 vma_adjust_trans_huge(vma, start, end, adjust_n= ext);
> +
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 if (file) {
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 mapping =3D fi= le->f_mapping;
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 if (!(vma->= vm_flags & VM_NONLINEAR))
> @@ -597,8 +599,6 @@ again: =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0remove_next =3D 1 + (end >
> next->vm_end);
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 }
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 }
>
> - =C2=A0 =C2=A0 =C2=A0 vma_adjust_trans_huge(vma, start, end, adjust_n= ext);
> -
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 anon_vma =3D vma->anon_vma;
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 if (!anon_vma && adjust_next)
> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 anon_vma =3D n= ext->anon_vma;
>
>
> Best wishes,
> --
> Ning Qu (=E6=9B=B2=E5=AE=81) | Software Engineer | quning@google.com | +1-408-418-6066

--
=C2=A0Kirill A. Shutemov
--001a11339c6c68499904e384e1b8-- -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org