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]
Message-ID: <20240210235009.2405808-23-ukaszb@chromium.org>
Date: Sun, 11 Feb 2024 00:49:52 +0100
From: Ɓukasz Bartosik <ukaszb@...omium.org>
To: Jason Baron <jbaron@...mai.com>,
	Jim Cromie <jim.cromie@...il.com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Kees Cook <keescook@...omium.org>,
	Douglas Anderson <dianders@...omium.org>
Cc: Guenter Roeck <groeck@...gle.com>,
	Yaniv Tzoreff <yanivt@...gle.com>,
	Benson Leung <bleung@...gle.com>,
	Steven Rostedt <rostedt@...dmis.org>,
	Vincent Whitchurch <vincent.whitchurch@...s.com>,
	Pekka Paalanen <ppaalanen@...il.com>,
	Sean Paul <seanpaul@...omium.org>,
	Daniel Vetter <daniel@...ll.ch>,
	Simon Ser <contact@...rsion.fr>,
	John Ogness <john.ogness@...utronix.de>,
	Petr Mladek <pmladek@...e.com>,
	Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
	linux-kernel@...r.kernel.org,
	upstream@...ihalf.com
Subject: [PATCH v4 22/39] dyndbg: reduce verbose/debug clutter

From: Jim Cromie <jim.cromie@...il.com>

currently, for verbose=3, these are logged for each query

 dyndbg: query 0: <class DRM_UT_CORE +p> mod: <*>
 dyndbg: split into words: "class" "DRM_UT_CORE" "+p"
 dyndbg: op='+'
 dyndbg: flags=0x1
 dyndbg: *flagsp=0x1 *maskp=0xffffffff
 dyndbg: parsed: func="" file="" module="" format="" lineno=0-0 class=...
 dyndbg: no matches for query
 dyndbg: no-match: func="" file="" module="" format="" lineno=0-0 class=...
 dyndbg: processed 1 queries, with 0 matches, 0 errs

That is excessive, so this patch shrinks it to 4 lines:

 dyndbg: query 0: <class D2_CORE +T:foo > on module: <*>
 dyndbg: split into words: "class" "D2_CORE" "+T:foo"
 dyndbg: op='+' flags=0x40 maskp=0xffffffff trace_dest=0x0
 dyndbg: applied: func="" file="" module="" format="" lineno=0-0 class=...

Signed-off-by: Jim Cromie <jim.cromie@...il.com>
---
 lib/dynamic_debug.c | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c
index a6c6392cde3e..4954d3e5be5b 100644
--- a/lib/dynamic_debug.c
+++ b/lib/dynamic_debug.c
@@ -871,7 +871,6 @@ static int ddebug_parse_query(char *words[], int nwords,
 		 */
 		query->module = modname;
 
-	vpr_info_dq(query, "parsed");
 	return 0;
 }
 
@@ -896,7 +895,6 @@ static int ddebug_parse_flags(const char *str, struct flag_settings *modifiers)
 		pr_err("bad flag-op %c, at start of %s\n", *str, str);
 		return -EINVAL;
 	}
-	v3pr_info("op='%c'\n", op);
 
 	for (; *str ; ++str) {
 		for (i = ARRAY_SIZE(opt_array) - 1; i >= 0; i--) {
@@ -916,7 +914,6 @@ static int ddebug_parse_flags(const char *str, struct flag_settings *modifiers)
 			return -EINVAL;
 		}
 	}
-	v3pr_info("flags=0x%x, trace_dest=0x%x\n", modifiers->flags, modifiers->trace_dst);
 
 	/* calculate final flags, mask based upon op */
 	switch (op) {
@@ -933,8 +930,8 @@ static int ddebug_parse_flags(const char *str, struct flag_settings *modifiers)
 		break;
 	}
 
-	v3pr_info("flags=0x%x mask=0x%x, trace_dest=0x%x\n",
-		  modifiers->flags, modifiers->mask, modifiers->trace_dst);
+	v3pr_info("op='%c' flags=0x%x mask=0x%x trace_dest=0x%x\n",
+		  op, modifiers->flags, modifiers->mask, modifiers->trace_dst);
 
 	return 0;
 }
-- 
2.43.0.687.g38aa6559b0-goog


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ