[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210318111546.4bda8c7a@alex-virtual-machine>
Date: Thu, 18 Mar 2021 11:15:46 +0800
From: Aili Yao <yaoaili@...gsoft.com>
To: David Hildenbrand <david@...hat.com>
CC: <akpm@...ux-foundation.org>, <naoya.horiguchi@....com>,
<linux-mm@...ck.org>, <linux-kernel@...r.kernel.org>,
<yangfeng1@...gsoft.com>, <sunhao2@...gsoft.com>,
Oscar Salvador <osalvador@...e.de>,
Mike Kravetz <mike.kravetz@...cle.com>, <yaoaili@...gsoft.com>
Subject: Re: [PATCH] mm/gup: check page posion status for coredump.
On Wed, 17 Mar 2021 10:12:02 +0100
David Hildenbrand <david@...hat.com> wrote:
>
> I wonder if a simple
>
> if (PageHWPoison(compound_head(page)))
> ret = 0;
>
> won't suffice. But I guess the "issue" is compound pages that are not
> huge pages or transparent huge pages.
Yes, the simple case won't suffice, as we mark the hugetlb page poison in head, and
other cases in the specific single page struct.
> If not, we certainly want a wrapper for that magic, otherwise we have to
> replicate the same logic all over the place.
>
> > +
> > return (ret == 1) ? page : NULL;
> > }
> > #endif /* CONFIG_ELF_CORE */
> >
>
>
Yes, May other places meet the requirements as the coredump meets, it's better to make a
wrapper for this. But i am not familiar with the specific scenario, so this patch only cover
the coredump case.
I will post a v2 patch for this.
--
Thanks!
Aili Yao
Powered by blists - more mailing lists