Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-17 Thread Michal Hocko
On Mon 17-12-18 14:29:04, David Hildenbrand wrote: > On 17.12.18 13:28, Michal Hocko wrote: > > On Mon 17-12-18 10:38:32, David Hildenbrand wrote: > > [...] > >> I am wondering if we should fix this on the memblock level instead than. > >> Something like, before handing memory over to the page

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-17 Thread David Hildenbrand
On 17.12.18 13:28, Michal Hocko wrote: > On Mon 17-12-18 10:38:32, David Hildenbrand wrote: > [...] >> I am wondering if we should fix this on the memblock level instead than. >> Something like, before handing memory over to the page allocator, add >> memory as reserved up to the last section

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-17 Thread Michal Hocko
On Mon 17-12-18 10:38:32, David Hildenbrand wrote: [...] > I am wondering if we should fix this on the memblock level instead than. > Something like, before handing memory over to the page allocator, add > memory as reserved up to the last section boundary. Or even when setting > the physical

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-17 Thread David Hildenbrand
On 14.12.18 20:23, Gerald Schaefer wrote: > On Fri, 14 Dec 2018 16:49:14 +0100 > David Hildenbrand wrote: > >> On 14.12.18 16:22, David Hildenbrand wrote: >>> On 12.12.18 18:27, Mikhail Zaslonko wrote: If memory end is not aligned with the sparse memory section boundary, the mapping

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-14 Thread Wei Yang
On Fri, Dec 14, 2018 at 11:19:59AM +0100, Michal Hocko wrote: >[Your From address seems to have a typo (linux.bm.com) - fixed] > >On Fri 14-12-18 10:33:55, Zaslonko Mikhail wrote: >[...] >> Yes, it might still trigger PF_POISONED_CHECK if the first page >> of the pageblock is left uninitialized

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-14 Thread Gerald Schaefer
On Fri, 14 Dec 2018 16:49:14 +0100 David Hildenbrand wrote: > On 14.12.18 16:22, David Hildenbrand wrote: > > On 12.12.18 18:27, Mikhail Zaslonko wrote: > >> If memory end is not aligned with the sparse memory section boundary, the > >> mapping of such a section is only partly initialized.

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-14 Thread David Hildenbrand
On 14.12.18 16:22, David Hildenbrand wrote: > On 12.12.18 18:27, Mikhail Zaslonko wrote: >> If memory end is not aligned with the sparse memory section boundary, the >> mapping of such a section is only partly initialized. This may lead to >> VM_BUG_ON due to uninitialized struct page access from

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-14 Thread David Hildenbrand
On 12.12.18 18:27, Mikhail Zaslonko wrote: > If memory end is not aligned with the sparse memory section boundary, the > mapping of such a section is only partly initialized. This may lead to > VM_BUG_ON due to uninitialized struct page access from > is_mem_section_removable() or

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-14 Thread Michal Hocko
[Your From address seems to have a typo (linux.bm.com) - fixed] On Fri 14-12-18 10:33:55, Zaslonko Mikhail wrote: [...] > Yes, it might still trigger PF_POISONED_CHECK if the first page > of the pageblock is left uninitialized (poisoned). > But in order to cover these exceptional cases we would

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-13 Thread Wei Yang
On Thu, Dec 13, 2018 at 01:37:16PM +0100, Zaslonko Mikhail wrote: >On 13.12.2018 04:46, Wei Yang wrote: >> On Wed, Dec 12, 2018 at 06:27:12PM +0100, Mikhail Zaslonko wrote: >>> If memory end is not aligned with the sparse memory section boundary, the >>> mapping of such a section is only partly

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-13 Thread Michal Hocko
On Wed 12-12-18 18:27:12, Mikhail Zaslonko wrote: > If memory end is not aligned with the sparse memory section boundary, the > mapping of such a section is only partly initialized. This may lead to > VM_BUG_ON due to uninitialized struct page access from > is_mem_section_removable() or

Re: [PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-12 Thread Wei Yang
On Wed, Dec 12, 2018 at 06:27:12PM +0100, Mikhail Zaslonko wrote: >If memory end is not aligned with the sparse memory section boundary, the >mapping of such a section is only partly initialized. This may lead to >VM_BUG_ON due to uninitialized struct page access from >is_mem_section_removable()

[PATCH v2 1/1] mm, memory_hotplug: Initialize struct pages for the full memory section

2018-12-12 Thread Mikhail Zaslonko
If memory end is not aligned with the sparse memory section boundary, the mapping of such a section is only partly initialized. This may lead to VM_BUG_ON due to uninitialized struct page access from is_mem_section_removable() or test_pages_in_a_zone() function triggered by memory_hotplug sysfs