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]
Message-Id: <1239695296.21985.6725.camel@twins>
Date:	Tue, 14 Apr 2009 09:48:15 +0200
From:	Peter Zijlstra <peterz@...radead.org>
To:	Frederic Weisbecker <fweisbec@...il.com>
Cc:	Ingo Molnar <mingo@...e.hu>, Steven Rostedt <rostedt@...dmis.org>,
	Zhaolei <zhaolei@...fujitsu.com>,
	Tom Zanussi <tzanussi@...il.com>,
	Li Zefan <lizf@...fujitsu.com>,
	LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] tracing/lockdep: turn lock->name into an array

On Tue, 2009-04-14 at 00:42 +0200, Frederic Weisbecker wrote:
> > +#define LOCK_NAME_SIZE       25
> 
> 
> 
> This constant may look a bit weird.
> I just started with the assumption that a full lock name
> will rarely exceed this length.
> 
> If you agree with it, I will expand the conversion of lockdep
> TRACE_FORMAT to TRACE_EVENTS with the same assumption.
> So that we will be able to use filters with locks events.

I really really hate this.

if you pick a size on the top end so that all lock->name's fit in,
you're wasting heaps of space, if you pick a median length, everything
will get truncated.

If you're going to do a copy, just do the print into the buffer by using
_FORMAT and be done with it.
--
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