Skip to content
Commit 509451ac authored by Emmanuel Gil Peyrot's avatar Emmanuel Gil Peyrot Committed by Alexandre Belloni
Browse files

rtc: gamecube: Always reset HW_SRNPROT after read



This register would fail to be reset if reading the RTC bias failed for
whichever reason.  This commit reorganises the code around to
unconditionally write it back to its previous value, unmap it, and
return the result of regmap_read(), which makes it both simpler and more
correct in the error case.

Signed-off-by: default avatarEmmanuel Gil Peyrot <linkmauve@linkmauve.fr>
Signed-off-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/r/20220823130702.1046-1-linkmauve@linkmauve.fr
parent 1e2585b4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment