[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210408220453.f95942bf20baadd8dbbc1488@linux-foundation.org>
Date: Thu, 8 Apr 2021 22:04:53 -0700
From: Andrew Morton <akpm@...ux-foundation.org>
To: Miaohe Lin <linmiaohe@...wei.com>
Cc: Mike Kravetz <mike.kravetz@...cle.com>,
<n-horiguchi@...jp.nec.com>, <hillf.zj@...baba-inc.com>,
<linux-kernel@...r.kernel.org>, <linux-mm@...ck.org>
Subject: Re: [PATCH 4/4] mm/hugeltb: handle the error case in
hugetlb_fix_reserve_counts()
On Fri, 9 Apr 2021 11:17:49 +0800 Miaohe Lin <linmiaohe@...wei.com> wrote:
> On 2021/4/9 7:25, Mike Kravetz wrote:
> > On 4/2/21 2:32 AM, Miaohe Lin wrote:
> >> A rare out of memory error would prevent removal of the reserve map region
> >> for a page. hugetlb_fix_reserve_counts() handles this rare case to avoid
> >> dangling with incorrect counts. Unfortunately, hugepage_subpool_get_pages
> >> and hugetlb_acct_memory could possibly fail too. We should correctly handle
> >> these cases.
> >
> > Yes, this is a potential issue.
> >
> > The 'good news' is that hugetlb_fix_reserve_counts() is unlikely to ever
> > be called. To do so would imply we could not allocate a region entry
> > which is only 6 words in size. We also keep a 'cache' of entries so we
> > may not even need to allocate.
> >
> > But, as mentioned it is a potential issue.
>
> Yes, a potential *theoretical* issue.
>
> >
> >> Fixes: b5cec28d36f5 ("hugetlbfs: truncate_hugepages() takes a range of pages")
> >
> > This is likely going to make this get picked by by stable releases.
> > That is unfortunate as mentioned above this is mostly theoretical.
> >
>
> I will drop this. This does not worth backport.
>
-stable have been asked not to backport MM patches unless MM patches
include "cc:stable". ie, no making our backporting decisions for us,
please.
Powered by blists - more mailing lists