ASoC: samsung: i2s: Use specific name for i2s dais
authorJaechul Lee <jcsing.lee@samsung.com>
Wed, 6 Sep 2017 01:04:13 +0000 (10:04 +0900)
committerJunghoon Kim <jhoon20.kim@samsung.com>
Thu, 14 Feb 2019 05:56:22 +0000 (14:56 +0900)
commit822d61610aa28d3900e6b9245167a9c3acb7e1b8
tree7895025294686ae9b97221a4e895eb1638a5bbce
parent4fdd301e3948a4dfffb030d4b0931977a93e90b7
ASoC: samsung: i2s: Use specific name for i2s dais

Add specific dais name when components are registered. Component and dai
name will follow their parent dev name, if the name isn't described.  In
case of this driver, each dais will have same name like '11440000.i2s0' by
fmt_single_name function.

The problem having same name is that TM2 machine driver can't detect
capture devices correctly. Machine driver doesn't know which one is proper
to use for cpu dai. The driver just selects to use 'samsung-i2c-sec' that
doesn't have capture functionality because the component of
samsung-i2s-sec is located in the first of the component_list.

I add dai name like 'samsung-i2s', 'samsung-i2s-sec' for each dais. The
reason why adding dai id to 1 is that it doesn't allow to use particular
dai name in case of when I use 0 for dai id.

Signed-off-by: Jaechul Lee <jcsing.lee@samsung.com>
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/samsung/i2s.c
sound/soc/samsung/i2s.h