[Devel] RE: [PATCH v2 1/4] SUNRPC: release per-net clients lock before calling PipeFS dentries creation

2012-02-27 Thread David Laight
> Gmmm. > Please, correct me, if I'm wrong, that you are proposing > something like this: > > spin_lock(&sn->rpc_client_lock); > again: > list_for_each_entry(clnt,&sn->all_clients, cl_clients) { > if ((event == RPC_PIPEFS_MOUNT) && clnt->cl_dentry) || >

[Devel] RE: [PATCH v2 2/4] NFS: release per-net clients lock before calling PipeFS dentries creation

2012-02-27 Thread David Laight
> spin_lock(&nn->nfs_client_lock); > - list_for_each_entry(clp, &nn->nfs_client_list, cl_share_link) { > + list_for_each_entry_safe(clp, tmp, &nn->nfs_client_list, cl_share_link) { > if (clp->rpc_ops != &nfs_v4_clientops) > continue; > +

[Devel] RE: [PATCH v8 1/9] Basic kernel memory functionality for the Memory Controller

2011-12-16 Thread David Laight
> How about this? > > val = !!val; > > /* > * This follows the same hierarchy restrictions than > * mem_cgroup_hierarchy_write() > */ > if (!parent || !parent->use_hierarchy) { > if (list_empty(&cgroup->children)) >