From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: [PATCH BlueZ v2 9/9] device: Don't use DBG in gatt_debug
Date: Tue, 22 Mar 2022 17:06:54 -0700 [thread overview]
Message-ID: <20220323000654.3157833-9-luiz.dentz@gmail.com> (raw)
In-Reply-To: <20220323000654.3157833-1-luiz.dentz@gmail.com>
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
gatt_debug callback is used to print debug strings from bt_att which
includes the file and function names so using DBG would add yet another
set of file and function prefixes which makes the logs confusing.
---
src/device.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/device.c b/src/device.c
index 3992f9a0c..860155b6e 100644
--- a/src/device.c
+++ b/src/device.c
@@ -5545,7 +5545,8 @@ static void gatt_client_service_changed(uint16_t start_handle,
static void gatt_debug(const char *str, void *user_data)
{
- DBG("%s", str);
+ if (DBG_IS_ENABLED())
+ btd_debug(0xffff, "%s", str);
}
static void gatt_client_init(struct btd_device *device)
--
2.35.1
next prev parent reply other threads:[~2022-03-23 0:07 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-23 0:06 [PATCH BlueZ v2 1/9] log: Introduce DBG_IS_ENABLED Luiz Augusto von Dentz
2022-03-23 0:06 ` [PATCH BlueZ v2 2/9] mgmt: Add DBG macro Luiz Augusto von Dentz
2022-03-23 0:06 ` [PATCH BlueZ v2 3/9] mgmt: Introduce mgmt_set_verbose Luiz Augusto von Dentz
2022-03-23 0:06 ` [PATCH BlueZ v2 4/9] adapter: Don't use DBG in mgmt_debug Luiz Augusto von Dentz
2022-03-23 10:37 ` Marcel Holtmann
2022-03-23 19:58 ` Luiz Augusto von Dentz
2022-03-25 14:52 ` Marcel Holtmann
2022-03-23 0:06 ` [PATCH BlueZ v2 5/9] att: Log file and function names Luiz Augusto von Dentz
2022-03-23 0:06 ` [PATCH BlueZ v2 6/9] gatt-client: Add DBG macro Luiz Augusto von Dentz
2022-03-23 0:06 ` [PATCH BlueZ v2 7/9] gatt-server: " Luiz Augusto von Dentz
2022-03-23 0:06 ` [PATCH BlueZ v2 8/9] att: Rename att_debug and att_verbose to DBG and VERBOSE Luiz Augusto von Dentz
2022-03-23 0:06 ` Luiz Augusto von Dentz [this message]
2022-03-23 6:02 ` [BlueZ,v2,1/9] log: Introduce DBG_IS_ENABLED bluez.test.bot
2022-03-23 10:35 ` [PATCH BlueZ v2 1/9] " Marcel Holtmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220323000654.3157833-9-luiz.dentz@gmail.com \
--to=luiz.dentz@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox