Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
rtc-ds1511.c File Reference
#include <linux/bcd.h>
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/gfp.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/rtc.h>
#include <linux/platform_device.h>
#include <linux/io.h>
#include <linux/module.h>

Go to the source code of this file.

Data Structures

struct  rtc_plat_data
 

Macros

#define DRV_VERSION   "0.6"
 
#define DS1511_BLF1   0x80
 
#define DS1511_BLF2   0x40
 
#define DS1511_PRS   0x20
 
#define DS1511_PAB   0x10
 
#define DS1511_TDF   0x08
 
#define DS1511_KSF   0x04
 
#define DS1511_WDF   0x02
 
#define DS1511_IRQF   0x01
 
#define DS1511_TE   0x80
 
#define DS1511_CS   0x40
 
#define DS1511_BME   0x20
 
#define DS1511_TPE   0x10
 
#define DS1511_TIE   0x08
 
#define DS1511_KIE   0x04
 
#define DS1511_WDE   0x02
 
#define DS1511_WDS   0x01
 
#define DS1511_RAM_MAX   0xff
 
#define RTC_CMD   DS1511_CONTROL_B
 
#define RTC_CMD1   DS1511_CONTROL_A
 
#define RTC_ALARM_SEC   DS1511_AM1_SEC
 
#define RTC_ALARM_MIN   DS1511_AM2_MIN
 
#define RTC_ALARM_HOUR   DS1511_AM3_HOUR
 
#define RTC_ALARM_DATE   DS1511_AM4_DATE
 
#define RTC_SEC   DS1511_SEC
 
#define RTC_MIN   DS1511_MIN
 
#define RTC_HOUR   DS1511_HOUR
 
#define RTC_DOW   DS1511_DOW
 
#define RTC_DOM   DS1511_DOM
 
#define RTC_MON   DS1511_MONTH
 
#define RTC_YEAR   DS1511_YEAR
 
#define RTC_CENTURY   DS1511_CENTURY
 
#define RTC_TIE   DS1511_TIE
 
#define RTC_TE   DS1511_TE
 

Enumerations

enum  ds1511reg {
  DS1511_SEC = 0x0, DS1511_MIN = 0x1, DS1511_HOUR = 0x2, DS1511_DOW = 0x3,
  DS1511_DOM = 0x4, DS1511_MONTH = 0x5, DS1511_YEAR = 0x6, DS1511_CENTURY = 0x7,
  DS1511_AM1_SEC = 0x8, DS1511_AM2_MIN = 0x9, DS1511_AM3_HOUR = 0xa, DS1511_AM4_DATE = 0xb,
  DS1511_WD_MSEC = 0xc, DS1511_WD_SEC = 0xd, DS1511_CONTROL_A = 0xe, DS1511_CONTROL_B = 0xf,
  DS1511_RAMADDR_LSB = 0x10, DS1511_RAMDATA = 0x13
}
 

Functions

 MODULE_ALIAS ("platform:ds1511")
 
 module_platform_driver (ds1511_rtc_driver)
 
 MODULE_AUTHOR ("Andrew Sharp <[email protected]>")
 
 MODULE_DESCRIPTION ("Dallas DS1511 RTC driver")
 
 MODULE_LICENSE ("GPL")
 
 MODULE_VERSION (DRV_VERSION)
 

Macro Definition Documentation

#define DRV_VERSION   "0.6"

Definition at line 28 of file rtc-ds1511.c.

#define DS1511_BLF1   0x80

Definition at line 51 of file rtc-ds1511.c.

#define DS1511_BLF2   0x40

Definition at line 52 of file rtc-ds1511.c.

#define DS1511_BME   0x20

Definition at line 61 of file rtc-ds1511.c.

#define DS1511_CS   0x40

Definition at line 60 of file rtc-ds1511.c.

#define DS1511_IRQF   0x01

Definition at line 58 of file rtc-ds1511.c.

#define DS1511_KIE   0x04

Definition at line 64 of file rtc-ds1511.c.

#define DS1511_KSF   0x04

Definition at line 56 of file rtc-ds1511.c.

#define DS1511_PAB   0x10

Definition at line 54 of file rtc-ds1511.c.

#define DS1511_PRS   0x20

Definition at line 53 of file rtc-ds1511.c.

#define DS1511_RAM_MAX   0xff

Definition at line 67 of file rtc-ds1511.c.

#define DS1511_TDF   0x08

Definition at line 55 of file rtc-ds1511.c.

#define DS1511_TE   0x80

Definition at line 59 of file rtc-ds1511.c.

#define DS1511_TIE   0x08

Definition at line 63 of file rtc-ds1511.c.

#define DS1511_TPE   0x10

Definition at line 62 of file rtc-ds1511.c.

#define DS1511_WDE   0x02

Definition at line 65 of file rtc-ds1511.c.

#define DS1511_WDF   0x02

Definition at line 57 of file rtc-ds1511.c.

#define DS1511_WDS   0x01

Definition at line 66 of file rtc-ds1511.c.

#define RTC_ALARM_DATE   DS1511_AM4_DATE

Definition at line 75 of file rtc-ds1511.c.

#define RTC_ALARM_HOUR   DS1511_AM3_HOUR

Definition at line 74 of file rtc-ds1511.c.

#define RTC_ALARM_MIN   DS1511_AM2_MIN

Definition at line 73 of file rtc-ds1511.c.

#define RTC_ALARM_SEC   DS1511_AM1_SEC

Definition at line 72 of file rtc-ds1511.c.

#define RTC_CENTURY   DS1511_CENTURY

Definition at line 84 of file rtc-ds1511.c.

#define RTC_CMD   DS1511_CONTROL_B

Definition at line 69 of file rtc-ds1511.c.

#define RTC_CMD1   DS1511_CONTROL_A

Definition at line 70 of file rtc-ds1511.c.

#define RTC_DOM   DS1511_DOM

Definition at line 81 of file rtc-ds1511.c.

#define RTC_DOW   DS1511_DOW

Definition at line 80 of file rtc-ds1511.c.

#define RTC_HOUR   DS1511_HOUR

Definition at line 79 of file rtc-ds1511.c.

#define RTC_MIN   DS1511_MIN

Definition at line 78 of file rtc-ds1511.c.

#define RTC_MON   DS1511_MONTH

Definition at line 82 of file rtc-ds1511.c.

#define RTC_SEC   DS1511_SEC

Definition at line 77 of file rtc-ds1511.c.

#define RTC_TE   DS1511_TE

Definition at line 87 of file rtc-ds1511.c.

#define RTC_TIE   DS1511_TIE

Definition at line 86 of file rtc-ds1511.c.

#define RTC_YEAR   DS1511_YEAR

Definition at line 83 of file rtc-ds1511.c.

Enumeration Type Documentation

enum ds1511reg
Enumerator:
DS1511_SEC 
DS1511_MIN 
DS1511_HOUR 
DS1511_DOW 
DS1511_DOM 
DS1511_MONTH 
DS1511_YEAR 
DS1511_CENTURY 
DS1511_AM1_SEC 
DS1511_AM2_MIN 
DS1511_AM3_HOUR 
DS1511_AM4_DATE 
DS1511_WD_MSEC 
DS1511_WD_SEC 
DS1511_CONTROL_A 
DS1511_CONTROL_B 
DS1511_RAMADDR_LSB 
DS1511_RAMDATA 

Definition at line 30 of file rtc-ds1511.c.

Function Documentation

MODULE_ALIAS ( "platform:ds1511"  )
MODULE_AUTHOR ( "Andrew Sharp <[email protected]>"  )
MODULE_DESCRIPTION ( "Dallas DS1511 RTC driver )
MODULE_LICENSE ( "GPL"  )
module_platform_driver ( ds1511_rtc_driver  )
MODULE_VERSION ( DRV_VERSION  )