Bluetooth: BT_SCAN reuse lib_bluetooth scan helpers and de-noise stdout#305
Open
smuppand wants to merge 4 commits intoqualcomm-linux:mainfrom
Open
Bluetooth: BT_SCAN reuse lib_bluetooth scan helpers and de-noise stdout#305smuppand wants to merge 4 commits intoqualcomm-linux:mainfrom
smuppand wants to merge 4 commits intoqualcomm-linux:mainfrom
Conversation
…isibility BT_ON_OFF was skipping when bluetoothctl did not immediately show the controller. Poll for controller visibility after public-addr and keep output sanitization to handle CR/ANSI noise in piped output. Also drop leading-underscore temp vars. Signed-off-by: Srikanth Muppandam <smuppand@qti.qualcomm.com>
Call btloghcidiag() after adapter selection and before controller checks so failures provide immediate service/journal context. Signed-off-by: Srikanth Muppandam <smuppand@qti.qualcomm.com>
Replace plain diagnostics with btctl_script list+quit so controller listing is consistent on ramdisk/minimal images where non-interactive output can be empty. Signed-off-by: Srikanth Muppandam <smuppand@qti.qualcomm.com>
…oothctl is flaky Signed-off-by: Srikanth Muppandam <smuppand@qti.qualcomm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
bluetoothctl list often returns no controllers in non-interactive mode. BT_SCAN correctly falls back to interactive bluetoothctl, but today that leads to:
Repeated fallback banner/diagnostics (same WARN/INFO block printed multiple times).
“Devices seen …” log being polluted with interactive bluetoothctl transcript (prompt lines / ANSI escapes / controller events), making CI/LAVA logs noisy and harder to parse.
What this PR changes (This PR fixes #303 )
Ensure the “non-interactive list empty -> interactive fallback” banner + optional diagnostics are emitted only once per run.
Keep the same controller visibility logic (non-interactive fast path, interactive fallback), but avoid duplicated WARN/INFO blocks during later BT operations.
Implement the new interactive fallback so that CI won't fail, but we will still generate log_warn. This way, CI engineers can identify and debug any issues.