ASoC: au1x: Fix timeout tests in au1xac97c_ac97_read()
authorDan Carpenter <dan.carpenter@oracle.com>
Mon, 15 Jan 2018 08:08:38 +0000 (11:08 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 26 Apr 2018 09:02:03 +0000 (11:02 +0200)
commit3f3017fa1540cf5eb6bd6af1f76f76a831c99652
treecc559b095f68b0ce5fc09cbfac3710b72f9cd02c
parentd3222cfc0b58f022a17f5f936b5c5d2df8a3f868
ASoC: au1x: Fix timeout tests in au1xac97c_ac97_read()

[ Upstream commit 123af9043e93cb6f235207d260d50f832cdb5439 ]

The loop timeout doesn't work because it's a post op and ends with "tmo"
set to -1.  I changed it from a post-op to a pre-op and I changed the
initial the starting value from 5 to 6 so we still iterate 5 times.  I
left the other as it was because it's a large number.

Fixes: b3c70c9ea62a ("ASoC: Alchemy AC97C/I2SC audio support")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
sound/soc/au1x/ac97c.c