ASoC: SDCA: correct the calculation of the maximum init table size
Subsystems (3)
PATCH 1/2 ASoC: SDCA: correct the calculation of the maximum init table size
From: Shuming Fan <[email protected]>
One initial setting is 5 bytes, so num_init_writes should divide by 5.
--- sound/soc/sdca/sdca_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/soc/sdca/sdca_functions.c +1 -1
@@ -212,7 +212,7 @@ static int find_sdca_init_table(struct device *dev, }else if (num_init_writes %sizeof (*raw) !=0 ) {dev_err (dev,"%pfwP: init table size invalid\n" , function_node);return -EINVAL ; - }else if (num_init_writes >SDCA_MAX_INIT_COUNT ) { + }else if ((num_init_writes /sizeof (*raw)) >SDCA_MAX_INIT_COUNT ) {dev_err (dev,"%pfwP: maximum init table size exceeded\n" , function_node);return -EINVAL ; }
Signature · 1 line
2.34.1
Quoted 6 lines · On Mon, Jul 21, 2025 at 07:23:34PM +0800, [email protected] wrote:
From: Shuming Fan <[email protected]>
One initial setting is 5 bytes, so
num_init_writesshould divide by 5.Signed-off-by Shuming Fan <[email protected]>---
Thanks,
Charles
Mark Brown
maintainerQuoted 3 lines · On Mon, 21 Jul 2025 19:23:34 +0800, [email protected] wrote:
One initial setting is 5 bytes, so
num_init_writesshould divide by 5.
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/2] ASoC: SDCA: correct the calculation of the maximum init table size
commit: 9e55f1192648a5b327f03c60e411126b3d19c5c5
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark