linux/drivers/rtc/rtc-bd70528.c

// SPDX-License-Identifier: GPL-2.0-or-later
//
// Copyright (C) 2018 ROHM Semiconductors
//
// RTC driver for ROHM BD71828 and BD71815 PMIC

#include <linux/bcd.h>
#include <linux/mfd/rohm-bd71815.h>
#include <linux/mfd/rohm-bd71828.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/platform_device.h>
#include <linux/regmap.h>
#include <linux/rtc.h>

/*
 * On BD71828 and BD71815 the ALM0 MASK is 14 bytes after the ALM0
 * block start
 */
#define BD718XX_ALM_EN_OFFSET

/*
 * We read regs RTC_SEC => RTC_YEAR
 * this struct is ordered according to chip registers.
 * Keep it u8 only (or packed) to avoid padding issues.
 */
struct bd70528_rtc_day {} __packed;

struct bd70528_rtc_data {} __packed;

struct bd71828_rtc_alm {} __packed;

struct bd70528_rtc {};

static inline void tmday2rtc(struct rtc_time *t, struct bd70528_rtc_day *d)
{}

static inline void tm2rtc(struct rtc_time *t, struct bd70528_rtc_data *r)
{}

static inline void rtc2tm(struct bd70528_rtc_data *r, struct rtc_time *t)
{}

static int bd71828_set_alarm(struct device *dev, struct rtc_wkalrm *a)
{}

static int bd71828_read_alarm(struct device *dev, struct rtc_wkalrm *a)
{}

static int bd71828_set_time(struct device *dev, struct rtc_time *t)
{}

static int bd70528_get_time(struct device *dev, struct rtc_time *t)
{}

static int bd71828_alm_enable(struct device *dev, unsigned int enabled)
{}

static const struct rtc_class_ops bd71828_rtc_ops =;

static irqreturn_t alm_hndlr(int irq, void *data)
{}

static int bd70528_probe(struct platform_device *pdev)
{}

static const struct platform_device_id bd718x7_rtc_id[] =;
MODULE_DEVICE_TABLE(platform, bd718x7_rtc_id);

static struct platform_driver bd70528_rtc =;

module_platform_driver();

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();
MODULE_ALIAS();