From: Tedd Ho-Jeong An <hj.tedd.an@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: [BlueZ v3] monitor: Add Intel read supported features command
Date: Mon, 19 Apr 2021 11:21:49 -0700 [thread overview]
Message-ID: <20210419182149.712000-1-hj.tedd.an@gmail.com> (raw)
From: Tedd Ho-Jeong An <tedd.an@intel.com>
< HCI Command: Intel Read Supported Features (0x3f|0x00a6) plen 1
Page: 0x01
> HCI Event: Command Complete (0x0e) plen 22
Intel Read Supported Features (0x3f|0x00a6) ncmd 1
Status: Success (0x00)
Page: 0x01
Max Pages: 0x02
Supported Features:
1f 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
---
monitor/intel.c | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
diff --git a/monitor/intel.c b/monitor/intel.c
index 18840f3e7..d2aefa6a8 100644
--- a/monitor/intel.c
+++ b/monitor/intel.c
@@ -471,6 +471,26 @@ static void memory_write_cmd(const void *data, uint8_t size)
packet_hexdump(data + 6, size - 6);
}
+static void read_supported_features_cmd(const void *data, uint8_t size)
+{
+ uint8_t page = get_u8(data);
+
+ print_field("Page: 0x%2.2x", page);
+}
+
+static void read_supported_features_rsp(const void *data, uint8_t size)
+{
+ uint8_t status = get_u8(data);
+ uint8_t page = get_u8(data + 1);
+ uint8_t max_pages = get_u8(data + 2);
+
+ print_status(status);
+ print_field("Page: 0x%2.2x", page);
+ print_field("Max Pages: 0x%2.2x", max_pages);
+ print_field("Supported Features:");
+ packet_hexdump(data + 3, size - 3);
+}
+
static const struct vendor_ocf vendor_ocf_table[] = {
{ 0x001, "Reset",
reset_cmd, 8, true,
@@ -533,6 +553,10 @@ static const struct vendor_ocf vendor_ocf_table[] = {
{ 0x08e, "Memory Write",
memory_write_cmd, 6, false,
status_rsp, 1, true },
+ { 0x0a6, "Read Supported Features",
+ read_supported_features_cmd, 1, true,
+ read_supported_features_rsp, 19, true },
+
{ }
};
--
2.25.1
next reply other threads:[~2021-04-19 18:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-19 18:21 Tedd Ho-Jeong An [this message]
2021-04-19 18:51 ` [BlueZ,v3] monitor: Add Intel read supported features command bluez.test.bot
2021-04-20 22:17 ` Luiz Augusto von Dentz
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=20210419182149.712000-1-hj.tedd.an@gmail.com \
--to=hj.tedd.an@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