-
Charles Keepax authored
The loop checking PDN_DONE doesn't check the return value from regmap_read, nor does it initialise val. This means if regmap_read fails val will be checked for the PDN_DONE bit whilst being uninitialised. Fix this up by switching to regmap_read_poll_timeout which tidies up the code and avoids the uninitialised variable. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20210914141349.30218-1-ckeepax@opensource.cirrus.comSigned-off-by: Mark Brown <broonie@kernel.org>
c2f14cc2