From c4785bafac0c2dd7909c8cc193facd704f2cc099 Mon Sep 17 00:00:00 2001 From: Seppo Ingalsuo Date: Tue, 2 Jun 2026 14:37:19 +0300 Subject: [PATCH 1/4] scripts: build-alsa-tools.sh: Update alsa-lib and alsa-utils This change updates to Release v1.2.16, needed for extended sample rates add to SOF topologies. Signed-off-by: Seppo Ingalsuo --- scripts/build-alsa-tools.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/build-alsa-tools.sh b/scripts/build-alsa-tools.sh index 5e1e7f75d39d..01cdb761ee1b 100755 --- a/scripts/build-alsa-tools.sh +++ b/scripts/build-alsa-tools.sh @@ -16,8 +16,8 @@ declare -a REPOS=( # the repository if this commit ID is not found. Leave empty to skip. # This array order must align with REPO array above. declare -a COMMIT_ID=( - "df8f1cc1ec9d9ee15be5e2c23ad25b9389fd8766" - "09550cd393b1a7d307ee6f26637b1ed7bd275e38" + "08b532cd3da9ac8f683bcb4e4beb9b74c39c1782" + "9feb22ba45b48729729c8d194aaf1bc082a6842a" # Add more IDs here... ) From 140b0011dcbaea51d5c98cf0457209654fc94a62 Mon Sep 17 00:00:00 2001 From: Seppo Ingalsuo Date: Tue, 2 Jun 2026 17:31:25 +0300 Subject: [PATCH 2/4] github: workflows: testbench: Update alsa-lib and alsa-lib This patch updates the commits to Release v1.2.16. It is needed to build topologies with extended sample rates. The autoconf install is needed due to dependency from alsa-lib. Signed-off-by: Seppo Ingalsuo --- .github/workflows/testbench.yml | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/.github/workflows/testbench.yml b/.github/workflows/testbench.yml index 290fe8e56dee..d54b1db331db 100644 --- a/.github/workflows/testbench.yml +++ b/.github/workflows/testbench.yml @@ -49,12 +49,27 @@ jobs: octave octave-signal automake autoconf libtool gettext libasound2-dev + # Ubuntu 24.04 ships autoconf 2.71, but current alsa-lib/alsa-utils + # require >= 2.72. Build a newer autoconf from the GNU release + # tarball and install it into /usr/local (ahead of /usr/bin in PATH). + - name: Install autoconf 2.72 + run: | + cd ${GITHUB_WORKSPACE} + wget -q https://ftp.gnu.org/gnu/autoconf/autoconf-2.72.tar.gz + tar xf autoconf-2.72.tar.gz + cd autoconf-2.72 + ./configure --prefix=/usr/local + make -j"$(nproc)" + sudo make install + hash -r + autoconf --version | head -n1 + - name: Build Alsa-lib run: | cd ${GITHUB_WORKSPACE} git clone https://github.com/thesofproject/alsa-lib.git cd alsa-lib - git checkout df8f1cc1ec9d9ee15be5e2c23ad25b9389fd8766 -b build + git checkout 08b532cd3da9ac8f683bcb4e4beb9b74c39c1782 -b build ./gitcompile --prefix=${GITHUB_WORKSPACE}/tools make install @@ -63,7 +78,7 @@ jobs: cd ${GITHUB_WORKSPACE} git clone https://github.com/thesofproject/alsa-utils.git cd alsa-utils - git checkout 0ffa105942a06cdfa98e5918b8dc82e3cac12792 -b build + git checkout 9feb22ba45b48729729c8d194aaf1bc082a6842a -b build ./gitcompile --prefix=${GITHUB_WORKSPACE}/tools \ --with-alsa-prefix=${GITHUB_WORKSPACE}/tools \ --with-alsa-inc-prefix=${GITHUB_WORKSPACE}/tools/include \ From aa2ea3659af48c21582f2a9272de349673bccc33 Mon Sep 17 00:00:00 2001 From: Seppo Ingalsuo Date: Fri, 5 Jun 2026 18:13:51 +0300 Subject: [PATCH 3/4] workflows: tools: build natively instead of in docker container The pre-built thesofproject/sof docker image carries an older alsa-lib / alsa-utils that no longer matches the versions required to build the current SOF user-space tools (in particular alsatplg used by the topology2 build). This patch moves the user-space tools build off docker and build it directly on the ubuntu-24.04 runner. - install the toolchain via apt - bootstrap autoconf 2.72 (Ubuntu 24.04 ships 2.71) - build the SOF forks of alsa-lib and alsa-utils at the same pinned commits used by testbench.yml - run scripts/build-tools.sh with PKG_CONFIG_PATH / LD_LIBRARY_PATH / PATH pointed at the freshly built ALSA tree The SOF-alsa-plugin job in the same workflow was already native and is left unchanged. The only consumer of this reusable workflow (daily-tests.yml) is unaffected by the internal switch. Signed-off-by: Seppo Ingalsuo --- .github/workflows/tools.yml | 66 +++++++++++++++++++++++++++++++------ 1 file changed, 56 insertions(+), 10 deletions(-) diff --git a/.github/workflows/tools.yml b/.github/workflows/tools.yml index 7c70e93ddb5f..825b571321d8 100644 --- a/.github/workflows/tools.yml +++ b/.github/workflows/tools.yml @@ -13,25 +13,71 @@ permissions: jobs: # This is not the same as building every ./build-tools.sh option. top-level_default_CMake_target_ALL: - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 with: filter: 'tree:0' + path: sof + + - name: apt get + run: sudo apt-get update && + sudo apt-get -y install ninja-build + automake autoconf libtool gettext libasound2-dev + pkg-config + + # Ubuntu 24.04 ships autoconf 2.71, but current alsa-lib/alsa-utils + # require >= 2.72. Build a newer autoconf from the GNU release + # tarball and install it into /usr/local (ahead of /usr/bin in PATH). + - name: Install autoconf 2.72 + run: | + cd ${GITHUB_WORKSPACE} + wget -q https://ftp.gnu.org/gnu/autoconf/autoconf-2.72.tar.gz + tar xf autoconf-2.72.tar.gz + cd autoconf-2.72 + ./configure --prefix=/usr/local + make -j"$(nproc)" + sudo make install + hash -r + autoconf --version | head -n1 + + - name: Build Alsa-lib + run: | + cd ${GITHUB_WORKSPACE} + git clone https://github.com/thesofproject/alsa-lib.git + cd alsa-lib + git checkout 08b532cd3da9ac8f683bcb4e4beb9b74c39c1782 -b build + ./gitcompile --prefix=${GITHUB_WORKSPACE}/tools + make install - # The ALSA version in Ubuntu 20.04 is buggy - # (https://github.com/thesofproject/sof/issues/2543) and likely - # getting out of date soon - - name: docker - run: docker pull thesofproject/sof && docker tag thesofproject/sof sof + - name: Build Alsa-utils + run: | + cd ${GITHUB_WORKSPACE} + git clone https://github.com/thesofproject/alsa-utils.git + cd alsa-utils + git checkout 9feb22ba45b48729729c8d194aaf1bc082a6842a -b build + ./gitcompile --prefix=${GITHUB_WORKSPACE}/tools \ + --with-alsa-prefix=${GITHUB_WORKSPACE}/tools \ + --with-alsa-inc-prefix=${GITHUB_WORKSPACE}/tools/include \ + --with-sysroot=${GITHUB_WORKSPACE}/tools \ + --with-udev-rules-dir=${GITHUB_WORKSPACE}/tools \ + PKG_CONFIG_PATH=${GITHUB_WORKSPACE}/tools \ + LDFLAGS=-L${GITHUB_WORKSPACE}/tools/lib \ + --disable-old-symbols \ + --enable-alsatopology \ + --with-asound-state-dir=${GITHUB_WORKSPACE}/tools/var/lib/alsa \ + --with-systemdsystemunitdir=${GITHUB_WORKSPACE}/tools/lib/systemd/system + make install # For some reason gcc has more warnings in Release mode - name: build-tools - run: CMAKE_BUILD_TYPE=Release ./scripts/docker-run.sh - ./scripts/build-tools.sh || + env: + PKG_CONFIG_PATH: ${{ github.workspace }}/tools/lib/pkgconfig + LD_LIBRARY_PATH: ${{ github.workspace }}/tools/lib + PATH: ${{ github.workspace }}/tools/bin:/usr/local/bin:/usr/bin:/bin + run: CMAKE_BUILD_TYPE=Release ./sof/scripts/build-tools.sh || VERBOSE=1 NO_PROCESSORS=1 USE_XARGS=no - CMAKE_BUILD_TYPE=Release ./scripts/docker-run.sh - ./scripts/build-tools.sh + CMAKE_BUILD_TYPE=Release ./sof/scripts/build-tools.sh SOF-alsa-plugin: From c8f9145c4573f6b9322a77a388a5936b04c5e74d Mon Sep 17 00:00:00 2001 From: Seppo Ingalsuo Date: Wed, 4 Mar 2026 14:39:06 +0200 Subject: [PATCH 4/4] Tools: Topology2: Add 24 kHz rate to topologies with SRC This patch adds the missing 24 kHz rate that is used with MPEG-2 standard based and other codecs. The support started with Linux kernel 6.12. Note: Build of these topologies needs alsa-lib version TBD. Signed-off-by: Seppo Ingalsuo --- tools/topology/topology2/cavs-benchmark-hda.conf | 4 ++-- tools/topology/topology2/cavs-benchmark-sdw.conf | 4 ++-- tools/topology/topology2/cavs-nocodec.conf | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tools/topology/topology2/cavs-benchmark-hda.conf b/tools/topology/topology2/cavs-benchmark-hda.conf index 95ab67431812..e06f21ea9d49 100644 --- a/tools/topology/topology2/cavs-benchmark-hda.conf +++ b/tools/topology/topology2/cavs-benchmark-hda.conf @@ -195,7 +195,7 @@ Object.PCM.pcm [ direction "playback" name $ANALOG_PLAYBACK_PCM formats 'S32_LE,S24_LE,S16_LE' - rates "8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000" + rates "8000,11025,16000,22050,24000,32000,44100,48000,64000,88200,96000,176400,192000" channels_min $BENCH_PCM_CHANNELS_MIN channels_max $BENCH_PCM_CHANNELS_MAX } @@ -203,7 +203,7 @@ Object.PCM.pcm [ direction "capture" name $ANALOG_CAPTURE_PCM formats 'S32_LE,S24_LE,S16_LE' - rates "8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000" + rates "8000,11025,16000,22050,24000,32000,44100,48000,64000,88200,96000,176400,192000" channels_min $BENCH_PCM_CHANNELS_MIN channels_max $BENCH_PCM_CHANNELS_MAX } diff --git a/tools/topology/topology2/cavs-benchmark-sdw.conf b/tools/topology/topology2/cavs-benchmark-sdw.conf index 1705facb4cc0..ee81baf23772 100644 --- a/tools/topology/topology2/cavs-benchmark-sdw.conf +++ b/tools/topology/topology2/cavs-benchmark-sdw.conf @@ -137,7 +137,7 @@ Object.PCM.pcm [ Object.PCM.pcm_caps.1 { name $ANALOG_PLAYBACK_PCM formats 'S16_LE,S24_LE,S32_LE' - rates "8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000" + rates "8000,11025,16000,22050,24000,32000,44100,48000,64000,88200,96000,176400,192000" channels_min $BENCH_PCM_CHANNELS_MIN channels_max $BENCH_PCM_CHANNELS_MAX } @@ -153,7 +153,7 @@ Object.PCM.pcm [ Object.PCM.pcm_caps.1 { name $ANALOG_CAPTURE_PCM formats 'S16_LE,S24_LE,S32_LE' - rates "8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000" + rates "8000,11025,16000,22050,24000,32000,44100,48000,64000,88200,96000,176400,192000" channels_min $BENCH_PCM_CHANNELS_MIN channels_max $BENCH_PCM_CHANNELS_MAX } diff --git a/tools/topology/topology2/cavs-nocodec.conf b/tools/topology/topology2/cavs-nocodec.conf index fea906f98741..1d3f50a989dd 100644 --- a/tools/topology/topology2/cavs-nocodec.conf +++ b/tools/topology/topology2/cavs-nocodec.conf @@ -1698,14 +1698,14 @@ IncludeByKey.PASSTHROUGH { direction "playback" name "SSP2 Playback" formats 'S16_LE,S24_LE,S32_LE' - rates "8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000" + rates "8000,11025,16000,22050,24000,32000,44100,48000,64000,88200,96000,176400,192000" } Object.PCM.pcm_caps.2 { direction "capture" name "SSP2 Capture" formats 'S16_LE,S24_LE,S32_LE' - rates "8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000" + rates "8000,11025,16000,22050,24000,32000,44100,48000,64000,88200,96000,176400,192000" } } ]