lkml.org 
[lkml]   [2020]   [Dec]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v0] ASoC: rsnd: core: Check convert rate in rsnd_hw_params

Hi Mikhail

Thank you for your patch

> + switch (rsnd_mod_id(src_mod)) {
> + /*
> + * SRC0 can downsample 4, 6 and 8 channel audio up to 4 times.
> + * SRC1, SRC3 and SRC4 can downsample 4 channel audio
> + * up to 4 times.
> + * SRC1, SRC3 and SRC4 can downsample 6 and 8 channel audio
> + * no more than twice.
> + */
> + case 1:
> + case 3:
> + case 4:
> + if (channel > 4) {
> + k_down = 2;
> + break;
> + }
> + case 0:
> + if (channel > 2)
> + k_down = 4;
> + break;
> +
> + /* Other SRC units do not support more than 2 channels */
> + default:
> + if (channel > 2)
> + return -EINVAL;
> + }

I think you want to add "fallthrough" between case 1/3/4 and case 0 ?

Thank you for your help !!

Best regards
---
Kuninori Morimoto

\
 
 \ /
  Last update: 2020-12-02 23:59    [W:0.937 / U:1.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site