Skip to content

[PW_SID:1079179] [v5] Bluetooth: qca: Fix delayed hw_error handling due to missing wakeup during SSR#3467

Open
BluezTestBot wants to merge 1 commit intoworkflowfrom
1079179
Open

[PW_SID:1079179] [v5] Bluetooth: qca: Fix delayed hw_error handling due to missing wakeup during SSR#3467
BluezTestBot wants to merge 1 commit intoworkflowfrom
1079179

Conversation

@BluezTestBot
Copy link
Copy Markdown
Owner

When Bluetooth controller encounters a coredump, it triggers
the Subsystem Restart (SSR) mechanism. The controller first
reports the coredump data, and once the data upload is complete,
it sends a hw_error event. The host relies on this event to
proceed with subsequent recovery actions.

If the host has not finished processing the coredump data
when the hw_error event is received,
it sets a timer to wait until either the data processing is complete
or the timeout expires before handling the event.

The current implementation lacks a wakeup trigger. As a result,
even if the coredump data has already been processed, the host
continues to wait until the timer expires, causing unnecessary
delays in handling the hw_error event.

To fix this issue, adds a wake_up_bit() call after the host finishes
processing the coredump data. This ensures that the waiting thread is
promptly notified and can proceed to handle the hw_error event without
waiting for the timeout.

Test case:

  • Trigger controller coredump using the command: hcitool cmd 0x3f 0c 26.
  • Use btmon to capture HCI logs.
  • Observe the time interval between receiving the hw_error event
    and the execution of the power-off sequence in the HCI log.

Signed-off-by: Shuai Zhang shuai.zhang@oss.qualcomm.com

Changes v5:

Changes v4:

Changes v3:

Changes v2:


drivers/bluetooth/hci_qca.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

…uring SSR

When Bluetooth controller encounters a coredump, it triggers
the Subsystem Restart (SSR) mechanism. The controller first
reports the coredump data, and once the data upload is complete,
it sends a hw_error event. The host relies on this event to
proceed with subsequent recovery actions.

If the host has not finished processing the coredump data
when the hw_error event is received,
it sets a timer to wait until either the data processing is complete
or the timeout expires before handling the event.

The current implementation lacks a wakeup trigger. As a result,
even if the coredump data has already been processed, the host
continues to wait until the timer expires, causing unnecessary
delays in handling the hw_error event.

To fix this issue, adds a `wake_up_bit()` call after the host finishes
processing the coredump data. This ensures that the waiting thread is
promptly notified and can proceed to handle the hw_error event without
waiting for the timeout.

Test case:
- Trigger controller coredump using the command: `hcitool cmd 0x3f 0c 26`.
- Use `btmon` to capture HCI logs.
- Observe the time interval between receiving the hw_error event
and the execution of the power-off sequence in the HCI log.

Signed-off-by: Shuai Zhang <shuai.zhang@oss.qualcomm.com>
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

CheckPatch
Desc: Run checkpatch.pl script
Duration: 0.56 seconds
Result: PENDING

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

GitLint
Desc: Run gitlint
Duration: 0.25 seconds
Result: PENDING

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

SubjectPrefix
Desc: Check subject contains "Bluetooth" prefix
Duration: 0.08 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

BuildKernel
Desc: Build Kernel for Bluetooth
Duration: 25.04 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

CheckAllWarning
Desc: Run linux kernel with all warning enabled
Duration: 27.37 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

CheckSparse
Desc: Run sparse tool with linux kernel
Duration: 27.05 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

BuildKernel32
Desc: Build 32bit Kernel for Bluetooth
Duration: 24.57 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunnerSetup
Desc: Setup kernel and bluez for test-runner
Duration: 530.06 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_l2cap-tester
Desc: Run l2cap-tester with test-runner
Duration: 28.46 seconds
Result: FAIL
Output:

Total: 96, Passed: 95 (99.0%), Failed: 1, Not Run: 0

Failed Test Cases
L2CAP BR/EDR Server - Set PHY 3M                     Failed       0.115 seconds

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_iso-tester
Desc: Run iso-tester with test-runner
Duration: 37.36 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_bnep-tester
Desc: Run bnep-tester with test-runner
Duration: 6.29 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_mgmt-tester
Desc: Run mgmt-tester with test-runner
Duration: 111.47 seconds
Result: FAIL
Output:

Total: 494, Passed: 489 (99.0%), Failed: 1, Not Run: 4

Failed Test Cases
Read Exp Feature - Success                           Failed       0.105 seconds

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_rfcomm-tester
Desc: Run rfcomm-tester with test-runner
Duration: 9.41 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_sco-tester
Desc: Run sco-tester with test-runner
Duration: 14.52 seconds
Result: FAIL
Output:

WARNING: possible circular locking dependency detected
BUG: sleeping function called from invalid context at net/core/sock.c:3782
Total: 30, Passed: 30 (100.0%), Failed: 0, Not Run: 0

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_ioctl-tester
Desc: Run ioctl-tester with test-runner
Duration: 10.17 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_mesh-tester
Desc: Run mesh-tester with test-runner
Duration: 12.62 seconds
Result: FAIL
Output:

Total: 10, Passed: 8 (80.0%), Failed: 2, Not Run: 0

Failed Test Cases
Mesh - Send cancel - 1                               Timed out    2.748 seconds
Mesh - Send cancel - 2                               Timed out    1.997 seconds

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_smp-tester
Desc: Run smp-tester with test-runner
Duration: 8.64 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

TestRunner_userchan-tester
Desc: Run userchan-tester with test-runner
Duration: 6.76 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

IncrementalBuild
Desc: Incremental build with the patches in the series
Duration: 0.94 seconds
Result: PENDING

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants