ASoC: mediatek: common: Fix refcount leak in parse_dai_link_info
Add missing of_node_put()s before the returns to balance of_node_get()s and of_node_put()s, which may get unbalanced in case the for loop 'for_each_available_child_of_node' returns early. Fixes: 4302187d ("ASoC: mediatek: common: add soundcard driver common code") Reported-by: kernel test robot <lkp@intel.com> Reported-by: Julia Lawall <julia.lawall@inria.fr> Link: https://lore.kernel.org/r/202304090504.2K8L6soj-lkp@intel.com/Signed-off-by: Aashish Sharma <shraash@google.com> Reviewed-by: Guenter Roeck <groeck@chromium.org> Reviewed-by: Trevor Wu <trevor.wu@mediatek.com> Link: https://lore.kernel.org/r/20230411003431.4048700-1-shraash@google.comSigned-off-by: Mark Brown <broonie@kernel.org>
Showing
Please register or sign in to comment