[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <be1e53c3-262c-e6f5-d68b-ab41c40d11ac@oracle.com>
Date: Wed, 21 Oct 2020 09:58:25 -0700
From: Mike Kravetz <mike.kravetz@...cle.com>
To: David Hildenbrand <david@...hat.com>,
Michal Privoznik <mprivozn@...hat.com>,
Mina Almasry <almasrymina@...gle.com>
Cc: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-mm@...ck.org" <linux-mm@...ck.org>,
"Michael S. Tsirkin" <mst@...hat.com>,
Michal Hocko <mhocko@...nel.org>,
Muchun Song <songmuchun@...edance.com>,
"Aneesh Kumar K.V" <aneesh.kumar@...ux.vnet.ibm.com>,
Tejun Heo <tj@...nel.org>
Subject: Re: cgroup and FALLOC_FL_PUNCH_HOLE: WARNING: CPU: 13 PID: 2438 at
mm/page_counter.c:57 page_counter_uncharge+0x4b/0x5
> On 21.10.20 15:11, David Hildenbrand wrote:
>> On 21.10.20 14:57, Michal Privoznik wrote:
>>> On 10/21/20 5:35 AM, Mike Kravetz wrote:
>>>> On 10/20/20 6:38 AM, David Hildenbrand wrote:
>>>>
>>>> It would be good if Mina (at least) would look these over. Would also
>>>> be interesting to know if these fixes address the bug seen with the qemu
>>>> use case.
>>>>
>>>> I'm still doing more testing and code inspection to look for other issues.
>>>>
...
...
>>>
>>> I've applied, rebuilt and tested, but unfortunately I still hit the problem:
>>> [ 6472.719047] ------------[ cut here ]------------
>>> [ 6472.719052] WARNING: CPU: 6 PID: 11773 at mm/page_counter.c:57
...
...
>>
>> Agreed, same over here. :(
>>
>
> I *think* the following on top makes it fly
>
> diff --git a/mm/hugetlb.c b/mm/hugetlb.c
> index 67fc6383995b..5cf7f6a6c1a6 100644
> --- a/mm/hugetlb.c
> +++ b/mm/hugetlb.c
> @@ -656,6 +656,9 @@ static long region_del(struct resv_map *resv, long
> f, long t)
>
> del += t - f;
>
> + hugetlb_cgroup_uncharge_file_region(
> + resv, rg, t - f);
> +
> /* New entry for end of split region */
> nrg->from = t;
> nrg->to = rg->to;
> @@ -667,9 +670,6 @@ static long region_del(struct resv_map *resv, long
> f, long t)
> /* Original entry is trimmed */
> rg->to = f;
>
> - hugetlb_cgroup_uncharge_file_region(
> - resv, rg, nrg->to - nrg->from);
> -
> list_add(&nrg->link, &rg->link);
> nrg = NULL;
> break;
>
>
Thanks, yes that certainly does look like a bug in that code.
Does that resolve the issue with quemu?
I want to do a little more testing/research before sending a patch later
today.
--
Mike Kravetz
Powered by blists - more mailing lists