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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 20 Feb 2013 16:46:27 +0100
From:	Ingo Molnar <mingo@...nel.org>
To:	Sasha Levin <sasha.levin@...cle.com>
Cc:	peterz@...radead.org, jamie.iles@...cle.com, penberg@...nel.org,
	acme@...stprotocols.net, paulus@...ba.org,
	linux-kernel@...r.kernel.org, namhyung@...nel.org,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [liblockdep] Re: [PATCH v2 01/11] liblockdep: remove the need
 for liblockdep_init


* Sasha Levin <sasha.levin@...cle.com> wrote:

> On 02/19/2013 02:58 AM, Ingo Molnar wrote:
> > 
> > * Sasha Levin <sasha.levin@...cle.com> wrote:
> > 
> >> Use a constructor in the library instead of making the user manually
> >> call liblockdep_init().
> >>
> >> Signed-off-by: Sasha Levin <sasha.levin@...cle.com>
> >> ---
> >>  tools/lib/lockdep/common.c                    | 2 +-
> >>  tools/lib/lockdep/include/liblockdep/common.h | 1 -
> >>  tools/lib/lockdep/tests/AA.c                  | 1 -
> >>  tools/lib/lockdep/tests/ABBA.c                | 1 -
> >>  tools/lib/lockdep/tests/ABBCCA.c              | 1 -
> >>  tools/lib/lockdep/tests/ABBCCDDA.c            | 1 -
> >>  tools/lib/lockdep/tests/ABCABC.c              | 1 -
> >>  tools/lib/lockdep/tests/ABCDBCDA.c            | 1 -
> >>  tools/lib/lockdep/tests/ABCDBDDA.c            | 1 -
> >>  tools/lib/lockdep/tests/WW.c                  | 1 -
> >>  tools/lib/lockdep/tests/unlock_balance.c      | 1 -
> >>  tools/lib/lockdep/uinclude/linux/lockdep.h    | 1 -
> >>  12 files changed, 1 insertion(+), 12 deletions(-)
> > 
> > Note that due to the heavy objections in the kvmtool thread 
> > I have removed the tools/lib/lockdep library and tooling 
> > commits from the locking tree - to be able to merge the 
> > other locking commits upstream.
> 
> Understood.
> 
> > I'm pretty sad about this outcome as your code really 
> > brought new development life into lockdep - if you still 
> > want to pursue this approach then you might want to try it 
> > via the tools/kvm tree, or via a separate project.
> 
> I'm most likely to just fold it into a standalone project 
> since I'm not quite certain the purpose of tools/ at this 
> point.

You could also tempt Linus with a standalone pull request - 
altough at this point I'm not sure he'd take it.

Sharing the source code between user-space and kernel space 
makes quite a bit of sense, and copying files, while it works, 
just encourages needless forking. The impact of your changes on 
kernel/lockdep.c was minimal:

 47dd80e801c3 lockdep: Be nice about building from userspace
  kernel/lockdep.c | 4 ++++
  1 file changed, 4 insertions(+)

So I don't see any substantial 'drag' or downside on the kernel 
lockdep subsystem - and I see a lot of upsides from exposing 
user-space to the lockdep code.

Have you tried to check the locking of something more complex, 
such as Firefox? (assuming it uses pthread mutexes and rwlocks - 
I'm not sure about that.)

Thanks,

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