Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
spi-xcomm.c File Reference
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/i2c.h>
#include <linux/spi/spi.h>
#include <asm/unaligned.h>

Go to the source code of this file.

Data Structures

struct  spi_xcomm
 

Macros

#define SPI_XCOMM_SETTINGS_LEN_OFFSET   10
 
#define SPI_XCOMM_SETTINGS_3WIRE   BIT(6)
 
#define SPI_XCOMM_SETTINGS_CS_HIGH   BIT(5)
 
#define SPI_XCOMM_SETTINGS_SAMPLE_END   BIT(4)
 
#define SPI_XCOMM_SETTINGS_CPHA   BIT(3)
 
#define SPI_XCOMM_SETTINGS_CPOL   BIT(2)
 
#define SPI_XCOMM_SETTINGS_CLOCK_DIV_MASK   0x3
 
#define SPI_XCOMM_SETTINGS_CLOCK_DIV_64   0x2
 
#define SPI_XCOMM_SETTINGS_CLOCK_DIV_16   0x1
 
#define SPI_XCOMM_SETTINGS_CLOCK_DIV_4   0x0
 
#define SPI_XCOMM_CMD_UPDATE_CONFIG   0x03
 
#define SPI_XCOMM_CMD_WRITE   0x04
 
#define SPI_XCOMM_CLOCK   48000000
 

Functions

 module_i2c_driver (spi_xcomm_driver)
 
 MODULE_LICENSE ("GPL")
 
 MODULE_AUTHOR ("Lars-Peter Clausen <[email protected]>")
 
 MODULE_DESCRIPTION ("Analog Devices AD-FMCOMMS1-EBZ board I2C-SPI bridge driver")
 

Macro Definition Documentation

#define SPI_XCOMM_CLOCK   48000000

Definition at line 32 of file spi-xcomm.c.

#define SPI_XCOMM_CMD_UPDATE_CONFIG   0x03

Definition at line 29 of file spi-xcomm.c.

#define SPI_XCOMM_CMD_WRITE   0x04

Definition at line 30 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_3WIRE   BIT(6)

Definition at line 19 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_CLOCK_DIV_16   0x1

Definition at line 26 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_CLOCK_DIV_4   0x0

Definition at line 27 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_CLOCK_DIV_64   0x2

Definition at line 25 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_CLOCK_DIV_MASK   0x3

Definition at line 24 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_CPHA   BIT(3)

Definition at line 22 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_CPOL   BIT(2)

Definition at line 23 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_CS_HIGH   BIT(5)

Definition at line 20 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_LEN_OFFSET   10

Definition at line 18 of file spi-xcomm.c.

#define SPI_XCOMM_SETTINGS_SAMPLE_END   BIT(4)

Definition at line 21 of file spi-xcomm.c.

Function Documentation

MODULE_AUTHOR ( "Lars-Peter Clausen <[email protected]>"  )
MODULE_DESCRIPTION ( "Analog Devices AD-FMCOMMS1-EBZ board I2C-SPI bridge driver )
module_i2c_driver ( spi_xcomm_driver  )
MODULE_LICENSE ( "GPL"  )