topology2: uaol-generic: Tag DAI-copier formats as MSB_INTEGER - #11156
topology2: uaol-generic: Tag DAI-copier formats as MSB_INTEGER#11156ujfalusi wants to merge 1 commit into
Conversation
|
@kv2019i, @lgirdwood, 2.15 candidate |
There was a problem hiding this comment.
🟢 Approval recommended
The change is narrowly scoped, consistent with existing topology2 conventions for MSB-tagged link-facing formats, and cleanly isolates the behavior to the UAOL DAI-copier widgets without affecting host-facing formats.
Pull request overview
This PR fixes UAOL DAI-copier sample alignment by explicitly tagging the wire-facing side audio formats as SAMPLE_TYPE_MSB_INTEGER, bringing UAOL in line with other link types (HDA/SDW/SSP/DMIC) and preventing 24-bit audio from being effectively byte-shifted (quiet / reduced resolution).
Changes:
- Switch UAOL DAI-copier widgets in
uaol-generic.confto use new MSB-tagged format tables on their wire-facing side. - Add
uaol_output_audio_formats_msb.confanduaol_input_audio_formats_msb.confas MSB-tagged counterparts of the existing UAOL format tables. - Keep host-facing UAOL copier format tables unchanged (still defaulting to LSB alignment) to preserve standard ALSA conventions.
File summaries
| File | Description |
|---|---|
| tools/topology/topology2/platform/intel/uaol-generic.conf | Updates only the UAOL DAI-copier widgets to reference MSB-tagged format tables on the link-facing side. |
| tools/topology/topology2/include/formats/uaol_output_audio_formats_msb.conf | New MSB-tagged output audio format table (315 expanded formats) for UAOL wire-facing playback side. |
| tools/topology/topology2/include/formats/uaol_input_audio_formats_msb.conf | New MSB-tagged input audio format table (315 expanded formats) for UAOL wire-facing capture side. |
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
I need to remove the MSB flag for the S32 formats. |
afa5b77 to
2b1c8cf
Compare
The UAOL DAI copier's wire-facing audio formats never set out_sample_type/in_sample_type, so they defaulted to SAMPLE_TYPE_LSB_INTEGER. Every other link type (HDA, SoundWire, SSP, DMIC) tags its DAI copier side SAMPLE_TYPE_MSB_INTEGER instead, which is what makes the copier left-justify 24-bit samples before handing them to the link. Without it, 24-bit UAOL audio played back right shifted by a byte: quiet and missing the top bits of resolution. Add uaol_output_audio_formats_msb.conf and uaol_input_audio_formats_msb.conf, copies of the existing tables with SAMPLE_TYPE_MSB_INTEGER added, and point only the two DAI-copier widgets (playback output, capture input) at them. The host-copier widgets keep the original tables, since their host-facing side has to stay in the standard LSB-aligned ALSA convention. The 32 bit valid depth stays LSB-tagged. Left-justifying is a no-op when every bit is valid, and sof_ipc4_fmt_cfg_to_type() only takes the tag into account for 8 and 32 bits, so an MSB tag there would never match the LSB reference the driver derives from an S32_LE PCM: every S32_LE stream failed with "Unsupported audio format", at any rate. Split the 24 32 valid depth list into an MSB-tagged 24 bit entry and an LSB-tagged 32 bit one, which leaves the format count unchanged. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
|
Changes since v1:
|
PR 11156: test resultsRun date: 2026-09-02 12:22 UTC Tested commit: 2b1c8cfd4e3b05acc91d564ab8346ef3a62292f0 |
The UAOL DAI copier's wire-facing audio formats never set out_sample_type/in_sample_type, so they defaulted to SAMPLE_TYPE_LSB_INTEGER. Every other link type (HDA, SoundWire, SSP, DMIC) tags its DAI copier side SAMPLE_TYPE_MSB_INTEGER instead, which is what makes the copier left-justify 24-bit samples before handing them to the link. Without it, 24-bit UAOL audio played back right shifted by a byte: quiet and missing the top bits of resolution.
Add uaol_output_audio_formats_msb.conf and
uaol_input_audio_formats_msb.conf, copies of the existing tables with SAMPLE_TYPE_MSB_INTEGER added, and point only the two DAI-copier widgets (playback output, capture input) at them. The host-copier widgets keep the original tables, since their host-facing side has to stay in the standard LSB-aligned ALSA convention.