linux/drivers/rtc/rtc-m48t86.c

// SPDX-License-Identifier: GPL-2.0-only
/*
 * ST M48T86 / Dallas DS12887 RTC driver
 * Copyright (c) 2006 Tower Technologies
 *
 * Author: Alessandro Zummo <[email protected]>
 *
 * This drivers only supports the clock running in BCD and 24H mode.
 * If it will be ever adapted to binary and 12H mode, care must be taken
 * to not introduce bugs.
 */

#include <linux/module.h>
#include <linux/mod_devicetable.h>
#include <linux/rtc.h>
#include <linux/platform_device.h>
#include <linux/bcd.h>
#include <linux/io.h>

#define M48T86_SEC
#define M48T86_SECALRM
#define M48T86_MIN
#define M48T86_MINALRM
#define M48T86_HOUR
#define M48T86_HOURALRM
#define M48T86_DOW
#define M48T86_DOM
#define M48T86_MONTH
#define M48T86_YEAR
#define M48T86_A
#define M48T86_B
#define M48T86_B_SET
#define M48T86_B_DM
#define M48T86_B_H24
#define M48T86_C
#define M48T86_D
#define M48T86_D_VRT
#define M48T86_NVRAM(x)
#define M48T86_NVRAM_LEN

struct m48t86_rtc_info {};

static unsigned char m48t86_readb(struct device *dev, unsigned long addr)
{}

static void m48t86_writeb(struct device *dev,
			  unsigned char value, unsigned long addr)
{}

static int m48t86_rtc_read_time(struct device *dev, struct rtc_time *tm)
{}

static int m48t86_rtc_set_time(struct device *dev, struct rtc_time *tm)
{}

static int m48t86_rtc_proc(struct device *dev, struct seq_file *seq)
{}

static const struct rtc_class_ops m48t86_rtc_ops =;

static int m48t86_nvram_read(void *priv, unsigned int off, void *buf,
			     size_t count)
{}

static int m48t86_nvram_write(void *priv, unsigned int off, void *buf,
			      size_t count)
{}

/*
 * The RTC is an optional feature at purchase time on some Technologic Systems
 * boards. Verify that it actually exists by checking if the last two bytes
 * of the NVRAM can be changed.
 *
 * This is based on the method used in their rtc7800.c example.
 */
static bool m48t86_verify_chip(struct platform_device *pdev)
{}

static int m48t86_rtc_probe(struct platform_device *pdev)
{}

static const struct of_device_id m48t86_rtc_of_ids[] =;
MODULE_DEVICE_TABLE(of, m48t86_rtc_of_ids);

static struct platform_driver m48t86_rtc_platform_driver =;

module_platform_driver();

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