[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YFxk3UPLHI8/6XOh@dhcp22.suse.cz>
Date: Thu, 25 Mar 2021 11:24:29 +0100
From: Michal Hocko <mhocko@...e.com>
To: Oscar Salvador <osalvador@...e.de>
Cc: Mike Kravetz <mike.kravetz@...cle.com>, linux-mm@...ck.org,
linux-kernel@...r.kernel.org, Roman Gushchin <guro@...com>,
Shakeel Butt <shakeelb@...gle.com>,
David Hildenbrand <david@...hat.com>,
Muchun Song <songmuchun@...edance.com>,
David Rientjes <rientjes@...gle.com>,
Miaohe Lin <linmiaohe@...wei.com>,
Peter Zijlstra <peterz@...radead.org>,
Matthew Wilcox <willy@...radead.org>,
HORIGUCHI NAOYA <naoya.horiguchi@....com>,
"Aneesh Kumar K . V" <aneesh.kumar@...ux.ibm.com>,
Waiman Long <longman@...hat.com>, Peter Xu <peterx@...hat.com>,
Mina Almasry <almasrymina@...gle.com>,
Hillf Danton <hdanton@...a.com>,
Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [PATCH 1/8] mm: cma: introduce cma_release_nowait()
On Thu 25-03-21 11:17:32, Oscar Salvador wrote:
> On Thu, Mar 25, 2021 at 11:11:49AM +0100, Michal Hocko wrote:
> > I have overlooked that
> > +static void cma_clear_bitmap_fn(struct work_struct *work)
> > +{
> > + struct cma_clear_bitmap_work *w;
> > +
> > + w = container_of(work, struct cma_clear_bitmap_work, work);
> > +
> > + cma_clear_bitmap(w->cma, w->pfn, w->count);
> > +
> > + __free_page(pfn_to_page(w->pfn));
> > +}
> >
> > should be doing free_contig_range with w->count target.
>
> That is currently done in cma_release_nowait().
> You meant we should move that work there in the wq?
I have missed that part. My bad. But it seems this whole thing is moot
because we can make the lock a spinlock as pointed out by David.
--
Michal Hocko
SUSE Labs
Powered by blists - more mailing lists