audio: copier: fix 24-bit channel remap conversion#10749
Open
wjablon1 wants to merge 1 commit intothesofproject:mainfrom
Open
audio: copier: fix 24-bit channel remap conversion#10749wjablon1 wants to merge 1 commit intothesofproject:mainfrom
wjablon1 wants to merge 1 commit intothesofproject:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the IPC4 copier converter selection so that, when channel remapping is required, 24-bit audio carried in 32-bit containers uses the correct 24-bit conversion/remap handlers (instead of being treated as true 32-bit PCM), avoiding incorrect bit-shifts during remap+convert operations.
Changes:
- In the channel remap path, normalize
in/outfromS32_LEtoS24_4LE/S24_4LE_MSBwhen the valid bit depth is 24-bit in a 32-bit container. - Keep existing special-casing for 16-bit-in-32 (
S16_4LE) in the remap path.
Comment on lines
+569
to
+576
| if ((in_valid == SOF_IPC_FRAME_S24_4LE || | ||
| in_valid == SOF_IPC_FRAME_S24_4LE_MSB) && | ||
| in == SOF_IPC_FRAME_S32_LE) | ||
| in = in_valid; | ||
| if ((out_valid == SOF_IPC_FRAME_S24_4LE || | ||
| out_valid == SOF_IPC_FRAME_S24_4LE_MSB) && | ||
| out == SOF_IPC_FRAME_S32_LE) | ||
| out = out_valid; |
Contributor
Author
There was a problem hiding this comment.
Probably the "in_valid == SOF_IPC_FRAME_S24_4LE_MSB" condition is excessive as the S24_4LE_MSB format has the same conversion handlers as S32_LE. Will fix it
serhiy-katsyuba-intel
approved these changes
May 7, 2026
Select appropriate conversion handlers for 24-bit audio in 32-bit containers with channel remapping Signed-off-by: Wojciech Jablonski <wojciech.jablonski@intel.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.
Select appropriate conversion handlers for 24-bit audio in 32-bit containers with channel remapping