]> git.baikalelectronics.ru Git - uboot.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)
commitdef609d512da8820c76ff3f737a5854e59de4c22
tree83405845a60efe6d368252c0406cbef7a249c5de
parente3b560f502f4c35295f86bf85f57ba4035e6fac5
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