Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-11 Thread Mike Rapoport
On Mon, Jan 11, 2021 at 10:06:43AM -0500, Qian Cai wrote: > On Sun, 2021-01-10 at 17:39 +0200, Mike Rapoport wrote: > > On Wed, Jan 06, 2021 at 04:04:21PM -0500, Qian Cai wrote: > > > On Wed, 2021-01-06 at 10:05 +0200, Mike Rapoport wrote: > > > > I think we trigger PF_POISONED_CHECK() in

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-11 Thread Qian Cai
On Sun, 2021-01-10 at 17:39 +0200, Mike Rapoport wrote: > On Wed, Jan 06, 2021 at 04:04:21PM -0500, Qian Cai wrote: > > On Wed, 2021-01-06 at 10:05 +0200, Mike Rapoport wrote: > > > I think we trigger PF_POISONED_CHECK() in PageSlab(), then > > > fffe > > > is "accessed" from

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-10 Thread Mike Rapoport
On Wed, Jan 06, 2021 at 04:04:21PM -0500, Qian Cai wrote: > On Wed, 2021-01-06 at 10:05 +0200, Mike Rapoport wrote: > > I think we trigger PF_POISONED_CHECK() in PageSlab(), then fffe > > is "accessed" from VM_BUG_ON_PAGE(). > > > > It seems to me that we are not initializing struct

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-06 Thread Qian Cai
On Wed, 2021-01-06 at 10:05 +0200, Mike Rapoport wrote: > I think we trigger PF_POISONED_CHECK() in PageSlab(), then fffe > is "accessed" from VM_BUG_ON_PAGE(). > > It seems to me that we are not initializing struct pages for holes at the node > boundaries because zones are already

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-06 Thread Mike Rapoport
On Tue, Jan 05, 2021 at 01:45:37PM -0500, Qian Cai wrote: > On Tue, 2021-01-05 at 10:24 +0200, Mike Rapoport wrote: > > Hi, > > > > On Mon, Jan 04, 2021 at 02:03:00PM -0500, Qian Cai wrote: > > > On Wed, 2020-12-09 at 23:43 +0200, Mike Rapoport wrote: > > > > From: Mike Rapoport > > > > > > > >

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-05 Thread Qian Cai
On Tue, 2021-01-05 at 10:24 +0200, Mike Rapoport wrote: > Hi, > > On Mon, Jan 04, 2021 at 02:03:00PM -0500, Qian Cai wrote: > > On Wed, 2020-12-09 at 23:43 +0200, Mike Rapoport wrote: > > > From: Mike Rapoport > > > > > > Interleave initialization of pages that correspond to holes with the > >

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-05 Thread Mike Rapoport
Hi, On Mon, Jan 04, 2021 at 02:03:00PM -0500, Qian Cai wrote: > On Wed, 2020-12-09 at 23:43 +0200, Mike Rapoport wrote: > > From: Mike Rapoport > > > > Interleave initialization of pages that correspond to holes with the > > initialization of memory map, so that zone and node information will

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-04 Thread Qian Cai
On Wed, 2020-12-09 at 23:43 +0200, Mike Rapoport wrote: > From: Mike Rapoport > > There could be struct pages that are not backed by actual physical memory. > This can happen when the actual memory bank is not a multiple of > SECTION_SIZE or when an architecture does not register memory holes >

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2020-12-10 Thread Greg KH
On Wed, Dec 09, 2020 at 11:43:04PM +0200, Mike Rapoport wrote: > From: Mike Rapoport > > There could be struct pages that are not backed by actual physical memory. > This can happen when the actual memory bank is not a multiple of > SECTION_SIZE or when an architecture does not register memory

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2020-12-09 Thread Andrea Arcangeli
Hello, On Wed, Dec 09, 2020 at 11:43:04PM +0200, Mike Rapoport wrote: > +void __init __weak memmap_init(unsigned long size, int nid, > +unsigned long zone, > +unsigned long range_start_pfn) > +{ > + unsigned long start_pfn, end_pfn,

[PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2020-12-09 Thread Mike Rapoport
From: Mike Rapoport There could be struct pages that are not backed by actual physical memory. This can happen when the actual memory bank is not a multiple of SECTION_SIZE or when an architecture does not register memory holes reserved by the firmware as memblock.memory. Such pages are