Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp984225ybt; Fri, 19 Jun 2020 20:32:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzIf9pfPPgfXOfY/DWtSkZ8yeiqU0hYH+fnYNj/+X9Xp3tPcAUfhwJAyVg45qGXsYFqyDBH X-Received: by 2002:a50:f393:: with SMTP id g19mr5050874edm.283.1592623967884; Fri, 19 Jun 2020 20:32:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592623967; cv=none; d=google.com; s=arc-20160816; b=sF6mkRqaAPaD4APS/bfuQdLazSFCNhXf4wtl1QwxFHAM35C6kdxqYGjtDfrHnw/zNO AGMDTw6sMSau5KUX7o02EPdmiVBtj11y7NsUP7W8hL/L+Esn8W4K6+rxC8RWr6ZZdF2M ZAjP7X3b3RVaSlbIEQWg2LnPlF74yJY+/KEQZqZZDc/SGYhht4zCQ1GSFNyJsgWJz9KE cqLc7k5QBAPv4DQ98/a8vwTWq8Kr1wABJNO97dDIQbuOR6tbigt/4VegNaMryu2bbMN7 SYbrlSVO0GWRYcxiJqOyqSBrh7/aGhKMWKRlxZKMQxCiWJX/avPSyvcdbwdUjVz6YReA FPlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=7CxRloMUzMzHtMYCAIVGIDg2K8kW9NS7Ez3DjXqAktk=; b=dUpYfeJS357Qp4maKDpHuH8xcMlxIPWPnlM+EiLqssLdweC6j7Pa1deTSfs6bzm/3c CIW8aK5+TDMUiDl1RXVbLIyaG4KkcWCDxPh8/W8KL8lBU8ydlRh6mUekt9L+hTgnukBh 8hJvMF/GxXXAf1yu1MhvT/lZSsDEAj7zG1ap8nChRp/tSlB0Jsqw2PKHaN6s/fTCapNV /tqX4jR4aBBXCp7Yh7sQRCnnBeGuL6M51rn8/E7yXNPrCKg74Esb0DxgUFmwU/i0T0R/ MYDD4MVbFC1ToMv/y7ih6TMduzfacUjZxFU109W2fNdFt/9j9zvAVc+q7INr5gU+qDhS YFVA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@akamai.com header.s=jan2016.eng header.b=ErWRNWuZ; 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=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=akamai.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y21si4858324edt.501.2020.06.19.20.32.25; Fri, 19 Jun 2020 20:32:47 -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; dkim=pass header.i=@akamai.com header.s=jan2016.eng header.b=ErWRNWuZ; 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=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=akamai.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2394314AbgFSQKW (ORCPT + 99 others); Fri, 19 Jun 2020 12:10:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38254 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2392921AbgFSQKR (ORCPT ); Fri, 19 Jun 2020 12:10:17 -0400 Received: from mx0b-00190b01.pphosted.com (mx0b-00190b01.pphosted.com [IPv6:2620:100:9005:57f::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9AF1EC06174E; Fri, 19 Jun 2020 09:10:17 -0700 (PDT) Received: from pps.filterd (m0122330.ppops.net [127.0.0.1]) by mx0b-00190b01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 05JG2QZa021248; Fri, 19 Jun 2020 17:07:55 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=akamai.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=jan2016.eng; bh=7CxRloMUzMzHtMYCAIVGIDg2K8kW9NS7Ez3DjXqAktk=; b=ErWRNWuZtlY60K2Le5us949BReegtvr7yjcy84NTOJPVRJ/s0ap065bNIvCItRkefDNG F4RVJ/PR/ZGPa06n/h+eeIzg9MVN3Bd8rZdhA3TEe2QqE+MAf4hJmYTevF0dcQpljAUt diHMpTzK/GzZlA7EclyixCNnPJ89oEQ+C6rBgystmYM2exlZFlA+G3o6fLnhNxs+RzUC 0Ulhuwch+yr1M2Q5dlWpsYCTJfSfKDv91f+LSVJxmZVQeFZFu6rh8IfU9biM9Rkiagxj Sn7gYn1j3wzhyzP7El+TgZowv9WXe2BLfLad9ldYTFcB4V2Mxh0O/cCM72tGdRx2zU3d BA== Received: from prod-mail-ppoint1 (prod-mail-ppoint1.akamai.com [184.51.33.18] (may be forged)) by mx0b-00190b01.pphosted.com with ESMTP id 31qrebsgw5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 19 Jun 2020 17:07:54 +0100 Received: from pps.filterd (prod-mail-ppoint1.akamai.com [127.0.0.1]) by prod-mail-ppoint1.akamai.com (8.16.0.42/8.16.0.42) with SMTP id 05JG5VvO011524; Fri, 19 Jun 2020 12:07:54 -0400 Received: from prod-mail-relay10.akamai.com ([172.27.118.251]) by prod-mail-ppoint1.akamai.com with ESMTP id 31qjmbvqx3-1; Fri, 19 Jun 2020 12:07:54 -0400 Received: from [0.0.0.0] (prod-ssh-gw01.bos01.corp.akamai.com [172.27.119.138]) by prod-mail-relay10.akamai.com (Postfix) with ESMTP id AE3853A60B; Fri, 19 Jun 2020 16:07:53 +0000 (GMT) Subject: Re: [PATCH v3 20/21] dyndbg: add user-flag, negating-flags, and filtering on flags To: jim.cromie@gmail.com, Stanimir Varbanov Cc: Petr Mladek , LKML , akpm@linuxfoundation.org, Greg KH , Rasmus Villemoes , Jonathan Corbet , Andrew Morton , Will Deacon , Orson Zhai , Linux Documentation List , Joe Perches References: <20200617162536.611386-1-jim.cromie@gmail.com> <20200617162536.611386-23-jim.cromie@gmail.com> <20200618161912.GD3617@alley> <20200618174058.GE3617@alley> <746984fb-00ee-9079-efac-50167f3c3e40@akamai.com> <172c0580-279f-aa3e-817a-4216067bea10@akamai.com> <23396523-28c3-74e6-3e62-be68e5a5465a@linaro.org> From: Jason Baron Message-ID: Date: Fri, 19 Jun 2020 12:07:53 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.216,18.0.687 definitions=2020-06-19_16:2020-06-19,2020-06-19 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 malwarescore=0 bulkscore=0 adultscore=0 mlxlogscore=999 mlxscore=0 phishscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2004280000 definitions=main-2006190118 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.216,18.0.687 definitions=2020-06-19_16:2020-06-19,2020-06-19 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 suspectscore=0 adultscore=0 spamscore=0 cotscore=-2147483648 malwarescore=0 phishscore=0 mlxlogscore=999 bulkscore=0 lowpriorityscore=0 priorityscore=1501 impostorscore=0 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2004280000 definitions=main-2006190117 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/18/20 6:48 PM, jim.cromie@gmail.com wrote: > On Thu, Jun 18, 2020 at 4:34 PM Stanimir Varbanov > wrote: >> >> Hi Jason, Jim, >> > > > >>> I would be curious to see what Stanimir thinks of this proposal >>> and whether it would work for his venus driver, which is what >>> prompted this module group discussion. >> >> Hmm, we spin in a circle :) >> >> Infact this was my first way of implementing the groups in Venus driver, >> you can see it at [1]. >> >> +#define VDBGL(fmt, args...) pr_debug("VENUSL: " fmt, ##args) >> +#define VDBGM(fmt, args...) pr_debug("VENUSM: " fmt, ##args) >> +#define VDBGH(fmt, args...) pr_debug("VENUSH: " fmt, ##args) >> +#define VDBGFW(fmt, args...) pr_debug("VENUSFW: " fmt, ##args) >> > > I recall :-) > > I think Greg K-Hs distaste for those defines was for using them, > as it tosses the utility of grep pr_debug > > pr_debug("VENUSM:" > is barely longer than > VDBGM > > with ddebug_exec_queries, you can leverage the existing format. > >> Ok, yes, I like this approach because its simple (just exports ddebug_exec_queries()), and it seems to be quite flexible. Module authors can 'tag' their queries any way they want. We could provide some structure, if desired, something like: #define DYNAMIC_DEBUG_LOW "-V " #define DYNAMIC_DEBUG_MED "-VV " #define DYNAMIC_DEBUG_HIGH "-VVV " #define DYNAMIC_DEBUG_REALLY_HIGH "-VVVV " And then these could be added to the pr_debug() so: #define VDBGL(fmt, args...) pr_debug("VENUSL: " DYNAMIC_DEBUG_LOW fmt, ##args) or #define VDBGL(fmt, args...) pr_debug(DYNAMIC_DEBUG_LOW fmt, ##args) or just: pr_debug(DYNAMIC_DEBUG_LOW "ERROR HERE: %d", err) Thanks, -Jason >> [1] https://urldefense.proofpoint.com/v2/url?u=https-3A__lkml.org_lkml_2020_5_21_668&d=DwIBaQ&c=96ZbZZcaMF4w0F4jpN6LZg&r=1fLh1mlLqbfetnnGsbwXfpwmGlG4m83mXgtV4vZ1B1A&m=29UzIGELhVL1znJsgyjGDKGIEdSkSlCsmAh0jpbWHVQ&s=_szr6DQOsbdQ-oYCR9-fs4b-XG_fotTiObUfG3z6UtY&e= >> >> -- >> regards, >> Stan > > thanks > Jim >