Linux Kernel
3.7.1
|
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/bcd.h>
#include <linux/slab.h>
#include <linux/rtc.h>
#include <linux/workqueue.h>
#include <linux/spi/spi.h>
#include <linux/spi/ds1305.h>
#include <linux/module.h>
Go to the source code of this file.
Data Structures | |
struct | ds1305 |
Macros | |
#define | DS1305_WRITE 0x80 |
#define | DS1305_RTC_LEN 7 /* bytes for RTC regs */ |
#define | DS1305_SEC 0x00 /* register addresses */ |
#define | DS1305_MIN 0x01 |
#define | DS1305_HOUR 0x02 |
#define | DS1305_HR_12 0x40 /* set == 12 hr mode */ |
#define | DS1305_HR_PM 0x20 /* set == PM (12hr mode) */ |
#define | DS1305_WDAY 0x03 |
#define | DS1305_MDAY 0x04 |
#define | DS1305_MON 0x05 |
#define | DS1305_YEAR 0x06 |
#define | DS1305_ALM_LEN 4 /* bytes for ALM regs */ |
#define | DS1305_ALM_DISABLE 0x80 |
#define | DS1305_ALM0(r) (0x07 + (r)) /* register addresses */ |
#define | DS1305_ALM1(r) (0x0b + (r)) |
#define | DS1305_CONTROL_LEN 3 /* bytes of control regs */ |
#define | DS1305_CONTROL 0x0f /* register addresses */ |
#define | DS1305_nEOSC 0x80 /* low enables oscillator */ |
#define | DS1305_WP 0x40 /* write protect */ |
#define | DS1305_INTCN 0x04 /* clear == only int0 used */ |
#define | DS1306_1HZ 0x04 /* enable 1Hz output */ |
#define | DS1305_AEI1 0x02 /* enable ALM1 IRQ */ |
#define | DS1305_AEI0 0x01 /* enable ALM0 IRQ */ |
#define | DS1305_STATUS 0x10 |
#define | DS1305_TRICKLE 0x11 |
#define | DS1305_NVRAM_LEN 96 /* bytes of NVRAM */ |
#define | DS1305_NVRAM 0x20 /* register addresses */ |
#define | FLAG_EXITING 0 |
#define | ds1305_proc NULL |
Functions | |
module_spi_driver (ds1305_driver) | |
MODULE_DESCRIPTION ("RTC driver for DS1305 and DS1306 chips") | |
MODULE_LICENSE ("GPL") | |
MODULE_ALIAS ("spi:rtc-ds1305") | |
#define DS1305_AEI0 0x01 /* enable ALM0 IRQ */ |
Definition at line 76 of file rtc-ds1305.c.
#define DS1305_AEI1 0x02 /* enable ALM1 IRQ */ |
Definition at line 75 of file rtc-ds1305.c.
#define DS1305_ALM0 | ( | r | ) | (0x07 + (r)) /* register addresses */ |
Definition at line 63 of file rtc-ds1305.c.
#define DS1305_ALM1 | ( | r | ) | (0x0b + (r)) |
Definition at line 64 of file rtc-ds1305.c.
#define DS1305_ALM_DISABLE 0x80 |
Definition at line 61 of file rtc-ds1305.c.
Definition at line 60 of file rtc-ds1305.c.
#define DS1305_CONTROL 0x0f /* register addresses */ |
Definition at line 70 of file rtc-ds1305.c.
Definition at line 68 of file rtc-ds1305.c.
#define DS1305_HOUR 0x02 |
Definition at line 39 of file rtc-ds1305.c.
#define DS1305_HR_12 0x40 /* set == 12 hr mode */ |
Definition at line 40 of file rtc-ds1305.c.
#define DS1305_HR_PM 0x20 /* set == PM (12hr mode) */ |
Definition at line 41 of file rtc-ds1305.c.
#define DS1305_INTCN 0x04 /* clear == only int0 used */ |
Definition at line 73 of file rtc-ds1305.c.
#define DS1305_MDAY 0x04 |
Definition at line 43 of file rtc-ds1305.c.
#define DS1305_MIN 0x01 |
Definition at line 38 of file rtc-ds1305.c.
#define DS1305_MON 0x05 |
Definition at line 44 of file rtc-ds1305.c.
#define DS1305_nEOSC 0x80 /* low enables oscillator */ |
Definition at line 71 of file rtc-ds1305.c.
#define DS1305_NVRAM 0x20 /* register addresses */ |
Definition at line 85 of file rtc-ds1305.c.
Definition at line 83 of file rtc-ds1305.c.
#define ds1305_proc NULL |
Definition at line 443 of file rtc-ds1305.c.
#define DS1305_SEC 0x00 /* register addresses */ |
Definition at line 37 of file rtc-ds1305.c.
#define DS1305_STATUS 0x10 |
Definition at line 77 of file rtc-ds1305.c.
#define DS1305_TRICKLE 0x11 |
Definition at line 79 of file rtc-ds1305.c.
#define DS1305_WDAY 0x03 |
Definition at line 42 of file rtc-ds1305.c.
#define DS1305_WP 0x40 /* write protect */ |
Definition at line 72 of file rtc-ds1305.c.
#define DS1305_WRITE 0x80 |
Definition at line 27 of file rtc-ds1305.c.
#define DS1305_YEAR 0x06 |
Definition at line 45 of file rtc-ds1305.c.
#define DS1306_1HZ 0x04 /* enable 1Hz output */ |
Definition at line 74 of file rtc-ds1305.c.
#define FLAG_EXITING 0 |
Definition at line 95 of file rtc-ds1305.c.
MODULE_ALIAS | ( | "spi:rtc-ds1305" | ) |
MODULE_LICENSE | ( | "GPL" | ) |
module_spi_driver | ( | ds1305_driver | ) |