Skip to content
Commit 340327a6 authored by Jon Medhurst (Tixy)'s avatar Jon Medhurst (Tixy) Committed by Mark Brown
Browse files

ASoC: hdmi-codec: Fix hdmi_of_xlate_dai_name when #sound-dai-cells = <0>

If a DAI specifies "#sound-dai-cells = <0>" in device-tree then
hdmi_of_xlate_dai_name() will be called with zero args, which it isn't
implemented to cope with. The resulting use of an uninitialised variable
for the id will usually result in an error like:

  asoc-simple-card sound: parse error -11
  asoc-simple-card: probe of sound failed with error -11

Fix this by using and id of zero if no arg is provided.

Fixes: 9731f82d

 ("ASoC: hdmi-codec: enable multi probe for same device")

Signed-off-by: default avatarJon Medhurst <tixy@linaro.org>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 1001354c
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment