Re: [PATCH v1] mm: hugetlb: remove incorrect comment

From: Naoya Horiguchi
Date: Wed Jul 20 2016 - 05:38:20 EST


On Tue, Jul 19, 2016 at 11:10:53AM +0200, Michal Hocko wrote:
> On Tue 19-07-16 11:08:18, Naoya Horiguchi wrote:
> > dequeue_hwpoisoned_huge_page() can be called without page lock hold,
> > so let's remove incorrect comment.
>
> Could you explain why the page lock is not really needed, please? Or
> what has changed that it is not needed anymore?

The reason is that dequeue_hwpoisoned_huge_page checks page_huge_active()
inside hugetlb_lock, which allows us to avoid trying to dequeue a hugepage
that are just allocated but not linked to active list yet, even without
taking page lock.

Your question makes me aware of another comment to be removed, so let me
update this.

Thanks,
Naoya Horiguchi
---