Message ID | 1629796682-4170-4-git-send-email-sugar.zhang@rock-chips.com |
---|---|
State | New |
Headers | show |
Series | Patches to update for rockchip i2s | expand |
diff --git a/sound/soc/rockchip/rockchip_i2s.c b/sound/soc/rockchip/rockchip_i2s.c index 15e2690..90580dc 100644 --- a/sound/soc/rockchip/rockchip_i2s.c +++ b/sound/soc/rockchip/rockchip_i2s.c @@ -720,6 +720,11 @@ static int rockchip_i2s_probe(struct platform_device *pdev) soc_dai->capture.channels_max = val; } + if (of_property_read_bool(node, "rockchip,playback-only")) + soc_dai->capture.channels_min = 0; + else if (of_property_read_bool(node, "rockchip,capture-only")) + soc_dai->playback.channels_min = 0; + ret = devm_snd_soc_register_component(&pdev->dev, &rockchip_i2s_component, soc_dai, 1);
- 'rockchip,playback-only': support playback only. - 'rockchip,capture-only': support capture only. Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com> --- Changes in v2: None sound/soc/rockchip/rockchip_i2s.c | 5 +++++ 1 file changed, 5 insertions(+)