lkml.org 
[lkml]   [2016]   [Aug]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH] memremap: Fix NULL pointer BUG in get_zone_device_page()
Date
> On Tue, Aug 23, 2016 at 7:53 PM, Dan Williams <dan.j.williams@intel.com>
> wrote:
> > On Tue, Aug 23, 2016 at 6:29 PM, Kani, Toshimitsu <toshi.kani@hpe.com>
> wrote:
> >>> On Tue, Aug 23, 2016 at 4:47 PM, Kani, Toshimitsu
> <toshi.kani@hpe.com>
> >>> wrote:
:
> >>
> >> crash> p {struct vmem_altmap} 0xffff88046d045410
> >> $6 = {
> >> base_pfn = 0x480000,
> >> reserve = 0x2, // PHYS_PFN(SZ_8K)
> >> free = 0x101fe,
> >> align = 0x1fe,
> >> alloc = 0x10000
> >> }
> >
> > Ah, so, on second look the 0x490200000 data offset looks correct. The
> > total size of the address range is 16GB which equates to 256MB needed
> > for struct page, plus 2MB more to re-align the data on the next 2MB
> > boundary.
> >
> > The question now is why is the guest faulting on an access to an
> > address less than 0x490200000?
>
> Does the attached patch fix this for you?

Yeah, that makes sense. I will test it tomorrow.

BTW, why does devm_memremap_pages() put a whole range to pgmap_radix
as device memory, but only initialize page->pgmap for its data range? Is there
particular reason for this inconsistency?

Thanks,
-Toshi

\
 
 \ /
  Last update: 2016-09-17 09:57    [W:0.120 / U:0.488 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site