rtc-at32ap700x: fix bug in at32_rtc_readalarm()
rtc-at32ap700x: fix bug in at32_rtc_readalarm()

alarm->pending indicates whether there's an alarm that has actually been
triggered, not whether we're waiting for it.  alarm->enabled indicates
that.

Also add missing locking around reading the RTC registers.

Signed-off-by: Haavard Skinnemoen <af8c0cf3411930951fa86926b241df32af99fdb9@atmel.com>
Signed-off-by: Alessandro Zummo <f0b9bd96bf07bfecc189c62159960134588fafe5@towertech.it>
Cc: Hans-Christian Egtvedt <3205290bd1d4a909d3b1f9e99f4a85bafd04fac3@atmel.com>
Cc: David Brownell <e543181633fc0fc2787945ef377537d9112d0c96@pacbell.net>
Signed-off-by: Andrew Morton <5c1e68b099950c134891f0b6e179498a8ebe9cf9@linux-foundation.org>
Signed-off-by: Linus Torvalds <69652caca27c8b940640ad396ab71f93cacec34f@linux-foundation.org>

TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas