Date: Mon, 18 May 2020 08:43:05 +0000 (UTC) From: Hans Petter Selasky <hselasky@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r361154 - stable/10/usr.sbin/bluetooth/hccontrol Message-ID: <202005180843.04I8h5VS037204@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: hselasky Date: Mon May 18 08:43:05 2020 New Revision: 361154 URL: https://svnweb.freebsd.org/changeset/base/361154 Log: MFC r360070: Add missing feature descriptions to hci_features2str(). The list of possible features in hccontrol/features2str() is incomplete. Refer to "Bluetooth Core Specification 5.2 Vol. 2 Part C. 3.3 Feature Mask Definition". Submitted by: Marc Veldman <marc@bumblingdork.com> PR: 245354 Sponsored by: Mellanox Technologies Modified: stable/10/usr.sbin/bluetooth/hccontrol/info.c stable/10/usr.sbin/bluetooth/hccontrol/link_control.c stable/10/usr.sbin/bluetooth/hccontrol/node.c stable/10/usr.sbin/bluetooth/hccontrol/util.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.sbin/bluetooth/hccontrol/info.c ============================================================================== --- stable/10/usr.sbin/bluetooth/hccontrol/info.c Mon May 18 08:42:10 2020 (r361153) +++ stable/10/usr.sbin/bluetooth/hccontrol/info.c Mon May 18 08:43:05 2020 (r361154) @@ -75,7 +75,7 @@ hci_read_local_supported_features(int s, int argc, cha { ng_hci_read_local_features_rp rp; int n; - char buffer[1024]; + char buffer[2048]; n = sizeof(rp); if (hci_simple_request(s, NG_HCI_OPCODE(NG_HCI_OGF_INFO, Modified: stable/10/usr.sbin/bluetooth/hccontrol/link_control.c ============================================================================== --- stable/10/usr.sbin/bluetooth/hccontrol/link_control.c Mon May 18 08:42:10 2020 (r361153) +++ stable/10/usr.sbin/bluetooth/hccontrol/link_control.c Mon May 18 08:43:05 2020 (r361154) @@ -609,7 +609,7 @@ hci_read_remote_supported_features(int s, int argc, ch char b[512]; ng_hci_read_remote_features_cp cp; ng_hci_event_pkt_t *e = (ng_hci_event_pkt_t *) b; - char buffer[1024]; + char buffer[2048]; /* parse command parameters */ switch (argc) { Modified: stable/10/usr.sbin/bluetooth/hccontrol/node.c ============================================================================== --- stable/10/usr.sbin/bluetooth/hccontrol/node.c Mon May 18 08:42:10 2020 (r361153) +++ stable/10/usr.sbin/bluetooth/hccontrol/node.c Mon May 18 08:43:05 2020 (r361154) @@ -150,7 +150,7 @@ hci_read_node_features(int s, int argc, char **argv) { struct ng_btsocket_hci_raw_node_features r; int n; - char buffer[1024]; + char buffer[2048]; memset(&r, 0, sizeof(r)); if (ioctl(s, SIOC_HCI_RAW_NODE_GET_FEATURES, &r, sizeof(r)) < 0) Modified: stable/10/usr.sbin/bluetooth/hccontrol/util.c ============================================================================== --- stable/10/usr.sbin/bluetooth/hccontrol/util.c Mon May 18 08:42:10 2020 (r361153) +++ stable/10/usr.sbin/bluetooth/hccontrol/util.c Mon May 18 08:43:05 2020 (r361154) @@ -276,7 +276,57 @@ hci_features2str(uint8_t *features, char *buffer, int /* 4 */ "<Flow control lag (bit0)> ", /* 5 */ "<Flow control lag (bit1)> ", /* 6 */ "<Flow control lag (bit2)> ", - /* 7 */ "<Unknown2.7> " + /* 7 */ "<Broadcast Encryption> " + }, + { /* byte 3 */ + /* 0 */ "<Unknown 3.0> ", + /* 1 */ "<EDR ACL 2 Mb/s> ", + /* 2 */ "<EDR ACL 3 Mb/s> ", + /* 3 */ "<Enhanced inquiry scan> ", + /* 4 */ "<Interlaced inquiry scan> ", + /* 5 */ "<Interlaced page scan> ", + /* 6 */ "<RSSI with inquiry results> ", + /* 7 */ "<Extended SCO link (EV3 packets)> " + }, + { /* byte 4 */ + /* 0 */ "<EV4 packets> ", + /* 1 */ "<EV5 packets> ", + /* 2 */ "<Unknown 4.2> ", + /* 3 */ "<AFH capable slave> ", + /* 4 */ "<AFH classification slave> ", + /* 5 */ "<BR/EDR Not Supported> ", + /* 6 */ "<LE Supported (Controller)> ", + /* 7 */ "<3-Slot EDR ACL packets> " + }, + { /* byte 5 */ + /* 0 */ "<5-Slot EDR ACL packets> ", + /* 1 */ "<Sniff subrating> ", + /* 2 */ "<Pause encryption> ", + /* 3 */ "<AFH capable master> ", + /* 4 */ "<AFH classification master> ", + /* 5 */ "<EDR eSCO 2 Mb/s mode> ", + /* 6 */ "<EDR eSCO 3 Mb/s mode> ", + /* 7 */ "<3-Slot EDR eSCO packets> " + }, + { /* byte 6 */ + /* 0 */ "<Enhanced Inquiry Response> ", + /* 1 */ "<Simultaneous LE and BR/EDR (Controller)> ", + /* 2 */ "<Unknown 6.2> ", + /* 3 */ "<Secure Simple Pairing (Controller Support)> ", + /* 4 */ "<Encapsulated PDU> ", + /* 5 */ "<Erroneous Data Reporting> ", + /* 6 */ "<Non-flushable Packed Boundary Flag> ", + /* 7 */ "<Unknown 6.7> " + }, + { /* byte 7 */ + /* 0 */ "<HCI_Link_Supervision_Timeout_Changed event> ", + /* 1 */ "<Variable Inquiry TX Power Level> ", + /* 2 */ "<Enhanced Power Control> ", + /* 3 */ "<Unknown 7.3> ", + /* 4 */ "<Unknown 7.4> ", + /* 5 */ "<Unknown 7.5> ", + /* 6 */ "<Unknown 7.6> ", + /* 7 */ "<Extended features> " }}; if (buffer != NULL && size > 0) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202005180843.04I8h5VS037204>