Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp347603pxb; Thu, 23 Sep 2021 01:05:03 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx+DRfE79UPl5orKV7C9S212hqZPb4Tvz2UteXmJVa+uVU6x7+UzC9OVKxBd5vcRQdwFun1 X-Received: by 2002:a05:6638:2050:: with SMTP id t16mr2795020jaj.101.1632384303718; Thu, 23 Sep 2021 01:05:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632384303; cv=none; d=google.com; s=arc-20160816; b=Ic8qyOQf1vle3n7TXuhA0Bv0ZR6b3p4+iBFG9WYdC9YjL8HuXQiopV638J01pdjC1f RH1BTK+dL3dRD5RVqWYmpnmrw8dATc9stAS380pnCYgysBEgU+FzFOBQo4NWJtjcDWMg L2AkqDWtR806hq8VLyMwT6kur9AeBR9vTutOVL5tcO1mXN4x6P5Hg8NvnADq+yijBff3 E+aTeqwVm/QprSKW6GmJarOmyG6Eeo4T/gZXv1rrQfeuLRmUGWQ/aEcDhm2+tL2FxOel t8xchS1eey+NOQvi3mA0PoyCXOY7vH+J1VtT+9PbefnNcIwYdpWNlHwVh/76OdmFA/B5 wSwQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:reply-to:message-id:subject:cc:to:from:date; bh=Ht5EVKp4+8m2hrgZfZfsksLnpXP6dLe8omBC4wtul9k=; b=gcT5WRHdA58vqMNIvqXaMnFOO9BoUXZYn7/he5UzXSiS0SqyJWNgJCUCmTmD7fuGho wZpka9kwjHttm+J+leCBIq9x2oVELZ/KeBtrmQb5muIAfEV6Chdnra29HMPz6hkyUqdh y8zsUuzof5sdYEct14j7RsBWsm0j/0lS71ckx9gSMvznOuqrFhPC7XT1ydph8VBd36W3 g+g/1Ec+rQyW/XFykaQNEUu273whj3RjcqD6N2ZRITQD2KYe/mLNy45KJyt/BPpiQtXl Bj4zWxz8stunJc77AX/MNodOIgAp/NrD1pCNsEi0c9ZwlQDGBDWalc/8A1ev8/8u4Vei brvA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f21si5043843jav.132.2021.09.23.01.04.48; Thu, 23 Sep 2021 01:05:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235983AbhIWID5 (ORCPT + 99 others); Thu, 23 Sep 2021 04:03:57 -0400 Received: from mga14.intel.com ([192.55.52.115]:37798 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232634AbhIWICn (ORCPT ); Thu, 23 Sep 2021 04:02:43 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10115"; a="223434348" X-IronPort-AV: E=Sophos;i="5.85,316,1624345200"; d="asc'?scan'208";a="223434348" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Sep 2021 01:01:06 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.85,316,1624345200"; d="asc'?scan'208";a="550748427" Received: from zhen-hp.sh.intel.com (HELO zhen-hp) ([10.239.160.143]) by FMSMGA003.fm.intel.com with ESMTP; 23 Sep 2021 01:01:03 -0700 Date: Thu, 23 Sep 2021 15:36:59 +0800 From: Zhenyu Wang To: Jim Cromie Cc: jbaron@akamai.com, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, amd-gfx@lists.freedesktop.org, intel-gvt-dev@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, daniel@ffwll.ch Subject: Re: [PATCH v8 10/16] i915/gvt: remove spaces in pr_debug "gvt: core:" etc prefixes Message-ID: <20210923073659.GZ14689@zhen-hp.sh.intel.com> Reply-To: Zhenyu Wang References: <20210915163957.2949166-1-jim.cromie@gmail.com> <20210915163957.2949166-11-jim.cromie@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Bu8it7iiRSEf40bY" Content-Disposition: inline In-Reply-To: <20210915163957.2949166-11-jim.cromie@gmail.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --Bu8it7iiRSEf40bY Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2021.09.15 10:39:51 -0600, Jim Cromie wrote: > Taking embedded spaces out of existing prefixes makes them better > class-prefixes; simplifying the extra quoting needed otherwise: >=20 > $> echo format "^gvt: core:" +p >control >=20 > Dropping the internal spaces means any trailing space in a query will > more clearly terminate the prefix being searched for. >=20 > Consider a generic drm-debug example: >=20 > # turn off ATOMIC reports > echo format "^drm:atomic: " -p > control >=20 > # turn off all ATOMIC:* reports, including any sub-categories > echo format "^drm:atomic:" -p > control >=20 > # turn on ATOMIC:FAIL: reports > echo format "^drm:atomic:fail: " +p > control >=20 > Removing embedded spaces in the class-prefixes simplifies the > corresponding match-prefix. This means that "quoted" match-prefixes > are only needed when the trailing space is desired, in order to > exclude explicitly sub-categorized pr-debugs; in this example, > "drm:atomic:fail:". >=20 > RFC: maybe the prefix catenation should paste in the " " class-prefix > terminator explicitly. A pr_debug_() flavor could exclude the " ", > allowing ad-hoc sub-categorization by appending for example, "fail:" > to "drm:atomic:" without the default " " insertion. >=20 > Signed-off-by: Jim Cromie > --- > v8: > . fix patchwork CI warning > --- > drivers/gpu/drm/i915/gvt/debug.h | 18 +++++++++--------- > 1 file changed, 9 insertions(+), 9 deletions(-) >=20 > diff --git a/drivers/gpu/drm/i915/gvt/debug.h b/drivers/gpu/drm/i915/gvt/= debug.h > index c6027125c1ec..bbecc279e077 100644 > --- a/drivers/gpu/drm/i915/gvt/debug.h > +++ b/drivers/gpu/drm/i915/gvt/debug.h > @@ -36,30 +36,30 @@ do { \ > } while (0) > =20 > #define gvt_dbg_core(fmt, args...) \ > - pr_debug("gvt: core: "fmt, ##args) > + pr_debug("gvt:core: " fmt, ##args) > =20 > #define gvt_dbg_irq(fmt, args...) \ > - pr_debug("gvt: irq: "fmt, ##args) > + pr_debug("gvt:irq: " fmt, ##args) > =20 > #define gvt_dbg_mm(fmt, args...) \ > - pr_debug("gvt: mm: "fmt, ##args) > + pr_debug("gvt:mm: " fmt, ##args) > =20 > #define gvt_dbg_mmio(fmt, args...) \ > - pr_debug("gvt: mmio: "fmt, ##args) > + pr_debug("gvt:mmio: " fmt, ##args) > =20 > #define gvt_dbg_dpy(fmt, args...) \ > - pr_debug("gvt: dpy: "fmt, ##args) > + pr_debug("gvt:dpy: " fmt, ##args) > =20 > #define gvt_dbg_el(fmt, args...) \ > - pr_debug("gvt: el: "fmt, ##args) > + pr_debug("gvt:el: " fmt, ##args) > =20 > #define gvt_dbg_sched(fmt, args...) \ > - pr_debug("gvt: sched: "fmt, ##args) > + pr_debug("gvt:sched: " fmt, ##args) > =20 > #define gvt_dbg_render(fmt, args...) \ > - pr_debug("gvt: render: "fmt, ##args) > + pr_debug("gvt:render: " fmt, ##args) > =20 > #define gvt_dbg_cmd(fmt, args...) \ > - pr_debug("gvt: cmd: "fmt, ##args) > + pr_debug("gvt:cmd: " fmt, ##args) > =20 > #endif > --=20 Looks good to me. Thanks! Reviewed-by: Zhenyu Wang --Bu8it7iiRSEf40bY Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EARECAB0WIQTXuabgHDW6LPt9CICxBBozTXgYJwUCYUwulgAKCRCxBBozTXgY J8qzAJ9cfZulZLyzqg5hhI9G1fLDqKMDlQCgi+YapDkpvZuzya6guQeaCyf+Nps= =+ZKA -----END PGP SIGNATURE----- --Bu8it7iiRSEf40bY--