From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from psmtp.com (na3sys010amx134.postini.com [74.125.245.134]) by kanga.kvack.org (Postfix) with SMTP id 493946B0031 for ; Tue, 4 Jun 2013 11:34:12 -0400 (EDT) Received: by mail-wi0-f180.google.com with SMTP id hn14so340541wib.13 for ; Tue, 04 Jun 2013 08:34:10 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20130603174351.d04b2ac71d1bab0df242e0ba@mxc.nes.nec.co.jp> References: <20130523052421.13864.83978.stgit@localhost6.localdomain6> <20130523052547.13864.83306.stgit@localhost6.localdomain6> <20130523152445.17549682ae45b5aab3f3cde0@linux-foundation.org> <51A2BBA7.50607@jp.fujitsu.com> <51A71B49.3070003@cn.fujitsu.com> <20130603174351.d04b2ac71d1bab0df242e0ba@mxc.nes.nec.co.jp> Date: Tue, 4 Jun 2013 19:34:10 +0400 Message-ID: Subject: Re: [PATCH v8 9/9] vmcore: support mmap() on /proc/vmcore From: Maxim Uvarov Content-Type: multipart/alternative; boundary=001a11c222020666a704de55d015 Sender: owner-linux-mm@kvack.org List-ID: To: Atsushi Kumagai Cc: riel@redhat.com, "kexec@lists.infradead.org" , hughd@google.com, linux-kernel@vger.kernel.org, lisa.mitchell@hp.com, Vivek Goyal , linux-mm@kvack.org, HATAYAMA Daisuke , Zhang Yanfei , "Eric W. Biederman" , kosaki.motohiro@jp.fujitsu.com, Andrew Morton , walken@google.com, Cliff Wickman , jingbai.ma@hp.com --001a11c222020666a704de55d015 Content-Type: text/plain; charset=ISO-8859-1 2013/6/3 Atsushi Kumagai > Hello Maxim, > > On Thu, 30 May 2013 14:30:01 +0400 > Maxim Uvarov wrote: > > > 2013/5/30 Zhang Yanfei > > > > > On 05/30/2013 05:14 PM, Maxim Uvarov wrote: > > > > > > > > > > > > > > > > 2013/5/27 HATAYAMA Daisuke > > d.hatayama@jp.fujitsu.com>> > > > > > > > > (2013/05/24 18:02), Maxim Uvarov wrote: > > > > > > > > > > > > > > > > > > > > 2013/5/24 Andrew Morton > > akpm@linux-foundation.org> > > akpm@linux-foundation.org>>> > > > > > > > > > > > > On Thu, 23 May 2013 14:25:48 +0900 HATAYAMA Daisuke < > > > d.hatayama@jp.fujitsu.com > > d.hatayama@jp.fujitsu.__com >> > wrote: > > > > > > > > > This patch introduces mmap_vmcore(). > > > > > > > > > > Don't permit writable nor executable mapping even with > > > mprotect() > > > > > because this mmap() is aimed at reading crash dump > memory. > > > > > Non-writable mapping is also requirement of > > > remap_pfn_range() when > > > > > mapping linear pages on non-consecutive physical > pages; > > > see > > > > > is_cow_mapping(). > > > > > > > > > > Set VM_MIXEDMAP flag to remap memory by > remap_pfn_range > > > and by > > > > > remap_vmalloc_range_pertial at the same time for a > single > > > > > vma. do_munmap() can correctly clean partially > remapped > > > vma with two > > > > > functions in abnormal case. See zap_pte_range(), > > > vm_normal_page() and > > > > > their comments for details. > > > > > > > > > > On x86-32 PAE kernels, mmap() supports at most 16TB > > > memory only. This > > > > > limitation comes from the fact that the third > argument of > > > > > remap_pfn_range(), pfn, is of 32-bit length on x86-32: > > > unsigned long. > > > > > > > > More reviewing and testing, please. > > > > > > > > > > > > Do you have git pull for both kernel and userland changes? I > > > would like to do some more testing on my machines. > > > > > > > > Maxim. > > > > > > > > > > > > Thanks! That's very helpful. > > > > > > > > -- > > > > Thanks. > > > > HATAYAMA, Daisuke > > > > > > > > Any update for this? Where can I checkout all sources? > > > > > > This series is now in Andrew Morton's -mm tree. > > > > > > Ok, and what about makedumpfile changes? Is it possible to fetch them > from > > somewhere? > > You can fetch them from here, "mmap" branch is the change: > > git://git.code.sf.net/p/makedumpfile/code > > And they will be merged into v1.5.4. > > thank you, got it. But still do not see kernel patches in akpm tree: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git http://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git Should I look at different branch? Maxim. > > Thanks > Atsushi Kumagai > > _______________________________________________ > kexec mailing list > kexec@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/kexec > -- Best regards, Maxim Uvarov --001a11c222020666a704de55d015 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable



2013/6/3 Atsushi Kumagai <kumagai-atsushi@mxc.nes.= nec.co.jp>
Hello Maxim,

On Thu, 30 May 2013 14:30:01 +0400
Maxim Uvarov <muvarov@gmail.com= > wrote:

> 2013/5/30 Zhang Yanfei <zhangyanfei@cn.fujitsu.com>
>
> > On 05/30/2013 05:14 PM, Maxim Uvarov wrote:
> > >
> > >
> > >
> > > 2013/5/27 HATAYAMA Daisuke <d.hatayama@jp.fujitsu.com <mailto:
> > d.hatayama@jp.fujits= u.com>>
> > >
> > > =A0 =A0 (2013/05/24 18:02), Maxim Uvarov wrote:
> > >
> > >
> > >
> > >
> > > =A0 =A0 =A0 =A0 2013/5/24 Andrew Morton <akpm@linux-foundation.org <mailto:
> > akpm@linux-foundatio= n.org> <mailto:akpm@lin= ux-foundation.__org <mailto:
> > akpm@linux-foundatio= n.org>>>
> > >
> > >
> > > =A0 =A0 =A0 =A0 =A0 =A0 On Thu, 23 May 2013 14:25:48 +0900 H= ATAYAMA Daisuke <
> > d.hatayama@jp.fujits= u.com <mailto:d.hatayam= a@jp.fujitsu.com> <mailto:
> > d.hatayama@jp.fujitsu.__com <mailto:d.hatayama@jp.fujitsu.com>>> wrote:
> > >
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> This patch introduces mmap_v= mcore().
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0>
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> Don't permit writable no= r executable mapping even with
> > mprotect()
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> because this mmap() is aimed= at reading crash dump memory.
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> Non-writable mapping is also= requirement of
> > remap_pfn_range() when
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> mapping linear pages on non-= consecutive physical pages;
> > see
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> is_cow_mapping().
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0>
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> Set VM_MIXEDMAP flag to rema= p memory by remap_pfn_range
> > and by
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> remap_vmalloc_range_pertial = at the same time for a single
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> vma. do_munmap() can correct= ly clean partially remapped
> > vma with two
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> functions in abnormal case. = See zap_pte_range(),
> > vm_normal_page() and
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> their comments for details.<= br> > > > =A0 =A0 =A0 =A0 =A0 =A0 =A0>
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> On x86-32 PAE kernels, mmap(= ) supports at most 16TB
> > memory only. This
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> limitation comes from the fa= ct that the third argument of
> > > =A0 =A0 =A0 =A0 =A0 =A0 =A0> remap_pfn_range(), pfn, is o= f 32-bit length on x86-32:
> > unsigned long.
> > >
> > > =A0 =A0 =A0 =A0 =A0 =A0 More reviewing and testing, please.<= br> > > >
> > >
> > > =A0 =A0 =A0 =A0 Do you have git pull for both kernel and use= rland changes? I
> > would like to do some more testing on my machines.
> > >
> > > =A0 =A0 =A0 =A0 Maxim.
> > >
> > >
> > > =A0 =A0 Thanks! That's very helpful.
> > >
> > > =A0 =A0 --
> > > =A0 =A0 Thanks.
> > > =A0 =A0 HATAYAMA, Daisuke
> > >
> > > Any update for this? Where can I checkout all sources?
> >
> > This series is now in Andrew Morton's -mm tree.
> >
> > Ok, and what about makedumpfile changes? Is it possible to fetch = them from
> somewhere?

You can fetch them from here, "mmap" branch is the ch= ange:

=A0 git://git.code.sf.net/p/makedumpfile/code

And they will be merged into v1.5.4.


Should I lo= ok at different branch?

Maxim.

=A0

Thanks
Atsushi Kumagai

_______________________________________________
kexec mailing list
kexec@lists.infradead.org<= br> http://lists.infradead.org/mailman/listinfo/kexec



--
Best regard= s,
Maxim Uvarov
--001a11c222020666a704de55d015-- -- 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