[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZBbptCj8j3gWVesY@pc636>
Date: Sun, 19 Mar 2023 11:53:40 +0100
From: Uladzislau Rezki <urezki@...il.com>
To: "Paul E. McKenney" <paulmck@...nel.org>,
Theodore Ts'o <tytso@....edu>
Cc: "Uladzislau Rezki (Sony)" <urezki@...il.com>,
Theodore Ts'o <tytso@....edu>,
Joel Fernandes <joel@...lfernandes.org>,
RCU <rcu@...r.kernel.org>, LKML <linux-kernel@...r.kernel.org>,
Oleksiy Avramchenko <oleksiy.avramchenko@...y.com>,
Steven Rostedt <rostedt@...dmis.org>,
Frederic Weisbecker <frederic@...nel.org>,
linux-ext4@...r.kernel.org, Lukas Czerner <lczerner@...hat.com>,
Andreas Dilger <adilger.kernel@...ger.ca>
Subject: Re: [PATCH 1/1] ext4: Replace ext4_kvfree_array_rcu() by
kvfree_rcu_mightsleep()
On Fri, Mar 17, 2023 at 05:31:04PM -0700, Paul E. McKenney wrote:
> On Fri, Mar 17, 2023 at 08:15:58AM +0100, Uladzislau Rezki (Sony) wrote:
> > The ext4_kvfree_array_rcu() function was introduced in order to
> > release some memory after a grace period during resizing of a
> > partition. An object that is freed does not contain any rcu_head
> > filed.
> >
> > To do so, it requires to allocate some extra memory for a special
> > structure that has an rcu_head filed and pointer one where a freed
> > memory is attached. Finally call_rcu() API is invoked.
> >
> > Since we have a single argument of kvfree_rcu() API, we can easily
> > replace all that tricky code by one single call that does the same
> > but in more efficient way.
> >
> > Cc: linux-ext4@...r.kernel.org
> > Cc: Lukas Czerner <lczerner@...hat.com>
> > Cc: Andreas Dilger <adilger.kernel@...ger.ca>
> > Signed-off-by: Uladzislau Rezki (Sony) <urezki@...il.com>
>
> From an RCU perspective:
>
> Reviewed-by: Paul E. McKenney <paulmck@...nel.org>
>
Thank you!
--
Uladzislau Rezki
Powered by blists - more mailing lists