]> git.dujemihanovic.xyz Git - u-boot.git/commit
rtc: add dm_rtc_write() helper
authorRasmus Villemoes <rasmus.villemoes@prevas.dk>
Mon, 6 Jul 2020 20:01:11 +0000 (22:01 +0200)
committerHeiko Schocher <hs@denx.de>
Thu, 9 Jul 2020 04:02:44 +0000 (06:02 +0200)
commit09381829a231f5d2b95568f3178c2bd125a93fac
tree83405845a60efe6d368252c0406cbef7a249c5de
parentd8be08805bc03d53b0dd6953792fba543a4f3890
rtc: add dm_rtc_write() helper

Similar to dm_rtc_read(), introduce a helper that allows the caller to
write multiple consecutive 8-bit registers with one call. If the
driver provides the ->write method, use that, otherwise loop using
->write8.

Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heiko Schocher <hs@denx.de>
Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
drivers/rtc/rtc-uclass.c
include/rtc.h