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: <20200613155738.2249399-23-jim.cromie@gmail.com>
Date:   Sat, 13 Jun 2020 09:57:36 -0600
From:   Jim Cromie <jim.cromie@...il.com>
To:     jbaron@...mai.com, linux-kernel@...r.kernel.org,
        akpm@...uxfoundation.org, gregkh@...uxfoundation.org
Cc:     linux@...musvillemoes.dk, Jim Cromie <jim.cromie@...il.com>
Subject: [PATCH v2 22/24] dyndbg: add print-class as trailing number to control output

This change adds trailing 0 for all existing callsites, and N>0 for
any uses of pr_debug_n().

subsequent patches add pr_debug_n(1) & pr_debug_n(2) to kset-example,
demonstrating that the callsite descriptors are getting initialized
properly by the *_cl adaptations done previously.

bash-5.0# modprobe kset-example
bash-5.0# grep -v '0$' control
[  311.060809] dynamic_debug:ddebug_proc_open: called
samples/kobject/kset-example.c:80 [kset_example]foo_attr_store =_ "called" 2
samples/kobject/kset-example.c:59 [kset_example]foo_attr_show =_ "called" 1
---
 lib/dynamic_debug.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c
index 0035218d7059..262a6a761219 100644
--- a/lib/dynamic_debug.c
+++ b/lib/dynamic_debug.c
@@ -919,7 +919,7 @@ static int ddebug_proc_show(struct seq_file *m, void *p)
 
 	if (p == SEQ_START_TOKEN) {
 		seq_puts(m,
-			 "# filename:lineno [module]function flags format\n");
+			 "# filename:lineno [module]function flags format prcls\n");
 		return 0;
 	}
 
@@ -928,7 +928,7 @@ static int ddebug_proc_show(struct seq_file *m, void *p)
 		   iter->table->mod_name, dp->function,
 		   ddebug_describe_flags(dp->flags, &flags));
 	seq_escape(m, dp->format, "\t\r\n\"");
-	seq_puts(m, "\"\n");
+	seq_printf(m, "\" %d\n", dp->pr_class);
 
 	return 0;
 }
-- 
2.26.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ