[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1307639543.20245.19.camel@lade.trondhjem.org>
Date: Thu, 09 Jun 2011 13:12:23 -0400
From: Trond Myklebust <Trond.Myklebust@...app.com>
To: "Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
Cc: linux-kernel@...r.kernel.org, mingo@...e.hu, laijs@...fujitsu.com,
dipankar@...ibm.com, akpm@...ux-foundation.org,
mathieu.desnoyers@...ymtl.ca, josh@...htriplett.org,
niv@...ibm.com, tglx@...utronix.de, peterz@...radead.org,
rostedt@...dmis.org, Valdis.Kletnieks@...edu, dhowells@...hat.com,
eric.dumazet@...il.com, darren@...art.com, patches@...aro.org
Subject: Re: [PATCH tip/core/rcu 13/28] nfs,rcu: Convert
call_rcu(nfs_free_delegation_callback) to kfree_rcu()
On Wed, 2011-06-08 at 12:29 -0700, Paul E. McKenney wrote:
> From: Lai Jiangshan <laijs@...fujitsu.com>
>
> The rcu callback nfs_free_delegation_callback() just calls a kfree(),
> so we use kfree_rcu() instead of the call_rcu(nfs_free_delegation_callback).
>
> Signed-off-by: Lai Jiangshan <laijs@...fujitsu.com>
> Signed-off-by: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>
> Cc: Trond Myklebust <Trond.Myklebust@...app.com>
> Reviewed-by: Josh Triplett <josh@...htriplett.org>
Acked-by: Trond Myklebust <Trond.Myklebust@...app.com>
> ---
> fs/nfs/delegation.c | 14 +-------------
> 1 files changed, 1 insertions(+), 13 deletions(-)
>
> diff --git a/fs/nfs/delegation.c b/fs/nfs/delegation.c
> index bbbc6bf..dd25c2a 100644
> --- a/fs/nfs/delegation.c
> +++ b/fs/nfs/delegation.c
> @@ -21,25 +21,13 @@
> #include "delegation.h"
> #include "internal.h"
>
> -static void nfs_do_free_delegation(struct nfs_delegation *delegation)
> -{
> - kfree(delegation);
> -}
> -
> -static void nfs_free_delegation_callback(struct rcu_head *head)
> -{
> - struct nfs_delegation *delegation = container_of(head, struct nfs_delegation, rcu);
> -
> - nfs_do_free_delegation(delegation);
> -}
> -
> static void nfs_free_delegation(struct nfs_delegation *delegation)
> {
> if (delegation->cred) {
> put_rpccred(delegation->cred);
> delegation->cred = NULL;
> }
> - call_rcu(&delegation->rcu, nfs_free_delegation_callback);
> + kfree_rcu(delegation, rcu);
> }
>
> /**
--
Trond Myklebust
Linux NFS client maintainer
NetApp
Trond.Myklebust@...app.com
www.netapp.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists