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: <20090205184304.GF3114@redhat.com>
Date:	Thu, 5 Feb 2009 13:43:04 -0500
From:	Jason Baron <jbaron@...hat.com>
To:	Greg KH <greg@...ah.com>
Cc:	linux-kernel@...r.kernel.org, gnb@....com, gregkh@...e.de,
	nfsv4@...ux-nfs.org, systemtap@...rces.redhat.com
Subject: Re: [Patch 0/2] dynamic debug

On Thu, Feb 05, 2009 at 09:58:49AM -0800, Greg KH wrote:
> On Thu, Feb 05, 2009 at 11:45:20AM -0500, Jason Baron wrote:
> > hi,
> > 
> > This patchset combines Greg Bank's dprintk() patchset with the dynamic printk
> > patchset. We are renaming the combined solution 'dynamic debug'. As a reminder,
> > the patchset allows debug printk style statements to be dynamically 
> > enabled/disabled at runtime.
> > 
> > The key new feature of this patchset is a richer /debugfs control file
> > interface, (an example output from my system is at the bottom), which allows
> > fined grained control over the the debug output. The output can be controlled by
> > function, file and line number, module, and format string. 
> 
> That's nice, but do we really need to have that kind of control?  It
> seems like overkill.
> 

given the ability of this feature to very quickly fill the logs, I think
it makes sense for some cases. Also, Greg found it very useful in his debugging
work...

> > For example, to enable all debug statement in module 'nf_conntrack':
> > 
> > #echo -n 'module nf_conntrack +p' > /mnt/debugfs/dynamic_debug/control
> > 
> > A further explanation can be found in the documentation patch.
> > 
> > While adding these new features we have dropped a couple that we intend to add
> > back in subsequent patches. The ability to turn on/off all debugging at once,
> > either via the /debugfs control file, or via the kernel command line.
> > 
> > thanks,
> > 
> > -Jason and Greg
> > 
> > 
> > # filename:lineno [module]function flags format
> > arch/x86/kernel/setup_percpu.c:260 [setup_percpu]numa_set_node - "Setting\040node\040for\040non-present\040cpu\040%d\012"
> 
> Why the \040 syntax?  Can't we handle a space in a string?  Makes it
> very hard to grep for things...
> 

ok, patch below resolves the space issue.

thanks,

-Jason

Signed-off-by: Jason Baron <jbaron@...hat.com>

diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c
index 7db55ce..9e123ae 100644
--- a/lib/dynamic_debug.c
+++ b/lib/dynamic_debug.c
@@ -572,7 +572,7 @@ static int ddebug_proc_show(struct seq_file *m, void *p)
 		   dp->filename, dp->lineno,
 		   iter->table->mod_name, dp->function,
 		   ddebug_describe_flags(dp, flagsbuf, sizeof(flagsbuf)));
-	seq_escape(m, dp->format, " \t\r\n\"");
+	seq_escape(m, dp->format, "\t\r\n\"");
 	seq_puts(m, "\"\n");
 
 	return 0;


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