Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
76 changes: 56 additions & 20 deletions Runner/config/pkg_command_map.conf
Original file line number Diff line number Diff line change
Expand Up @@ -103,26 +103,24 @@ ubuntu:benchmark_model=tensorflow-lite-qcom-apps
debian:qnn-net-run=qnn-tools
ubuntu:qnn-net-run=qnn-tools

# On general-purpose distributions, audio asset download is recovered only
# when AudioPlayback needs a remote clip and neither curl nor wget is already
# available. curl is sufficient because the downloader retains wget as an
# image-provided fallback.
debian:package-set:audio-download=curl
ubuntu:package-set:audio-download=curl
centos:package-set:audio-download=curl
# Audio asset downloads use only image-provided curl or wget clients.

# ---------------------------------------------------------------------------
# Ubuntu Bluetooth userspace stack.
# Bluetooth userspace stack and firmware.
#
# Ubuntu Server installs this package set before running the current Bluetooth
# validation tests. Ubuntu Desktop uses its image-provided stack and skips
# package installation.
#
# PipeWire, WirePlumber, and libspa-0.2-bluetooth provide the BlueZ media
# endpoint/profile integration validated as part of the Ubuntu BT stack.
# CentOS uses BlueZ from BaseOS and Qualcomm/Atheros firmware from the
# atheros-firmware package. The package set is intentionally minimal because
# hciconfig is not shipped by CentOS Stream 10 and is optional to the tests.
# ---------------------------------------------------------------------------

ubuntu:package-set:bluetooth=bluez pipewire wireplumber libspa-0.2-bluetooth alsa-utils rfkill expect
centos:package-set:bluetooth=bluez atheros-firmware expect

# ---------------------------------------------------------------------------
# Weston compositor and example-client mappings.
Expand Down Expand Up @@ -220,6 +218,24 @@ rpm:gst-launch-1.0=gstreamer1.0-tools
rpm:gst-inspect-1.0=gstreamer1.0-tools
rpm:efivar=efivar

# CentOS Stream 10 Bluetooth command ownership. Keep these OS-specific so
# Yocto RPM images retain their existing package policy. hciconfig and hcitool
# are deprecated BlueZ tools and are not shipped by CentOS Stream 10
# BaseOS/AppStream/CRB, so the helpers use sysfs and bluetoothctl instead.
# l2ping is an optional fallback supplied by bluez-libs-devel from CRB.
centos:bluetoothctl=bluez
centos:bluetoothd=bluez
centos:btattach=bluez
centos:btmgmt=bluez
centos:btmon=bluez
centos:l2ping=bluez-libs-devel
centos:rfkill=util-linux
centos:expect=expect
centos:pgrep=procps-ng
centos:killall=psmisc
centos:lsmod=kmod
centos:modprobe=kmod

# ---------------------------------------------------------------------------
# Common opkg provider mappings.
# Applies to opkg-based images.
Expand Down Expand Up @@ -280,11 +296,13 @@ ubuntu:package-set:fastrpc=fastrpc-support fastrpc-tests

debian:package-set:fastcv-runtime=qcom-fastcv-binaries libfastcvopt-dev
ubuntu:package-set:fastcv-runtime=qcom-fastcv-binaries libfastcvopt-dev
centos:package-set:fastcv-rpm-prerequisites=epel-release
centos:package-set:fastcv-runtime=qcom-fastcv-binaries libfastcvopt-devel
rhel:package-set:fastcv-rpm-prerequisites=epel-release
rhel:package-set:fastcv-runtime=qcom-fastcv-binaries libfastcvopt-devel

# Shared prerequisite for explicit Qualcomm RPM package preparation.
centos:package-set:qualcomm-rpm-prerequisites=epel-release
rhel:package-set:qualcomm-rpm-prerequisites=epel-release

# ---------------------------------------------------------------------------
# Qualcomm MinkIPC runtime and test packages.
#
Expand Down Expand Up @@ -350,13 +368,15 @@ ubuntu:package-set:urm=userspace-resource-manager userspace-resource-manager-tes
# for example:
# ./run.sh --overlay
#
# Currently available from qli-staging. Once promoted to qli, only the source
# selection in the caller needs to change. The package-set name remains graphics.
# Debian packages are currently available from qli-staging. Once promoted to
# qli, only the source selection in the caller needs to change. CentOS packages
# use the Qualcomm production RPM repositories.
#
# DKMS packages are skipped by lib_pkg_provider.sh when matching kernel headers
# are unavailable. Remaining userspace packages continue to install.
#
# No qcom-distro/rpm mapping is provided, so Yocto remains no-op.
# CentOS Stream 10 uses the verified Qualcomm RPM package names below.
# No qcom-distro mapping is provided, so Yocto remains no-op.
# ---------------------------------------------------------------------------

# Qualcomm proprietary graphics overlay package set.
Expand All @@ -371,16 +391,19 @@ ubuntu:package-set:graphics-base=libegl-mesa0 libgl1-mesa-dri libgbm1 libegl1 li
# Qualcomm proprietary graphics overlay package set for Ubuntu.
ubuntu:package-set:graphics=kgsl-dkms adreno-common libgbm-msm adreno-gles1 adreno-gles2 adreno-egl1 adreno-vulkan-icd adreno-opencl-icd adreno-opencl-dev

# CentOS Stream 10 Qualcomm graphics overlay. gbm-msm-backend is listed
# explicitly because graphics validation checks the installed GBM backend.
centos:package-set:graphics=gbm-msm-backend adreno-egl1 adreno-gles2 adreno-opencl-icd adreno-vulkan-icd

# ---------------------------------------------------------------------------
# Audio validation package recovery.
#
# Debian Audio tests use the upstream base Audio stack by default.
# Qualcomm AudioReach packages are installed only when --overlay is explicitly
# requested.
# Debian and CentOS Audio tests use the base Audio stack by default. Qualcomm
# AudioReach packages are installed only when --overlay is explicitly requested.
#
# No rpm, opkg, qcom-distro, or generic provider package-set mapping is
# provided. Yocto and other embedded images therefore continue using their
# image-provided Audio stack without package recovery.
# CentOS Stream 10 uses the verified Qualcomm RPM package names below. No opkg,
# qcom-distro, or generic provider package-set mapping is provided, so Yocto
# and other embedded images continue using their image-provided Audio stack.
# ---------------------------------------------------------------------------

# Base Debian Audio stack.
Expand All @@ -397,6 +420,9 @@ ubuntu:package-set:audio-desktop=pipewire pipewire-pulse wireplumber pipewire-bi
# This package set is complete by itself because overlay mode checks only
# "audio"; it does not check "audio-base" first.
debian:package-set:audio=alsa-utils pipewire-bin wireplumber pulseaudio-utils audioreach-pipewire-plugin audioreach-kernel-dkms audioreach-config

# CentOS Stream 10 Qualcomm AudioReach overlay.
centos:package-set:audio=audioreach-dkms audioreach-pal audioreach-pipewire-plugin

# Command recovery used by check_dependencies()/pkg_ensure_command().
apt:aplay=alsa-utils
Expand All @@ -409,6 +435,9 @@ apt:pw-record=pipewire-bin
apt:pactl=pulseaudio-utils
apt:paplay=pulseaudio-utils
apt:parecord=pulseaudio-utils
rpm:pw-play=pipewire-utils
rpm:pw-record=pipewire-utils
rpm:pw-cat=pipewire-utils

# ---------------------------------------------------------------------------
# Qualcomm Sensors runtime and test packages.
Expand Down Expand Up @@ -463,4 +492,11 @@ centos:Sensors:ssc_drva_test=qcom-sensors-test-core qcom-sensors-test-apps

debian:package-set:camera-nhx=camx-dkms camx-glymur libcamx-glymur1 camx-firmware-glymur camx-nhx
ubuntu:package-set:camera-nhx=camx-dkms camx-glymur libcamx-glymur1 camx-firmware-glymur camx-nhx
centos:package-set:camera-nhx=camx-dkms camx-glymur libcamx-glymur1 camx-firmware-glymur camx-nhx
centos:package-set:camera-nhx=camx-dkms camx-firmware-kodiak camx-kodiak libcamx-kodiak1

# Qualcomm Iris video overlay. Debian and Ubuntu use the public DKMS package,
# whose post-install flow builds, registers, and loads iris_vpu. CentOS uses
# the equivalent RPM package and scriptlet.
debian:package-set:video-overlay=iris-vpu-dkms
ubuntu:package-set:video-overlay=iris-vpu-dkms
centos:package-set:video-overlay=iris-vpu
29 changes: 19 additions & 10 deletions Runner/suites/Connectivity/Bluetooth/BT_FW_KMD_Service/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -113,15 +113,19 @@ WARN_COUNT=0
log_info "------------------------------------------------------------"
log_info "Starting $TESTNAME"

if ! bt_prepare_ubuntu_stack; then
test_result_finish "FAIL" "$TESTNAME FAIL - Ubuntu Bluetooth stack preparation failed"
if ! bt_prepare_bluetooth_stack; then
test_result_finish "FAIL" "$TESTNAME FAIL - Bluetooth stack preparation failed"
fi

log_info "Checking dependencies: bluetoothctl hciconfig lsmod"
if ! check_dependencies bluetoothctl hciconfig lsmod; then
log_info "Checking dependencies: bluetoothctl lsmod"
if ! check_dependencies bluetoothctl lsmod; then
test_result_finish "SKIP" "$TESTNAME SKIP - required Bluetooth tools are unavailable"
fi

if ! command -v hciconfig >/dev/null 2>&1; then
log_info "Optional hciconfig command is unavailable, using sysfs and bluetoothctl diagnostics"
fi

# ---------- Bluetooth runtime check/ readiness ----------
log_info "Waiting up to ${BT_RUNTIME_READY_WAIT}s for a usable Bluetooth runtime"
if bt_ensure_runtime_ready \
Expand All @@ -136,7 +140,9 @@ if bt_ensure_runtime_ready \
test_result_record "PASS" "Bluetooth runtime exposed an HCI adapter with a valid BD address"
fi
else
test_result_record "FAIL" "Bluetooth runtime remained unusable after bounded recovery attempts"
test_result_record \
"FAIL" \
"${BT_RUNTIME_FAILURE_REASON:-Bluetooth runtime remained unusable after bounded recovery attempts}"
fi

ADAPTER="$BT_RUNTIME_READY_ADAPTER"
Expand Down Expand Up @@ -181,7 +187,7 @@ fi
if fw_dir="$(btfwpresent 2>/dev/null)"; then
test_result_record "PASS" "Firmware present in: $fw_dir"
else
log_warn "No BT firmware matching msbtfw*/msnv* or cmbtfw*/cmnv* found under standard firmware paths."
log_warn "No supported Qualcomm Bluetooth firmware or NVM file found under standard firmware paths"
WARN_COUNT=$((WARN_COUNT + 1))
fi

Expand Down Expand Up @@ -248,7 +254,9 @@ if command -v btfwloaded >/dev/null 2>&1; then
log_warn "No retained BT firmware-load signature found, but BT runtime state is healthy."
WARN_COUNT=$((WARN_COUNT + 1))
else
test_result_record "FAIL" "Firmware load/setup is incomplete and Bluetooth runtime state is unhealthy"
test_result_record \
"FAIL" \
"Firmware load/setup is incomplete and Bluetooth runtime is unhealthy, verify the image firmware package and reboot after provisioning new firmware"
fi
;;
esac
Expand Down Expand Up @@ -316,7 +324,9 @@ if [ -n "$ADAPTER" ]; then
if btbdok "$ADAPTER"; then
test_result_record "PASS" "BD address is valid for $ADAPTER"
else
test_result_record "FAIL" "BD address is invalid or all zeros for $ADAPTER"
test_result_record \
"FAIL" \
"BD address is invalid or all zeros for $ADAPTER, verify Qualcomm firmware and platform BD-address provisioning"
fi
fi

Expand All @@ -341,8 +351,7 @@ log_info "=== hciconfig -a (if available) ==="
if command -v hciconfig >/dev/null 2>&1; then
hciconfig -a || true
else
log_warn "hciconfig command not available."
WARN_COUNT=$((WARN_COUNT + 1))
log_info "Optional hciconfig command is unavailable"
fi

log_info "=== bluetoothctl list (controllers) ==="
Expand Down
11 changes: 11 additions & 0 deletions Runner/suites/Connectivity/Bluetooth/BT_ON_OFF/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,11 @@ Select an adapter and tune the retry delays:
The command-line adapter overrides `BT_ADAPTER`. When neither is set, the
shared Bluetooth helper selects a usable runtime controller.

On CentOS, direct execution verifies the minimal `bluez`, `atheros-firmware`,
and `expect` package set before runtime validation. Existing complete images
avoid package-manager and network work. Debian and Ubuntu retain their existing
preparation behavior, while Yocto continues to use image-provided components.

## Validation contract

The test uses the exact BlueZ `Powered: yes|no` property as its power-state
Expand All @@ -46,6 +51,12 @@ Power ON completed with consecutive Powered=yes confirmations
The test fails when the requested stable state is not observed within the
bounded helper attempts. If a power-on attempt fails, the suite records
diagnostics and can perform the configured controlled recovery before retrying.
An all-zero runtime BD address remains a failure. Recovery uses
`btmgmt public-addr` with an authoritative address read from the adapter
device-tree node or from the exact Qualcomm NVM firmware selected by the kernel.
It never hardcodes or generates an address. If firmware was newly provisioned
and the HCI controller remains at `00:00:00:00:00:00`, reboot the target and
rerun the test.

## LAVA

Expand Down
8 changes: 5 additions & 3 deletions Runner/suites/Connectivity/Bluetooth/BT_ON_OFF/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,8 @@ test_result_init "$TESTNAME" "$RES_FILE" || exit 1
log_info "------------------------------------------------------------"
log_info "Starting $TESTNAME Testcase"
log_info "Config: BT_POWER_CYCLE_DELAY=${BT_POWER_CYCLE_DELAY}s BT_POWER_ON_ATTEMPTS=$BT_POWER_ON_ATTEMPTS BT_POWER_ON_RETRY_DELAY=${BT_POWER_ON_RETRY_DELAY}s BT_RESTART_SERVICE_ON_RETRY=$BT_RESTART_SERVICE_ON_RETRY"
if ! bt_prepare_ubuntu_stack; then
test_result_finish "FAIL" "$TESTNAME FAIL - Ubuntu Bluetooth stack preparation failed"
if ! bt_prepare_bluetooth_stack; then
test_result_finish "FAIL" "$TESTNAME FAIL - Bluetooth stack preparation failed"
fi

log_info "Checking dependency: bluetoothctl"
Expand All @@ -165,7 +165,9 @@ if ! bt_ensure_runtime_ready \
"$BT_RUNTIME_READY_WAIT" \
"$BT_RUNTIME_RECOVERY_WAIT" \
"$BT_RUNTIME_RECOVERY_ATTEMPTS"; then
test_result_finish "FAIL" "Bluetooth runtime remained unusable after bounded recovery attempts"
test_result_finish \
"FAIL" \
"${BT_RUNTIME_FAILURE_REASON:-Bluetooth runtime remained unusable after bounded recovery attempts}"
fi

ADAPTER="$BT_RUNTIME_READY_ADAPTER"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ Required runtime support:
/sys/class/bluetooth/hci*
```

On CentOS, direct execution verifies `bluez`, `atheros-firmware`, and `expect`
before validation. If an attached controller exposes an all-zero address, the
shared helper uses `btmgmt public-addr` with an authoritative address from
device tree or the exact Qualcomm NVM firmware selected by the kernel. It does
not hardcode or generate a Bluetooth address.

The test automatically skips if no HCI adapter is found.

## Basic usage
Expand Down
8 changes: 5 additions & 3 deletions Runner/suites/Connectivity/Bluetooth/BT_SCAN/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,8 @@ test_result_init "$TESTNAME" "$RES_FILE" || exit 1

log_info "------------------------------------------------------------"
log_info "Starting $TESTNAME Testcase"
if ! bt_prepare_ubuntu_stack; then
test_result_finish "FAIL" "$TESTNAME FAIL - Ubuntu Bluetooth stack preparation failed"
if ! bt_prepare_bluetooth_stack; then
test_result_finish "FAIL" "$TESTNAME FAIL - Bluetooth stack preparation failed"
fi

log_info "Checking dependencies: bluetoothctl pgrep"
Expand All @@ -150,7 +150,9 @@ if ! bt_ensure_runtime_ready \
"$BT_RUNTIME_READY_WAIT" \
"$BT_RUNTIME_RECOVERY_WAIT" \
"$BT_RUNTIME_RECOVERY_ATTEMPTS"; then
test_result_finish "FAIL" "Bluetooth runtime remained unusable after bounded recovery attempts"
test_result_finish \
"FAIL" \
"${BT_RUNTIME_FAILURE_REASON:-Bluetooth runtime remained unusable after bounded recovery attempts}"
fi

ADAPTER="$BT_RUNTIME_READY_ADAPTER"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,15 @@ When a whitelist is specified (CLI or `BT_WHITELIST_ENV`), only devices whose MA

## Troubleshooting

- Ensure `bluetoothctl`, `rfkill`, `expect`, and `hciconfig` are installed and in PATH.
- Ensure `bluetoothctl`, `rfkill`, and `expect` are installed and in PATH.
CentOS direct execution verifies `bluez`, `atheros-firmware`, and `expect`
before starting the test.
`hciconfig` is optional because current CentOS BlueZ packages omit that
deprecated utility. The test uses sysfs and `bluetoothctl` when it is absent.
- When an attached controller reports an all-zero address, the shared helper
invokes `btmgmt public-addr` with an authoritative address read from device
tree or the exact Qualcomm NVM firmware selected by the kernel. No address is
hardcoded or generated.
- Confirm the DUT’s Bluetooth adapter is present and powered on.
- For headless devices, ensure target is in discoverable/pairing mode.
- Inspect `scan.log` and `pair.log` for detailed errors.
Expand Down
18 changes: 14 additions & 4 deletions Runner/suites/Connectivity/Bluetooth/BT_SCAN_PAIR/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -177,21 +177,31 @@ if [ -z "$BT_MAC" ] && [ -z "$BT_NAME" ] && [ ! -f "./bt_device_list.txt" ]; the
test_result_finish "SKIP" "No Bluetooth target and no bt_device_list.txt were provided"
fi

if ! bt_prepare_ubuntu_stack; then
test_result_finish "FAIL" "$TESTNAME FAIL - Ubuntu Bluetooth stack preparation failed"
if ! bt_prepare_bluetooth_stack; then
test_result_finish "FAIL" "$TESTNAME FAIL - Bluetooth stack preparation failed"
fi

if ! check_dependencies bluetoothctl rfkill expect hciconfig; then
if ! check_dependencies \
bluetoothctl \
rfkill \
expect \
l2ping; then
test_result_finish "SKIP" "$TESTNAME SKIP - required Bluetooth tools are unavailable"
fi

if ! command -v hciconfig >/dev/null 2>&1; then
log_info "Optional hciconfig command is unavailable, using sysfs and bluetoothctl for adapter discovery"
fi

log_info "Ensuring Bluetooth runtime readiness before pairing"
if ! bt_ensure_runtime_ready \
"${BT_ADAPTER:-}" \
"$BT_RUNTIME_READY_WAIT" \
"$BT_RUNTIME_RECOVERY_WAIT" \
"$BT_RUNTIME_RECOVERY_ATTEMPTS"; then
test_result_finish "FAIL" "Bluetooth runtime remained unusable after bounded recovery attempts"
test_result_finish \
"FAIL" \
"${BT_RUNTIME_FAILURE_REASON:-Bluetooth runtime remained unusable after bounded recovery attempts}"
fi

BT_ADAPTER="$BT_RUNTIME_READY_ADAPTER"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ This test is useful for verifying basic WiFi firmware and driver readiness befor

- Required command-line utilities are available.
- The SoC model is detected from device tree when available.
- WiFi firmware is found under `/lib/firmware`.
- WiFi firmware is found under `/lib/firmware`, including readable symlinks
and kernel-supported `.xz` or `.zst` compressed files.
- The WiFi firmware family is detected.
- Family-specific runtime preparation succeeds.
- Family-specific modules are visible.
Expand Down Expand Up @@ -97,7 +98,8 @@ The test passes when:
The test skips when:

- Required tools are missing.
- No supported WiFi firmware is found under `/lib/firmware`.
- No supported uncompressed, `.xz`, or `.zst` WiFi firmware file or readable
symlink is found under `/lib/firmware`.

## FAIL criteria

Expand Down
3 changes: 2 additions & 1 deletion Runner/suites/Connectivity/WiFi/WiFi_Firmware_Driver/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ suite_rc=0

log_info "=== WiFi Firmware Detection ==="
if ! wifi_detect_firmware_info; then
log_skip "$TESTNAME SKIP - No ath12k/ath11k/ath10k WiFi firmware found under /lib/firmware"
log_skip \
"$TESTNAME SKIP - No readable ath12k/ath11k/ath10k WiFi firmware asset found under /lib/firmware, including .xz and .zst files"
echo "$TESTNAME SKIP" >"$RES_FILE"
exit 0
fi
Expand Down
Loading
Loading