[bluez/bluez] 53c28e: monitor/att: Simplify CCC decoders

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



  Branch: refs/heads/master
  Home:   https://github.com/bluez/bluez
  Commit: 53c28e3d868396fe5676751a44171dd67a7255a0
      https://github.com/bluez/bluez/commit/53c28e3d868396fe5676751a44171dd67a7255a0
  Author: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
  Date:   2022-05-26 (Thu, 26 May 2022)

  Changed paths:
    M monitor/att.c

  Log Message:
  -----------
  monitor/att: Simplify CCC decoders

This simplify callbacks moving the decoding of the value to
print_ccc_value.


  Commit: 13bdb9f3bee1763143ec5af4db3bb4e213261fe7
      https://github.com/bluez/bluez/commit/13bdb9f3bee1763143ec5af4db3bb4e213261fe7
  Author: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
  Date:   2022-05-26 (Thu, 26 May 2022)

  Changed paths:
    M monitor/att.c
    M monitor/l2cap.h
    M monitor/packet.c
    M monitor/packet.h

  Log Message:
  -----------
  monitor/att: Add decoding support for PAC Sink/Source

This adds decoding support for PAC Sink/Source attributes:

 < ACL Data TX: Handle 42 flags 0x00 dlen 9
      Channel: 64 len 5 sdu 3 [PSM 39 mode Enhanced Credit (0x81)]
      {chan 0}
      ATT: Read Request (0x0a) len 2
        Handle: 0x0017 Type: Sink PAC (0x2bc9)
> ACL Data RX: Handle 42 flags 0x02 dlen 31
      Channel: 65 len 27 sdu 25 [PSM 39 mode Enhanced Credit (0x81)]
      {chan 0}
        Value: 010600000000100301ff0002020302030305041e00f00000
          Number of PAC(s): 1
          PAC #0:
            Codec: LC3 (0x06)
            Codec Specific Configuration #0: len 0x03 type 0x01
            Codec Specific Configuration: ff00
            Codec Specific Configuration #1: len 0x02 type 0x02
            Codec Specific Configuration: 03
            Codec Specific Configuration #2: len 0x02 type 0x03
            Codec Specific Configuration: 03
            Codec Specific Configuration #3: len 0x05 type 0x04
            Codec Specific Configuration: 1e00f000


  Commit: ba32b25a61eb75277cedc1fea7ed5d35fd1e726e
      https://github.com/bluez/bluez/commit/ba32b25a61eb75277cedc1fea7ed5d35fd1e726e
  Author: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
  Date:   2022-05-26 (Thu, 26 May 2022)

  Changed paths:
    M lib/bluetooth.h
    M monitor/att.c
    M monitor/l2cap.h

  Log Message:
  -----------
  monitor/att: Add decoding support for ASE Sink/Source

This adds decoding support for ASE Sink/Source attributes:

> ACL Data RX: Handle 42 flags 0x02 dlen 9
      Channel: 65 len 5 sdu 3 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Read Request (0x0a) len 2
        Handle: 0x002a Type: Sink ASE (0x2bc4)
< ACL Data TX: Handle 42 flags 0x00 dlen 9
      Channel: 64 len 5 sdu 3 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Read Response (0x0b) len 2
        Value: 0300
            ASE ID: 1
            State: Idle (0x00)
< ACL Data TX: Handle 42 flags 0x00 dlen 55
      Channel: 64 len 51 sdu 49 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Handle Multiple Value Notification (0x23) len 48
        Length: 0x0023
        Handle: 0x0024 Type: Sink ASE (0x2bc4)
          Data: 01010000000a00204e00409c00204e00409c0006000000000a02010302020103042800
            ASE ID: 1
            State: Codec Configured (0x01)
            Framing: Unframed PDUs supported (0x00)
            PHY: 0x00
            RTN: 0
            Max Transport Latency: 10
            Presentation Delay Min: 20000 us
            Presentation Delay Max: 40000 us
            Preferred Presentation Delay Min: 20000 us
            Preferred Presentation Delay Max: 40000 us
            Codec: LC3 (0x06)
            Codec Specific Configuration #0: len 0x02 type 0x01
            Codec Specific Configuration: 03
            Codec Specific Configuration #1: len 0x02 type 0x02
            Codec Specific Configuration: 01
            Codec Specific Configuration #2: len 0x03 type 0x04
            Codec Specific Configuration: 2800
< ACL Data TX: Handle 42 flags 0x00 dlen 37
      Channel: 64 len 33 sdu 31 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Handle Multiple Value Notification (0x23) len 30
        Length: 0x0011
        Handle: 0x0024 Type: Sink ASE (0x2bc4)
          Data: 0102000010270000022800020a00409c00
            ASE ID: 1
            State: QoS Configured (0x02)
            CIG ID: 0x00
            CIS ID: 0x00
            SDU Interval: 10000 usec
            Framing: Unframed (0x00)
            PHY: 0x02
            LE 2M PHY (0x02)
            Max SDU: 40
            RTN: 2
            Max Transport Latency: 10
            Presentation Delay: 40000 us
< ACL Data TX: Handle 42 flags 0x00 dlen 33
      Channel: 64 len 29 sdu 27 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Handle Multiple Value Notification (0x23) len 26
        Length: 0x000d
        Handle: 0x002a Type: Source ASE (0x2bc5)
          Data: 03030000060304030202000000
            ASE ID: 3
            State: Enabling (0x03)
            CIG ID: 0x00
            CIS ID: 0x00
            Metadata #0: len 0x03 type 0x04
            Metadata: 0302
            Metadata #1: len 0x02 type 0x00
< ACL Data TX: Handle 42 flags 0x00 dlen 39
      Channel: 64 len 35 sdu 33 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Handle Multiple Value Notification (0x23) len 32
        Length: 0x000d
        Handle: 0x002a Type: Source ASE (0x2bc5)
          Data: 03040000060304030202000000
            ASE ID: 3
            State: Streaming (0x04)
            CIG ID: 0x00
            CIS ID: 0x00
            Metadata #0: len 0x03 type 0x04
            Metadata: 0302
            Metadata #1: len 0x02 type 0x00
< ACL Data TX: Handle 42 flags 0x00 dlen 33
      Channel: 64 len 29 sdu 27 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Handle Multiple Value Notification (0x23) len 26
        Length: 0x000d
        Handle: 0x002a Type: Source ASE (0x2bc5)
          Data: 03050000060304030202000000
            ASE ID: 3
            State: Disabling (0x05)
            CIG ID: 0x00
            CIS ID: 0x00
            Metadata #0: len 0x03 type 0x04
            Metadata: 0302
            Metadata #1: len 0x02 type 0x00


  Commit: 21f65f7b2fca8201291bc5b630d3c20e209d515d
      https://github.com/bluez/bluez/commit/21f65f7b2fca8201291bc5b630d3c20e209d515d
  Author: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
  Date:   2022-05-26 (Thu, 26 May 2022)

  Changed paths:
    M monitor/att.c

  Log Message:
  -----------
  monitor/att: Add decoding support for ASE Control Point

This adds decoding support for ASE Control Point attribute:

> ACL Data RX: Handle 42 flags 0x02 dlen 30
      Channel: 64 len 26 sdu 24 [PSM 39 mode Enhanced Credit (0x81)] {chan 1}
      ATT: Write Command (0x52) len 23
        Handle: 0x0030 Type: ASE Control Point (0x2bc6)
          Data: 010103020206000000000a02010302020103042800
            Opcode: Codec Configuration (0x01)
            Number of ASE(s): 1
            ASE: #0
            ASE ID: 0x03
            Target Latency: Balance Latency/Reliability (0x02)
            PHY: 0x02
            LE 2M PHY (0x02)
            Codec: LC3 (0x06)
            Codec Specific Configuration #0: len 0x02 type 0x01
            Codec Specific Configuration: 03
            Codec Specific Configuration #1: len 0x02 type 0x02
            Codec Specific Configuration: 01
            Codec Specific Configuration #2: len 0x03 type 0x04
            Codec Specific Configuration: 2800
< ACL Data TX: Handle 42 flags 0x00 dlen 55
      Channel: 64 len 51 sdu 49 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Handle Multiple Value Notification (0x23) len 48
        Length: 0x0005
        Handle: 0x0030 Type: ASE Control Point (0x2bc6)
          Data: 0101030000
            Opcode: Codec Configuration (0x01)
            Number of ASE(s): 1
            ASE: #0
            ASE ID: 0x03
            ASE Response Code: Success (0x00)
            ASE Response Reason: None (0x00)
> ACL Data RX: Handle 42 flags 0x02 dlen 27
      Channel: 64 len 23 sdu 21 [PSM 39 mode Enhanced Credit (0x81)] {chan 1}
      ATT: Write Command (0x52) len 20
        Handle: 0x0030 Type: ASE Control Point (0x2bc6)
          Data: 020103000010270000022800020a00409c00
            Opcode: QoS Configuration (0x02)
            Number of ASE(s): 1
            ASE: #0
            ASE ID: 0x03
            CIG ID: 0x00
            CIS ID: 0x00
            SDU Interval: 10000 usec
            Framing: Unframed (0x00)
            PHY: 0x02
            LE 2M PHY (0x02)
            Max SDU: 40
            RTN: 2
            Max Transport Latency: 10
            Presentation Delay: 40000 us
< ACL Data TX: Handle 42 flags 0x00 dlen 37
      Channel: 64 len 33 sdu 31 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Handle Multiple Value Notification (0x23) len 30
        Length: 0x0005
        Handle: 0x0030 Type: ASE Control Point (0x2bc6)
          Data: 0201030000
            Opcode: QoS Configuration (0x02)
            Number of ASE(s): 1
            ASE: #0
            ASE ID: 0x03
            ASE Response Code: Success (0x00)
            ASE Response Reason: None (0x00)
> ACL Data RX: Handle 42 flags 0x02 dlen 17
      Channel: 64 len 13 sdu 11 [PSM 39 mode Enhanced Credit (0x81)] {chan 1}
      ATT: Write Command (0x52) len 10
        Handle: 0x0030 Type: ASE Control Point (0x2bc6)
          Data: 0301030403020200
            Opcode: Enable (0x03)
            Number of ASE(s): 1
            ASE: #0
            ASE ID: 0x03
            Metadata #0: len 0x03 type 0x02
            Metadata: 0200
< ACL Data TX: Handle 42 flags 0x00 dlen 33
      Channel: 64 len 29 sdu 27 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Handle Multiple Value Notification (0x23) len 26
        Length: 0x0005
        Handle: 0x0030 Type: ASE Control Point (0x2bc6)
          Data: 0301030000
            Opcode: Enable (0x03)
            Number of ASE(s): 1
            ASE: #0
            ASE ID: 0x03
            ASE Response Code: Success (0x00)
            ASE Response Reason: None (0x00)
> ACL Data RX: Handle 42 flags 0x02 dlen 12
      Channel: 64 len 8 sdu 6 [PSM 39 mode Enhanced Credit (0x81)] {chan 0}
      ATT: Write Command (0x52) len 5
        Handle: 0x0030 Type: ASE Control Point (0x2bc6)
          Data: 050101
            Opcode: Disable (0x05)
            Number of ASE(s): 1


  Commit: b4233bca181580800b483a228ca5377efcfeb844
      https://github.com/bluez/bluez/commit/b4233bca181580800b483a228ca5377efcfeb844
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M client/gatt.c

  Log Message:
  -----------
  client/gatt: Fix memory leak issues

While performing the static tool analysis using coverity tool
found following reports

Error: RESOURCE_LEAK (CWE-772):
bluez-5.64/client/gatt.c:1531: leaked_storage: Variable "service"
going out of scope leaks the storage it points to.

Error: RESOURCE_LEAK (CWE-772):
bluez-5.64/client/gatt.c:2626: leaked_storage: Variable "chrc"
going out of scope leaks the storage it points to.

Error: RESOURCE_LEAK (CWE-772):
bluez-5.64/client/gatt.c:2906: leaked_storage: Variable "desc"
going out of scope leaks the storage it points to.


  Commit: 5eb96b3ec8545047a74d7204664267c7aa749070
      https://github.com/bluez/bluez/commit/5eb96b3ec8545047a74d7204664267c7aa749070
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M mesh/appkey.c

  Log Message:
  -----------
  mesh/appkey: Fix memory leaks

While performing the static analysis using the coverity tool found
following memory leak reports

bluez-5.64/mesh/appkey.c:143: leaked_storage: Variable "key" going
out of scope leaks the storage it points to.

Error: RESOURCE_LEAK (CWE-772):
bluez-5.64/mesh/appkey.c:146: leaked_storage: Variable "key" going
out of scope leaks the storage it points to.


  Commit: 6f02010ce0043ec2e17eb15f2a1dd42f6c64e223
      https://github.com/bluez/bluez/commit/6f02010ce0043ec2e17eb15f2a1dd42f6c64e223
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M monitor/jlink.c

  Log Message:
  -----------
  monitor: Fix memory leaks

While performing static tool analysis using coverity
found following reports for resouse leak

bluez-5.64/monitor/jlink.c:111: leaked_storage: Variable "so"
going out of scope leaks the storage it points to.

bluez-5.64/monitor/jlink.c:113: leaked_storage: Variable "so"
going out of scope leaks the storage it points to.


  Commit: fc57aa92a4f32f7c0f38198e6d26b529b537a047
      https://github.com/bluez/bluez/commit/fc57aa92a4f32f7c0f38198e6d26b529b537a047
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M plugins/sixaxis.c

  Log Message:
  -----------
  sixaxis: Fix memory leaks

While performing static tool analysis using coverity
found following reports for resouse leak

bluez-5.64/plugins/sixaxis.c:425: alloc_arg:
"get_pairing_type_for_device" allocates memory that is
stored into "sysfs_path".

bluez-5.64/plugins/sixaxis.c:428: leaked_storage: Variable "sysfs_path"
going out of scope leaks the storage it points to.


  Commit: f4743109f381a4d53b476c5b77c7c68a6aa40b59
      https://github.com/bluez/bluez/commit/f4743109f381a4d53b476c5b77c7c68a6aa40b59
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M tools/cltest.c

  Log Message:
  -----------
  cltest: Fix leaked_handle

While performing static tool analysis using coverity found
following reports for resouse leak

bluez-5.64/tools/cltest.c:75: leaked_handle: Handle variable "fd"
going out of scope leaks the handle.


  Commit: 4ae130455b173650f564d92f7908a7ca4f7b1ee6
      https://github.com/bluez/bluez/commit/4ae130455b173650f564d92f7908a7ca4f7b1ee6
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M tools/create-image.c

  Log Message:
  -----------
  create-image: Fix leaked_handle

While performing static tool analysis using coverity found following
reports for resouse leak

bluez-5.64/tools/create-image.c:124: leaked_storage: Variable "map"
going out of scope leaks the storage it points to.


  Commit: 4334be027ae1ad50193025c90e77a76b64464b53
      https://github.com/bluez/bluez/commit/4334be027ae1ad50193025c90e77a76b64464b53
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M tools/l2cap-tester.c

  Log Message:
  -----------
  l2cap-tester: Fix leaked_handle

While performing static tool analysis using coverity found following
reports for resouse leak

bluez-5.64/tools/l2cap-tester.c:1712: leaked_handle: Handle variable
"new_sk" going out of scope leaks the handle.


  Commit: 35cbfd9660949fca23418bfa32fd51d81ed91208
      https://github.com/bluez/bluez/commit/35cbfd9660949fca23418bfa32fd51d81ed91208
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M tools/mesh/mesh-db.c

  Log Message:
  -----------
  mesh/mesh-db: Fix resource leaks

While performing static tool analysis using coverity found following
reports for resouse leak

bluez-5.64/tools/mesh/mesh-db.c:2388: leaked_handle: Handle variable
"fd" going out of scope leaks the handle.

bluez-5.64/tools/mesh/mesh-db.c:2388: leaked_storage: Variable "str"
going out of scope leaks the storage it points to.


  Commit: 39b638526d9a45d54d2d6e3f175fd7eb057ef8f0
      https://github.com/bluez/bluez/commit/39b638526d9a45d54d2d6e3f175fd7eb057ef8f0
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M tools/obex-client-tool.c

  Log Message:
  -----------
  obex-client: Fix leaked_handle

While performing static tool analysis using coverity found following
reports for resouse leak

bluez-5.64/tools/obex-client-tool.c:315: leaked_handle: Handle variable
"sk" going out of scope leaks the handle.


  Commit: 06d3c7429ad6bdf6eef1bcedee327e74a33c40bf
      https://github.com/bluez/bluez/commit/06d3c7429ad6bdf6eef1bcedee327e74a33c40bf
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M obexd/client/pbap.c

  Log Message:
  -----------
  pbap: Fix memory leak

Reported by coverity tool as follows:

bluez-5.64/obexd/client/pbap.c:929: leaked_storage: Variable "apparam"
going out of scope leaks the storage it points to.


  Commit: 56bda20ce9e3e5c4684b37cffd4527264c2b4c1e
      https://github.com/bluez/bluez/commit/56bda20ce9e3e5c4684b37cffd4527264c2b4c1e
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M tools/meshctl.c

  Log Message:
  -----------
  meshctl: Fix possible use_after_free

Reported by coverity tool as follows :

bluez-5.64/tools/meshctl.c:1968: freed_arg: "g_free" frees "mesh_dir".

bluez-5.64/tools/meshctl.c:2018: double_free: Calling "g_free" frees
pointer "mesh_dir" which has already been freed.


  Commit: 5cdaeaefc350ea3c42719284b88406579d032fb6
      https://github.com/bluez/bluez/commit/5cdaeaefc350ea3c42719284b88406579d032fb6
  Author: Gopal Tiwari <gtiwari@xxxxxxxxxx>
  Date:   2022-05-31 (Tue, 31 May 2022)

  Changed paths:
    M tools/mesh-gatt/prov-db.c

  Log Message:
  -----------
  mesh-gatt: Fix use_after_free

Following scenario happens when prov is false and we have double free as
mentioned in the below

bluez-5.64/tools/mesh-gatt/prov-db.c:847: freed_arg: "g_free" frees
"in_str".

bluez-5.64/tools/mesh-gatt/prov-db.c:867: double_free: Calling "g_free"
frees pointer "in_str" which has already been freed.


  Commit: 93850c827d549115f0396da42c4a0529feeed1a3
      https://github.com/bluez/bluez/commit/93850c827d549115f0396da42c4a0529feeed1a3
  Author: Joseph Hwang <josephsih@xxxxxxxxxxxx>
  Date:   2022-06-02 (Thu, 02 Jun 2022)

  Changed paths:
    M doc/mgmt-api.txt

  Log Message:
  -----------
  doc: Introduce the quality report command and event

Add the MGMT quality report command and event in doc/mgmt-api.txt.


  Commit: 7bcd32e67e9388c49212e5dd5dd431c9ec079eb0
      https://github.com/bluez/bluez/commit/7bcd32e67e9388c49212e5dd5dd431c9ec079eb0
  Author: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
  Date:   2022-06-02 (Thu, 02 Jun 2022)

  Changed paths:
    M tools/test-runner.c

  Log Message:
  -----------
  test-runner: Fix not waiting for system_bus_socket

This makes test-runner wait for system_bus_socket to be available before
continuing otherwise the likes of bluetoothd would likely fail to start.


  Commit: 67b325c614e5fdac255798fb9280b32e704895e1
      https://github.com/bluez/bluez/commit/67b325c614e5fdac255798fb9280b32e704895e1
  Author: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
  Date:   2022-06-02 (Thu, 02 Jun 2022)

  Changed paths:
    M doc/test-runner.txt
    M doc/tester.config

  Log Message:
  -----------
  test-runner: Enable BT_HCIUART and BT_HCIUART_H4

These options are required when running with -u option since that uses
H4 headers to serialize the communication of host and guest.


  Commit: ab31e2f7e828df3d971cba6f12859edc69f149d5
      https://github.com/bluez/bluez/commit/ab31e2f7e828df3d971cba6f12859edc69f149d5
  Author: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
  Date:   2022-06-02 (Thu, 02 Jun 2022)

  Changed paths:
    M tools/mgmt-tester.c

  Log Message:
  -----------
  mgmt-tester: Fix build error

This fixes the following build error:

CC    tools/mgmt-tester.o
tools/mgmt-tester.c: In function ‘setup_command_generic’:
tools/mgmt-tester.c:7503:16: error: the comparison will always evaluate
as ‘true’ for the pointer operand in
‘(const struct setup_mgmt_cmd *)test->setup_mgmt_cmd_arr +
(sizetype)(i * 24)’ must not be NULL [-Werror=address]
 7503 |     for (; test->setup_mgmt_cmd_arr + i; ++i) {
   |        ^~~~


Compare: https://github.com/bluez/bluez/compare/1ffd74a6d421...ab31e2f7e828




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux