lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 20 Oct 2010 13:37:47 +1100
From:	Nick Piggin <npiggin@...nel.dk>
To:	Miklos Szeredi <miklos@...redi.hu>
Cc:	npiggin@...nel.dk, linux-kernel@...r.kernel.org,
	linux-fsdevel@...r.kernel.org
Subject: Re: [patch 23/35] fs: icache use per-CPU lists and locks for sb
 inode lists

On Tue, Oct 19, 2010 at 05:33:54PM +0200, Miklos Szeredi wrote:
> On Tue, 19 Oct 2010, npiggin@...nel.d wrote:
> > +/**
> > + * inode_sb_list_add - add an inode to the sb's file list
> > + * @inode: inode to add
> > + * @sb: sb to add it to
> > + *
> > + * Use this function to associate an with the superblock it belongs to.
> 
>                                        ^^^inode

Yes, thanks.


> > @@ -1270,6 +1316,7 @@
> >  			continue;
> >  		if (!spin_trylock(&old->i_lock)) {
> >  			spin_unlock_bucket(b);
> > +			cpu_relax();
> 
> Doesn't this logically belong to a previous patch?

Yes, I had a couple of them leak out. I'll try to fix them
up... most trylocks get resolved with RCU later.

 
> > Index: linux-2.6/fs/super.c
> > ===================================================================
> > --- linux-2.6.orig/fs/super.c	2010-10-19 14:17:17.000000000 +1100
> > +++ linux-2.6/fs/super.c	2010-10-19 14:18:59.000000000 +1100
> > @@ -67,12 +67,25 @@
> >  			for_each_possible_cpu(i)
> >  				INIT_LIST_HEAD(per_cpu_ptr(s->s_files, i));
> >  		}
> > +		s->s_inodes = alloc_percpu(struct list_head);
> > +		if (!s->s_inodes) {
> > +			free_percpu(s->s_files);
> > +			security_sb_free(s);
> > +			kfree(s);
> > +			s = NULL;
> > +			goto out;
> 
> Factor out error cleanups to separate out labels?

OK... probably makes sense at this point.

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ