On Wed, 2014-03-26 at 08:10 +0100, Robert Baldyga wrote:
> This patch modifies mfd driver to use regmap for handling interrupts.
> It allows to simplify irq handling process. This modifications needed
> to make small changes in function drivers, which use interrupts.
>
> Signed-off-by: Robert Baldyga <[email protected]>
> ---
> drivers/mfd/Kconfig | 2 +-
> drivers/mfd/Makefile | 2 +-
> drivers/mfd/max77686-irq.c | 319
> ----------------------------------
> drivers/mfd/max77686.c | 54 +++++-
> drivers/rtc/rtc-max77686.c | 43 ++++-
> include/linux/mfd/max77686-private.h | 32 +++-
> 6 files changed, 119 insertions(+), 333 deletions(-)
> delete mode 100644 drivers/mfd/max77686-irq.c
(...)
> diff --git a/drivers/rtc/rtc-max77686.c b/drivers/rtc/rtc-max77686.c
> index 9efe118..b8bc412 100644
> --- a/drivers/rtc/rtc-max77686.c
> +++ b/drivers/rtc/rtc-max77686.c
> @@ -497,6 +497,25 @@ static struct regmap_config max77686_rtc_regmap_config =
> {
> .val_bits = 8,
> };
>
> +static const struct regmap_irq max77686_irqs_rtc[] = {
> + { .mask = RTC_INT_RTC60S_MASK, },
> + { .mask = RTC_INT_RTCA1_MASK, },
> + { .mask = RTC_INT_RTCA2_MASK, },
> + { .mask = RTC_INT_SMPL_MASK, },
> + { .mask = RTC_INT_RTC1S_MASK, },
> + { .mask = RTC_INT_WTSR_MASK, },
> +};
> +
> +static const struct regmap_irq_chip max77686_irq_chip_rtc = {
> + .name = "max77686-rtc",
> + .status_base = MAX77686_RTC_INT,
> + .mask_base = MAX77686_RTC_INTM,
> + .mask_invert = true,
> + .num_regs = 2,
I think there is only one RTC interrupt register (RTCINT).
Beside that, everything else looks fine.
Reviewed-by: Krzysztof Kozlowski <[email protected]>
Best regards,
Krzysztof
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/