]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
rtc: msm6242: Fix reading of 10-hour digit
authorKars de Jong <jongk@linux-m68k.org>
Sat, 16 Nov 2019 11:05:48 +0000 (12:05 +0100)
committerKhalid Elmously <khalid.elmously@canonical.com>
Fri, 14 Feb 2020 05:29:37 +0000 (00:29 -0500)
commit3d6f3c6bbabf68eb39166c23513c29fdeefaf44f
tree417e4109c61ed775c9c41c2a8195d660af4884ec
parentdbd8d40a7e007b436690df27b914a2e7346279f2
rtc: msm6242: Fix reading of 10-hour digit

BugLink: https://bugs.launchpad.net/bugs/1861934
commit e34494c8df0cd96fc432efae121db3212c46ae48 upstream.

The driver was reading the wrong register as the 10-hour digit due to
a misplaced ')'. It was in fact reading the 1-second digit register due
to this bug.

Also remove the use of a magic number for the hour mask and use the define
for it which was already present.

Fixes: 4f9b9bba1dd1 ("rtc: Add an RTC driver for the Oki MSM6242")
Tested-by: Kars de Jong <jongk@linux-m68k.org>
Signed-off-by: Kars de Jong <jongk@linux-m68k.org>
Link: https://lore.kernel.org/r/20191116110548.8562-1-jongk@linux-m68k.org
Reviewed-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/rtc/rtc-msm6242.c