ASoC: simple-card-utils: fixup asoc_simple_card_get_dai_id() counting
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Fri, 30 Nov 2018 02:04:13 +0000 (02:04 +0000)
committerMark Brown <broonie@kernel.org>
Tue, 4 Dec 2018 16:28:03 +0000 (16:28 +0000)
commitb6f3fc005a2c8b425d7a0973b43bef05890bf479
tree969a79165d068bd55b81cb2fe14a68b82e63ac87
parent538a4ffea3f719ed8f853f78826e360aee5fe9d7
ASoC: simple-card-utils: fixup asoc_simple_card_get_dai_id() counting

asoc_simple_card_get_dai_id() returns DAI ID, but it is based on
DT node's "endpoint" position.
Almost all cases 1 port has 1 endpoint, thus, it was no problem.
But in reality, port : endpoint = 1 : N, thus, counting endpoint
is BUG, it should based on "port" ID.
This patch fixup it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/generic/simple-card-utils.c