Commits

Commit Message Author Age Changes
f9cb7c80 mgmt: Add DBG macro This adds mgmt_log wrapper for util_debug and DBG so file and function names are printed with the logs. Luiz Augusto von Dentz 3 years ago 1 file, +22, -14
a3c94090 log: Don't log __FILE__ and __func__ with DBG_IDX This removes __FILE__ and __func__ from DBG_IDX since users of it may already contain such information embedded in the format. Luiz Augusto von Dentz 3 years ago 1 file, +4, -2
41f8c466 Release 5.64 Marcel Holtmann 3 years ago 2 files, +9, -1
411d63ec gatt-db: Fix gatt_db_attribute_notify gatt_db_attribute_notify was only accepting passing the Characteristic Declaration instead of accepting its value as well, gatt_db_service_foreach_desc also have similar limitation so both have been updated to allow working with both value and declaration. Luiz Augusto von Dentz 3 years ago 1 file, +51, -12
8fb8f9e7 gatt: Print error if gatt_db_attribut_notify fails This prints an error if gatt_db_attribut_notify fails. Luiz Augusto von Dentz 3 years ago 1 file, +6, -4
42e99371 test-runner: Update help information This updates usage so it list -l/--emulator properly: test-runner - Automated test execution utility Usage: test-runner [options] [--] <command> [args] Options: -a, --auto Find tests and run them -d, --dbus Start D-Bus daemon -m, --monitor Start btmon -l, --emulator Start btvirt -u, --unix [path] Provide serial device -q, --qemu <path> QEMU binary -k, --kernel <image> Kernel image (bzImage) -h, --help Show help options Luiz Augusto von Dentz 3 years ago 1 file, +1, -0
55888bfd test-runner: Fix -l/--emulator This fixes -l/--emulator not able to start depending on what parameters are given as it was not setting the directory properly. Luiz Augusto von Dentz 3 years ago 1 file, +7, -2
8e1892cc btdev: Fix response to LE Set Extended Advertising Parameters The response should both the status and TX Power regardless if the command succeeds or not. Luiz Augusto von Dentz 3 years ago 1 file, +9, -8
b69b5736 audio: Fix crash in a2dp_discover Sample stack trace: 0x0000567c394e4c6b (bluetoothd - a2dp.c: 270) setup_cb_free 0x0000567c394e4a94 (bluetoothd - a2dp.c: 2884) a2dp_discover 0x0000567c394e3c03 (bluetoothd - sink.c: 275) sink_setup_stream 0x0000567c394e3d4f (bluetoothd - sink.c: 299) sink_connect 0x0000567c39535183 (bluetoothd - service.c: 294) btd_service_connect 0x0000567c39539f68 (bluetoothd - device.c: 2006) connect_next 0x0000567c3954086d (bluetoothd - device.c: 2060) service_state_changed 0x0000567c39534efb (bluetoothd - service.c: 111) change_state 0x0000567c3953559c (bluetoothd - service.c: 0) btd_service_connecting_complete 0x0000567c39534a5c (bluetoothd - profile.c: 1641) record_cb 0x0000567c395197cd (bluetoothd - sdp-client.c: 298) connect_watch 0x00007b14bc8034f6 (libglib-2.0.so.0 - gmain.c: 3337) g_main_context_dispatch 0x00007b14bc803801 (libglib-2.0.so.0 - gmain.c: 4131) g_main_context_iterate 0x00007b14bc803a7d (libglib-2.0.so.0 - gmain.c: 4329) g_main_loop_run 0x0000567c39566af1 (bluetoothd - mainloop-glib.c: 79) mainloop_run 0x0000567c39566ddb (bluetoothd - mainloop-notify.c: 201) mainloop_run_with_signal 0x0000567c3954bf4c (bluetoothd - main.c: 1222) main 0x00007b14bc579797 (libc.so.6 - libc-start.c: 332) __libc_start_main 0x0000567c394df449 (bluetoothd) _start 0x00007ffd70145737 This could be triggered from a2dp_discover -> avdtp_discover -> send_request -> send_req -> l2cap_connect (return error) -> avdtp_set_state (to disconnect state)-> channel_remove -> channel_free -> finalize_setup_errno (discover cb is freed) -> error handling all the way back to a2dp_discover -> a2dp_discover (discover cb is freed again, crashed!). The fix is to attach cb with setup after avdtp_discover success. Suggested-by: luiz.dentz@gmail.com Reviewed-by: Archie Pusaka <apusaka@chromium.org> Yun-Hao Chung 3 years ago 1 file, +20, -6
554fcb7d bthost: Add support for Create BIG This adds bthost_create_big Luiz Augusto von Dentz 3 years ago 2 files, +14, -0
f040ba43 bthost: Add support for Periodic Advertising This adds bthost_set_pa_params and bthost_set_pa_enable. Luiz Augusto von Dentz 3 years ago 2 files, +25, -0
a473a5a4 bthost: Add support for BT_H4_ISO_PKT This adds sending and receiving BT_H4_ISO_PKT packets. Luiz Augusto von Dentz 3 years ago 4 files, +328, -42
9cbc6fc1 btdev: Implements BT_HCI_CMD_LE_BIG_TERM_SYNC This sends BT_HCI_EVT_DISCONNECT_COMPLETE when handling BT_HCI_CMD_LE_BIG_TERM_SYNC. Luiz Augusto von Dentz 3 years ago 2 files, +42, -2
40bacfff btdev: Implements BT_HCI_CMD_LE_BIG_CREATE_SYNC This sends BT_HCI_EVT_LE_BIG_SYNC_ESTABLISHED when handling BT_HCI_CMD_LE_BIG_CREATE_SYNC. Luiz Augusto von Dentz 3 years ago 2 files, +150, -9
9d7f4405 monitor: Rename Periodic Advertising terms to PA/pa This renames the use of Periodic Advertising in the API to just PA. Luiz Augusto von Dentz 3 years ago 3 files, +173, -181
306bc0ca btdev: Send BT_HCI_EVT_LE_PER_SYNC_ESTABLISHED if remote start pa This sends BT_HCI_EVT_LE_PER_SYNC_ESTABLISHED if remote device start to periodic advertise when BT_HCI_CMD_LE_PERIODIC_ADV_CREATE_SYNC is pending. Luiz Augusto von Dentz 3 years ago 1 file, +78, -66
d07185ff btdev: Send BT_HCI_EVT_LE_PER_SYNC_ESTABLISHED when scan is initiated This sends BT_HCI_EVT_LE_PER_SYNC_ESTABLISHED if scan is initiated while BT_HCI_CMD_LE_PERIODIC_ADV_CREATE_SYNC is pending. Luiz Augusto von Dentz 3 years ago 1 file, +86, -66
942a73da btdev: Implement BT_HCI_CMD_LE_PERIODIC_ADV_TERM_SYNC This adds implementation of BT_HCI_CMD_LE_PERIODIC_ADV_TERM_SYNC. Luiz Augusto von Dentz 3 years ago 1 file, +15, -2
3250d7f9 btdev: Implement BT_HCI_CMD_LE_PERIODIC_ADV_CREATE_SYNC_CANCEL This adds implementation of BT_HCI_CMD_LE_PERIODIC_ADV_CREATE_SYNC_CANCEL generating BT_HCI_EVT_LE_PER_SYNC_ESTABLISHED if necessary. Luiz Augusto von Dentz 3 years ago 2 files, +28, -3
ea501af9 btdev: Implement BT_HCI_CMD_LE_PERIODIC_ADV_CREATE_SYNC This adds implementation of BT_HCI_CMD_LE_PERIODIC_ADV_CREATE_SYNC generating BT_HCI_EVT_LE_PER_SYNC_ESTABLISHED and BT_HCI_EVT_LE_PER_ADV_REPORT. Luiz Augusto von Dentz 3 years ago 1 file, +96, -3
b5ab5eee monitor: Fix Create BIG PDU The PDU of Create BIG is actually fixed size as the num_bis is related to the number of indexes to be connected and not the BIS parameters. Luiz Augusto von Dentz 3 years ago 3 files, +4, -9
2f4368de device: Fix writing out of bounds array %32s expect a buffer of at least 33 bytes since it is a string it needs to be NULL terminated. ihsinme 3 years ago 1 file, +1, -1
5e9342ee gatt: sanitize input at profile registration Check whether type of UUIDs property of GattProfile1 object is correct. Andreas Kemnade 3 years ago 1 file, +5, -0
18af5f4f client: Add support for scan <le/bredr> This adds support for entering the transport directly as an scan argument rather than having to first set it scan.transport. Luiz Augusto von Dentz 3 years ago 1 file, +24, -2
b9f27b81 test-runner: Fix parsing of command line Instead of parsing the command line, which can contain a shell script, run using /bin/sh so it allows more complex command line to be tested: sudo tools/test-runner -l -d -k <pathto/bzImage> -- 'client/bluetoothctl power on && sleep 2 && client/bluetoothctl power off' Luiz Augusto von Dentz 3 years ago 1 file, +7, -21
ab943bf8 shared/shell: Introduce bt_shell_exec This introduces bt_shell_exec which can be used to inject commands into a bt_shell without using stdin/user input. Luiz Augusto von Dentz 3 years ago 2 files, +25, -10
85000373 test-runner: Add option to start emulator This adds an option (-l/--emulator) to start btvirt before processing the command which is convenient to runs tools like bluetoothctl: sudo tools/test-runner -l -d -k <pathto/bzImage> -- client/bluetoothctl power on Luiz Augusto von Dentz 3 years ago 1 file, +82, -4
d91fe699 hog-lib: Fix not waiting for UHID_START With use of UHID_CREATE2 the code needs to wait for UHID_START in order to know if the reports are numbered or not. Fixes: https://github.com/bluez/bluez/issues/298 Luiz Augusto von Dentz 3 years ago 1 file, +22, -19
2ae3ce9e btproxy: Attempt to bind the next index If no specific index is given attempt to bind the next index if the current one is already in use. Luiz Augusto von Dentz 3 years ago 1 file, +17, -4
bf09e1f0 neard: Fix reading State message dbus_message_iter_recurse only makese sense for container types, this is a string. Fixes: https://github.com/bluez/bluez/issues/300 Nicolas Fella 3 years ago 1 file, +0, -2
58dec00e src/shared/util.h: include sys/types.h Include sys/types.h to avoid the following build failure on musl raised since commit fb57ad9b9d107856e5f1c8135da04ffa2f7a11ac: In file included from src/shared/queue.c:15: ./src/shared/util.h:106:1: error: unknown type name 'ssize_t'; did you mean 'size_t'? 106 | ssize_t util_getrandom(void *buf, size_t buflen, unsigned int flags); | ^~~~~~~ | size_t Fixes: - http://autobuild.buildroot.org/results/83eaeb3863040645409f5787fdbdde79385c5257 Fabrice Fontaine 3 years ago 1 file, +1, -0
65302d98 error: Fix typo s/suuported/supported Fabrice Delliaux 3 years ago 1 file, +1, -1
d89af9ac monitor: fix division by zero about conn->tx_pkt_med In a connection without outgoing traffic, conn->tx_num will remain 0. In this case, conn->tx_pkt_med should be simply 0 without calculating "conn->tx_bytes / conn->tx_num". This was likely to happen, for example, when "btmon -w btsnoop.log" was launched in the middle of a LE mouse connection, and a number of incoming ACL Data RX were received as the mouse movements. When running "btmon -a btsnoop.log", it would encounter this error. Reviewed-by: Alain Michaud <alainm@chromium.org> Reviewed-by: Yun-Hao Chung <howardchung@chromium.org> Reviewed-by: Shuo-Peng Liao <deanliao@chromium.org> Joseph Hwang 3 years ago 1 file, +2, -1
b086260a adapter-api: Document per-client discovery sessions The fact that each client can start its own discovery wasn't clear from the documentation and only becomes obvious when reading the sources. Bastien Nocera 3 years ago 1 file, +5, -1
2e4627c3 player: Fix Track being emitted with empty metadata This sometimes causes the Track to be schedule while some metadata are still pending, also don't remove the Duration from track when updating its metadata since Duration is typically updated by player status rather than metadata. Fixes: https://github.com/bluez/bluez/issues/291 Luiz Augusto von Dentz 3 years ago 3 files, +45, -35
8fe1e5e1 gobex: Fix read from pointer after free This patch sets the pointer to null after free since the g_free(p) doesn't set the pointer to NULL. This is reported by the Coverity. Fixes: 7e7d826aa1db ("gobex: Print error if data cannot be written") Tedd Ho-Jeong An 3 years ago 1 file, +2, -0
51c34da9 Makefile.tools: remove duplicate link entry Michael Nosthoff 3 years ago 1 file, +1, -2
840ca1e7 shared: Fix the incorrect type with bit shift This patch fixes the following runtime error: $ sudo ./monitor/btmon -w test.btsnoop Bluetooth monitor ver 5.63 src/shared/btsnoop.c:339:18: runtime error: left shift of 65535 by 16 places cannot be represented in type 'int' Tedd Ho-Jeong An 3 years ago 1 file, +1, -1
afefbb48 main.conf: Fix parsing of mode options This replace the use of g_key_file_get_integer, which is limited to only decimal values, to g_key_file_get_string and then use strtol to convert the string value to integer. Fixes: https://github.com/bluez/bluez/issues/293 Luiz Augusto von Dentz 3 years ago 1 file, +12, -3
d96c2fd8 adapter: Fix allowing multiple adapters with the same address The bdaddr of an adapter is used for its unique storage path so having multiple adapters with the same address would likely cause problems with its storage as they would be shared. Luiz Augusto von Dentz 3 years ago 1 file, +10, -0
a1cdd683 main.conf: Introduce MaxControllers This introduces MaxControllers which can be used to limit the number of adapters exposed in the system. Luiz Augusto von Dentz 3 years ago 4 files, +21, -0
ec8c8f22 tools/mesh-cfgtest: include limits.h mesh-cfgtest.c uses MAX_PATH so it should include limits.h. fixes compilation error with musl-based toolchains. Michael Nosthoff 3 years ago 1 file, +1, -0
e6b7d537 adapter: battery provider for non-LE controllers Enable battery provider dbus interface BatteryProviderManager1 for non-LE controllers, so external clients like pipewire can provide battery information for bluetooth headsets on non-LE controllers. Reviewed-by: Sonny Sasaka <sonnysasaka@chromium.org> Daniel Trnka 3 years ago 1 file, +5, -5
fb57ad9b build: Fix errors with glibc < 2.25 getrandom and sys/random.h are only available since glibc 2.25: https://www.gnu.org/software/gnulib/manual/html_node/sys_002frandom_002eh.html resulting in the following build failures since version 5.63 and https://git.kernel.org/pub/scm/bluetooth/bluez.git/log/?qt=grep&q=getrandom: plugins/autopair.c:20:24: fatal error: sys/random.h: No such file or directory #include <sys/random.h> ^ To fix this build failure, add util_getrandom and a fallback (borrowed from pipewire and licensed under MIT): https://gitlab.freedesktop.org/pipewire/pipewire/-/blob/master/src/pipewire/utils.c Fixes: - http://autobuild.buildroot.org/results/6b8870d12e0804d6154230a7322c49416c1dc0e2 Fabrice Fontaine 3 years ago 10 files, +42, -16
b5ff08b2 lib: fix hci_strtolm crash |str| can be NULL in the case of reading lm value. Calling strcasestr could lead to a crash. Reviewed-by: Archie Pusaka <apusaka@chromium.org> Yun-Hao Chung 3 years ago 1 file, +1, -1
6c9c4b7c rfcomm-tester: Increase amount of data from 8k to 32k This forces the behavior where not all data can be written at once so it is able to reproduce the from [1]. [1]https://bugzilla.kernel.org/show_bug.cgi?id=215594 Luiz Augusto von Dentz 3 years ago 1 file, +66, -24
7e7d826a gobex: Print error if data cannot be written This makes sure that if the data cannot be written it fails and the error is properly printed. Luiz Augusto von Dentz 3 years ago 1 file, +15, -2
47bea541 obexctl: Add optional argument channel to connect command This adds a third argument to connect command so a channel can be passed to CreateSession which is useful since it possible to force a specific RFCOMM channel. Luiz Augusto von Dentz 3 years ago 1 file, +21, -6
002c0c9e profiles: Fix the reusing gerror without re-initialization When the GError variable is freeed with g_error_free(), it is not set to NULL and reusing the same variable again can cause the seg_fault because it is still pointing the old memory address which is freed. This patch relaces the g_error_free() to g_clear_error() which frees the variable and set it to NULL if the variable is used in the function again. Fixes: 4ad622d592ba5 ("profiles/a2dp: Fix unchecked return value") Tedd Ho-Jeong An 3 years ago 3 files, +6, -6
8b69a634 device: Fix the reusing gerror without re-initialization When the GError variable is freeed with g_error_free(), it is not set to NULL and reusing the same variable again can cause the seg_fault because it is still pointing the old memory address which is freed. This patch relaces the g_error_free() to g_clear_error() which frees the variable and set it to NULL if the variable is used in the function again. Fixes: 6a154cd08000b ("device: Fix unchecked return value") Tedd Ho-Jeong An 3 years ago 1 file, +6, -6
Previous Next