Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp780891ybt; Mon, 6 Jul 2020 23:33:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzIskWV2Ddv2YY0o5EOrjhB0scwz2TvLenjOW4v0axg6DDqU3qdN6/u0GwQ/pHg9lWZkA9P X-Received: by 2002:a17:906:b888:: with SMTP id hb8mr45800412ejb.124.1594103621495; Mon, 06 Jul 2020 23:33:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594103621; cv=none; d=google.com; s=arc-20160816; b=YOIXX1Z8TnCR2pw4lNt028erkNfFDT2wpjqTkzPnBHA4ZhTPW78LQZTwHubIVVbmIG RosRPJtubtg9qgwk4Qmg5nCAb4pr6WJY5LkmCmIoKvD2ZvNNcOBQzHbIcQ23SCIKY+eq Lgi3+cQEuB8QM9ZB6JBPq+d+yk8HMz3sv+2COapX/5OZUw8VE0EajAf5TztdlmLb/+nu YqVkb7tUXrVT/BbsCMowdcx9CunnIXRueznDcTsRri1UAQydTti2+mb6sBkQw85QzDSw g/l4sOYiLFTBCiSm2C6tcVWrPNXMdF/4ZN5QoNC+F+AIEWWLxNigEOvJcJB5htW+oWq6 I/KA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:references:message-id :content-transfer-encoding:cc:date:in-reply-to:from:subject :mime-version; bh=Xhj/aXL18Ft37oFrQ3p3VpWe/cQ2aJPOWAoxPRTzEKs=; b=GGrXh7Fm8PBHFBpZV7j4Gf//ZCO1YMXug+x2zLWp9DK2mzRZRH0ld+nhG6Q8TX2gf4 0ET98iEJUV/P6xZDu5RAB97jFVBYE+ldSck0egRUL+TmPRvo/lRqoHzoGGpY0RigHdUL DxgQXTeYlT4R+T9ekBPeAIT8l+PTQVl7gZW0opVzEd1Uw8kjTJRE6tPKAz4TI6GPlI7T FSAGsziu3F5KlioWfiJ337gJLluUkdQjtGoZRIpn44DIG4q2ekXdz6z9C/4m4cb+GxO7 gjFxCSu/2kumY/bu20/Zii7DyYIsMS1zp7klNXT5nOggp03X2P8mNyuoE/A//f3v4v80 jyqA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i26si14717063edv.525.2020.07.06.23.32.59; Mon, 06 Jul 2020 23:33:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth-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-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728025AbgGGGcz convert rfc822-to-8bit (ORCPT + 99 others); Tue, 7 Jul 2020 02:32:55 -0400 Received: from coyote.holtmann.net ([212.227.132.17]:47389 "EHLO mail.holtmann.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725825AbgGGGcy (ORCPT ); Tue, 7 Jul 2020 02:32:54 -0400 Received: from [192.168.1.91] (p5b3d2638.dip0.t-ipconnect.de [91.61.38.56]) by mail.holtmann.org (Postfix) with ESMTPSA id 08718CECE5; Tue, 7 Jul 2020 08:42:49 +0200 (CEST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.80.23.2.2\)) Subject: Re: [PATCH v1] Bluetooth: create CONFIG_BT_DEBUG_FUNC_NAME From: Marcel Holtmann In-Reply-To: <20200707003937.187125-1-alainm@chromium.org> Date: Tue, 7 Jul 2020 08:32:22 +0200 Cc: linux-bluetooth , Abhishek Pandit-Subedi Content-Transfer-Encoding: 8BIT Message-Id: <4B0E4627-26D8-4D70-ABE9-6CB7A9E86D35@holtmann.org> References: <20200707003937.187125-1-alainm@chromium.org> To: Alain Michaud X-Mailer: Apple Mail (2.3608.80.23.2.2) Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Hi Alain, > Creates a CONFIG_BT_DEBUG_FUNC_NAME option to include function names in > debug statements. > > Unlike other platforms __func__ isn't a string literal so it cannot be > automatically concatenated by the pre-processor. As a result, the > function name is passed as a parameter to the tracing function. Since > pr_debug is a function like macro, the normal expansion of BT_PREFIX_PARAM > does not work as it gets processed within the first parameter as well, > for this reason, BT_DBG is split into two versions. > > This patch was built tested with all 4 possible combinations of > CONFIG_BT_DEBUG_FUNC_NAME and CONFIG_BT_FEATURE_DEBUG configurations. can we please limit this to FEATURE_DEBUG since dynamic debug doesn’t need it. It can switch on function name debugging on a per debug statement. And even for FEATURE_DEBUG I would rather have it optional that can be enabled when needed via the experimental feature itself. Regards Marcel