lkml.org 
[lkml]   [2022]   [Jul]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 5.10 039/112] ASoC: Intel: Skylake: Correct the ssp rate discovery in skl_get_ssp_clks()
    Date
    From: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>

    [ Upstream commit 219af251bd1694bce1f627d238347d2eaf13de61 ]

    The present flag is only set once when one rate has been found to be saved.
    This will effectively going to ignore any rate discovered at later time and
    based on the code, this is not the intention.

    Fixes: bc2bd45b1f7f3 ("ASoC: Intel: Skylake: Parse nhlt and register clock device")
    Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
    Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com>
    Link: https://lore.kernel.org/r/20220630065638.11183-2-peter.ujfalusi@linux.intel.com
    Signed-off-by: Mark Brown <broonie@kernel.org>
    Signed-off-by: Sasha Levin <sashal@kernel.org>
    ---
    sound/soc/intel/skylake/skl-nhlt.c | 3 ++-
    1 file changed, 2 insertions(+), 1 deletion(-)

    diff --git a/sound/soc/intel/skylake/skl-nhlt.c b/sound/soc/intel/skylake/skl-nhlt.c
    index 87c891c46291..c668e10baade 100644
    --- a/sound/soc/intel/skylake/skl-nhlt.c
    +++ b/sound/soc/intel/skylake/skl-nhlt.c
    @@ -201,7 +201,6 @@ static void skl_get_ssp_clks(struct skl_dev *skl, struct skl_ssp_clk *ssp_clks,
    struct nhlt_fmt_cfg *fmt_cfg;
    struct wav_fmt_ext *wav_fmt;
    unsigned long rate;
    - bool present = false;
    int rate_index = 0;
    u16 channels, bps;
    u8 clk_src;
    @@ -215,6 +214,8 @@ static void skl_get_ssp_clks(struct skl_dev *skl, struct skl_ssp_clk *ssp_clks,
    return;

    for (i = 0; i < fmt->fmt_count; i++) {
    + bool present = false;
    +
    fmt_cfg = &fmt->fmt_config[i];
    wav_fmt = &fmt_cfg->fmt_ext;

    --
    2.35.1


    \
     
     \ /
      Last update: 2022-07-19 14:21    [W:4.125 / U:0.112 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site