Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-24 Thread Oscar Salvador
On Wed, Feb 24, 2021 at 11:47:49AM +0800, Muchun Song wrote: > I have been looking at the dequeue_huge_page_node_exact(). > If a PageHWPoison huge page is in the free pool list, the page will > not be allocated to the user. The PageHWPoison huge page > will be skip in the

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-23 Thread Muchun Song
On Wed, Feb 24, 2021 at 6:32 AM Oscar Salvador wrote: > > On Tue, Feb 23, 2021 at 04:41:28PM +0100, Oscar Salvador wrote: > > On Tue, Feb 23, 2021 at 11:50:05AM +0100, Oscar Salvador wrote: > > > > CPU0: CPU1: > > > > > > > >

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-23 Thread Oscar Salvador
On Tue, Feb 23, 2021 at 04:41:28PM +0100, Oscar Salvador wrote: > On Tue, Feb 23, 2021 at 11:50:05AM +0100, Oscar Salvador wrote: > > > CPU0: CPU1: > > > set_compound_page_dtor(HUGETLB_PAGE_DTOR); > > > memory_failure_hugetlb > > >

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-23 Thread Oscar Salvador
On Tue, Feb 23, 2021 at 11:50:05AM +0100, Oscar Salvador wrote: > > CPU0: CPU1: > > set_compound_page_dtor(HUGETLB_PAGE_DTOR); > > memory_failure_hugetlb > > get_hwpoison_page > > __get_hwpoison_page > > get_page_unless_zero > >

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-23 Thread Oscar Salvador
On Tue, Feb 23, 2021 at 06:27:07PM +0800, Muchun Song wrote: > > > > + > > > > + if (alloc_huge_page_vmemmap(h, page)) { > > > > + int zeroed; > > > > + > > > > + spin_lock(_lock); > > > > + INIT_LIST_HEAD(>lru); > > > > + set_compound_page_dtor(page,

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-23 Thread Muchun Song
On Tue, Feb 23, 2021 at 5:28 PM Oscar Salvador wrote: > > On Mon, Feb 22, 2021 at 04:00:27PM -0800, Mike Kravetz wrote: > > > -static void update_and_free_page(struct hstate *h, struct page *page) > > > +static int update_and_free_page(struct hstate *h, struct page *page) > > > +

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-22 Thread Muchun Song
On Tue, Feb 23, 2021 at 8:01 AM Mike Kravetz wrote: > > On 2/19/21 2:49 AM, Muchun Song wrote: > > When we free a HugeTLB page to the buddy allocator, we should allocate > > the vmemmap pages associated with it. But we may cannot allocate vmemmap > > pages when the system is under memory

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-22 Thread Oscar Salvador
On Mon, Feb 22, 2021 at 06:31:12PM +0800, Muchun Song wrote: > On Mon, Feb 22, 2021 at 5:25 PM Michal Hocko wrote: > > > > On Sat 20-02-21 12:20:36, Muchun Song wrote: > > > On Fri, Feb 19, 2021 at 10:12 PM Michal Hocko wrote: > > [...] > > > > What about hugetlb page poisoning on HW failure

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-22 Thread Muchun Song
On Mon, Feb 22, 2021 at 5:25 PM Michal Hocko wrote: > > On Sat 20-02-21 12:20:36, Muchun Song wrote: > > On Fri, Feb 19, 2021 at 10:12 PM Michal Hocko wrote: > [...] > > > What about hugetlb page poisoning on HW failure (resp. soft offlining)? > > > > If the HW poisoned hugetlb page failed to be

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-22 Thread Michal Hocko
On Sat 20-02-21 12:20:36, Muchun Song wrote: > On Fri, Feb 19, 2021 at 10:12 PM Michal Hocko wrote: [...] > > What about hugetlb page poisoning on HW failure (resp. soft offlining)? > > If the HW poisoned hugetlb page failed to be dissolved, the page > will go back to the free list with

Re: [External] Re: [PATCH v16 4/9] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page

2021-02-19 Thread Muchun Song
On Fri, Feb 19, 2021 at 10:12 PM Michal Hocko wrote: > > On Fri 19-02-21 18:49:49, Muchun Song wrote: > > When we free a HugeTLB page to the buddy allocator, we should allocate > > the vmemmap pages associated with it. But we may cannot allocate vmemmap > > pages when the system is under memory