rtc: max77686: Add an indirection level to access RTC registers
authorJavier Martinez Canillas <javier@osg.samsung.com>
Wed, 27 Jan 2016 03:36:41 +0000 (00:36 -0300)
committerAlexandre Belloni <alexandre.belloni@free-electrons.com>
Thu, 4 Feb 2016 22:42:08 +0000 (23:42 +0100)
commit90a5698a86ba968e6fbe2e03cfab9ffc18a17186
tree96669368152596011457d4ec23c5e63e3fd14150
parent01ea01b35120663a8ec727566e757ea6efdbd2d1
rtc: max77686: Add an indirection level to access RTC registers

The max77686 driver is generic enough that can be used for other
Maxim RTC IP blocks but these might not have the same registers
layout so instead of accessing the registers directly, add a map
to translate offsets to the real registers addresses for each IP.

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
Acked-by: Laxman Dewangan <ldewangan@nvidia.com>
Tested-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Reviewed-by: Andi Shyti <andi.shyti@samsung.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
drivers/rtc/rtc-max77686.c