Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp453370lqo; Thu, 16 May 2024 10:46:09 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVCZ/YIBhlsa/m9K2gqmmCXytA4SI5BsFwYQejH2X5R0OrroIpAnUVnjE/25faI+tPIBn+MNxSeP7Jd+xncIM2a3LeGUj9G51ObcJP2PQ== X-Google-Smtp-Source: AGHT+IGPMYjknJeEbds+3JS0OUzn6DAPvdKvKCkUykghbLXEUXna/B5y1xAQZOAOSQVtIYghV6rb X-Received: by 2002:a2e:9d14:0:b0:2e1:a504:f9ec with SMTP id 38308e7fff4ca-2e51fe542bdmr155725801fa.23.1715881569569; Thu, 16 May 2024 10:46:09 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715881569; cv=pass; d=google.com; s=arc-20160816; b=ECoCDwwEeh++Ai8fymRUuJTBSGkb05Jscz5azuhpWRTyAGiFaMF1IWtWACpEj/OmA5 jVCz9/Nm8RrLlydVVX2GLsWJWhcWzPZ5YR0kOs4vCGV0sJDzOXJ7IbZAQChedwZJ4Vdn 6QUnqma6daIo/dmzWJMu/pEbKPaXTvIqZoF+5iBNmfwweNmmT86BfSMpaUaaCL8u9f2u j+yuvtHYprBAbYHM+KMS8qyO4mjNf4FzdDqxtRKBg6n1w8nIG1tcYXHtLaZB6w5a+jnd y1B8NbVfNL2gCAW/4aBNiKLvNt3D+Mtb6AFHO+vYZ+PCiBfsI0G8h6LXoR1vyEvBcENT NEEg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=IQuNI/VL3/Itw4aJGKYcYvYUzx59qbXu6ruzCspuP/A=; fh=wmvykAPVp+83477RW2vTNcMgpsNtSO30I0mSiOeAe5I=; b=qvGmJLLI+jo+q90fA1+g4jUvdL2SiEoGGc7EJs5jYZyLZJ0yzbNZoUwuCipL0SDojh Fzw4Cd+rng4HN5UetKYA7YpGsqdsx4p5JNmmhZFpDnUZLeJOliVMcupOqRq14n3awDoa QRnLgz1hv+8J63fsZNTUMCHGG/TKaCAc8XeTudChN5yRoY0723cvKVva9LcKZifD/v+g bmFqJyVh1ITRNwURu+hVGdeAR4DocdTcdPg0/HTKcBUg1SFdMRqCajyLchnqYQaE2GZh xtvFOz/ZWpM8QYR+GyRr/wdfGEt6v/8dSZ6/MiBMILX5eCr0sNSgaCHjS4qhYDyerEn8 y3DQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=gA0tAO5O; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-181391-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-181391-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id a640c23a62f3a-a5cdd41ef08si143965466b.40.2024.05.16.10.46.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 May 2024 10:46:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-181391-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=gA0tAO5O; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-181391-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-181391-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 1EDE31F22C1F for ; Thu, 16 May 2024 17:46:09 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AF5911586DB; Thu, 16 May 2024 17:44:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="gA0tAO5O" Received: from mail-io1-f50.google.com (mail-io1-f50.google.com [209.85.166.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4C659156C74 for ; Thu, 16 May 2024 17:44:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.166.50 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715881461; cv=none; b=AJYuY/LLd0+sTP1wEcOBJsZmoo61jS8IbdFJ9moDIVH+pOktjFwfe2WrWQ2rc72pzW3yMyub0UBDxUBTeyqD3D7DEgJvqL82XRtZcl+PNYbwWsBYxCCwD0HpntPifMVaqQ83+HXITA/kT4Lg/J84Hdo0FZl86bfiymPXxTEBwDY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715881461; c=relaxed/simple; bh=zRw7b4KxY6XwSKZoRGW1l0s8wJscpuoS2KwZ+Arhbyc=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Csqd/0hvat50Q2H20b1jcqo3HASgUcIVr9l4HuEU5O8bYoqk+3QP+T3rbwQqGfJSNkhUpWQp4HppELKUZPmdZm6fkrdg8QG0+0WM2ZGI9mqfAunQ6f/cp65lNQNAbdm65MMtF6KcuglUIn3J09T94Xjk7UZ3fG0fzg88hBtN0pY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=gA0tAO5O; arc=none smtp.client-ip=209.85.166.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-io1-f50.google.com with SMTP id ca18e2360f4ac-7e2025c3651so62759139f.3 for ; Thu, 16 May 2024 10:44:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715881459; x=1716486259; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=IQuNI/VL3/Itw4aJGKYcYvYUzx59qbXu6ruzCspuP/A=; b=gA0tAO5OytNtZ89he8x72sobhp9+pnpCyqivVFCut5NA1ebXrgHDy/LknpMxVz7xJa xxSIrpYS1jPcopE4Gj5Wk3R85PzV9EUXIlwnoTduROaTRTgRGwGXOwt1zu/aom/IA1K0 BHJJqZvdr+0GNK9xchatp6D/Pg2I8D4p1aaqIuPkl/AtpjQPaksSs+7cm2Al1xFuWSjV Zhk1OPN1eYQJayp2AuxV3YFJelr7Hg8/7GZdrSc2nvkmA8q93u+ws6iGPZRl+dL1mFNN d8T4hcbcoM32unrcMksEApbxR4NiX8EA1XSa3YWTU4INvey/HTOrhWAOxDbnjBXtZrQW rjWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715881459; x=1716486259; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=IQuNI/VL3/Itw4aJGKYcYvYUzx59qbXu6ruzCspuP/A=; b=OuUtYx1hqJ5vexj0jmQ97oBReaopyRmijGFwbyyvDnc2/DtkVOu1LoMmX4swk8aBQj 77qNk6ByKJ8v2590UpUpeQWzpAANpDFt/xbdJQ4Z8HRKaU9Rvou9SXJdryLqtmGC8LYI 9TyZbTgaHhF2xzl3jEtDOccHQP6jO4m0sJRohvPZrngeJSi8Aq31A/OO5KZX/itRrY4H UqnF7wA9mTBW9JYyUHuXBXblPx4xohLU5KwvF+eV537Pky0idJ3WNC3rPth/hD98o6iM HyLtRjxVK4NlYYhqdJW/3/o0JsrCb7nX0F5J7rRQioF+OXmjtFThlR73uBWJjN7wW58T l2IA== X-Forwarded-Encrypted: i=1; AJvYcCWYw/Ayti3uFD6eWytFxqK+C6qK/2f7xp/O+5GXHhT1dOR06sYxV6s1f+3knFL22jdDz8QemO1HJJoHB5OZSxQoxDZqS8CUIXqAZ+gB X-Gm-Message-State: AOJu0YzEnLd29/ZVUt23d9T6IwP5gpXJW+/NNqQlvurRdN31KzEidXr8 WaIBXsHbo6aL8qBmoLGJXU9hIBUy5VwnW6P193I258h5inLBIT4c X-Received: by 2002:a5e:8a46:0:b0:7d9:a53a:c9bc with SMTP id ca18e2360f4ac-7e1b51c7b16mr2196661039f.10.1715881459466; Thu, 16 May 2024 10:44:19 -0700 (PDT) Received: from frodo.. (c-73-78-62-130.hsd1.co.comcast.net. [73.78.62.130]) by smtp.googlemail.com with ESMTPSA id 8926c6da1cb9f-4893715057csm4273595173.80.2024.05.16.10.44.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 May 2024 10:44:19 -0700 (PDT) From: Jim Cromie To: jbaron@akamai.com, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org Cc: ukaszb@chromium.org, linux@rasmusvillemoes.dk, joe@perches.com, mcgrof@kernel.org, daniel.vetter@ffwll.ch, tvrtko.ursulin@linux.intel.com, jani.nikula@intel.com, ville.syrjala@linux.intel.com, seanpaul@chromium.org, robdclark@gmail.com, groeck@google.com, yanivt@google.com, bleung@google.com, Jim Cromie Subject: [PATCH v8-RESEND 09/33] dyndbg: reduce verbose/debug clutter Date: Thu, 16 May 2024 11:43:33 -0600 Message-ID: <20240516174357.26755-10-jim.cromie@gmail.com> X-Mailer: git-send-email 2.45.0 In-Reply-To: <20240516174357.26755-1-jim.cromie@gmail.com> References: <20240516174357.26755-1-jim.cromie@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit currently, for verbose=3, these are logged (blank lines for clarity): 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 3 lines of 2nd stanza to single line - drops 1st 2 lines of 3rd stanza 3rd line is like 1st, with result, not procedure. 2nd line is just status, retold in 4th, with more info. New output: dyndbg: query 0: "class DRM_UT_CORE +p" mod:* dyndbg: split into words: "class" "DRM_UT_CORE" "+p" dyndbg: op='+' flags=0x1 *flagsp=0x1 *maskp=0xffffffff dyndbg: no-match: func="" file="" module="" format="" lineno=0-0 class=... dyndbg: processed 1 queries, with 0 matches, 0 errs no functional change. Signed-off-by: Jim Cromie --- lib/dynamic_debug.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c index 4a48f830507f..368381dbd266 100644 --- a/lib/dynamic_debug.c +++ b/lib/dynamic_debug.c @@ -266,9 +266,6 @@ static int ddebug_change(const struct ddebug_query *query, } mutex_unlock(&ddebug_lock); - if (!nfound && verbose) - pr_info("no matches for query\n"); - return nfound; } @@ -501,7 +498,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--) { @@ -515,7 +511,6 @@ static int ddebug_parse_flags(const char *str, struct flag_settings *modifiers) return -EINVAL; } } - v3pr_info("flags=0x%x\n", modifiers->flags); /* calculate final flags, mask based upon op */ switch (op) { @@ -531,7 +526,7 @@ static int ddebug_parse_flags(const char *str, struct flag_settings *modifiers) modifiers->flags = 0; break; } - v3pr_info("*flagsp=0x%x *maskp=0x%x\n", modifiers->flags, modifiers->mask); + v3pr_info("op='%c' flags=0x%x maskp=0x%x\n", op, modifiers->flags, modifiers->mask); return 0; } @@ -541,7 +536,7 @@ static int ddebug_exec_query(char *query_string, const char *modname) struct flag_settings modifiers = {}; struct ddebug_query query = {}; #define MAXWORDS 9 - int nwords, nfound; + int nwords; char *words[MAXWORDS]; nwords = ddebug_tokenize(query_string, words, MAXWORDS); @@ -559,10 +554,7 @@ static int ddebug_exec_query(char *query_string, const char *modname) return -EINVAL; } /* actually go and implement the change */ - nfound = ddebug_change(&query, &modifiers); - vpr_info_dq(&query, nfound ? "applied" : "no-match"); - - return nfound; + return ddebug_change(&query, &modifiers); } /* handle multiple queries in query string, continue on error, return -- 2.45.0