Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
tifm.h File Reference
#include <linux/spinlock.h>
#include <linux/interrupt.h>
#include <linux/delay.h>
#include <linux/pci.h>
#include <linux/workqueue.h>

Go to the source code of this file.

Data Structures

struct  tifm_device_id
 
struct  tifm_dev
 
struct  tifm_driver
 
struct  tifm_adapter
 

Macros

#define TIFM_CTRL_LED   0x00000040
 
#define TIFM_CTRL_FAST_CLK   0x00000100
 
#define TIFM_CTRL_POWER_MASK   0x00000007
 
#define TIFM_SOCK_STATE_OCCUPIED   0x00000008
 
#define TIFM_SOCK_STATE_POWERED   0x00000080
 
#define TIFM_FIFO_ENABLE   0x00000001
 
#define TIFM_FIFO_READY   0x00000001
 
#define TIFM_FIFO_MORE   0x00000008
 
#define TIFM_FIFO_INT_SETALL   0x0000ffff
 
#define TIFM_FIFO_INTMASK   0x00000005
 
#define TIFM_DMA_RESET   0x00000002
 
#define TIFM_DMA_TX   0x00008000
 
#define TIFM_DMA_EN   0x00000001
 
#define TIFM_DMA_TSIZE   0x0000007f
 
#define TIFM_TYPE_XD   1
 
#define TIFM_TYPE_MS   2
 
#define TIFM_TYPE_SD   3
 

Enumerations

enum  { FM_SET_INTERRUPT_ENABLE = 0x008, FM_CLEAR_INTERRUPT_ENABLE = 0x00c, FM_INTERRUPT_STATUS = 0x014 }
 
enum  {
  SOCK_CONTROL = 0x004, SOCK_PRESENT_STATE = 0x008, SOCK_DMA_ADDRESS = 0x00c, SOCK_DMA_CONTROL = 0x010,
  SOCK_DMA_FIFO_INT_ENABLE_SET = 0x014, SOCK_DMA_FIFO_INT_ENABLE_CLEAR = 0x018, SOCK_DMA_FIFO_STATUS = 0x020, SOCK_FIFO_CONTROL = 0x024,
  SOCK_FIFO_PAGE_SIZE = 0x028, SOCK_MMCSD_COMMAND = 0x104, SOCK_MMCSD_ARG_LOW = 0x108, SOCK_MMCSD_ARG_HIGH = 0x10c,
  SOCK_MMCSD_CONFIG = 0x110, SOCK_MMCSD_STATUS = 0x114, SOCK_MMCSD_INT_ENABLE = 0x118, SOCK_MMCSD_COMMAND_TO = 0x11c,
  SOCK_MMCSD_DATA_TO = 0x120, SOCK_MMCSD_DATA = 0x124, SOCK_MMCSD_BLOCK_LEN = 0x128, SOCK_MMCSD_NUM_BLOCKS = 0x12c,
  SOCK_MMCSD_BUFFER_CONFIG = 0x130, SOCK_MMCSD_SPI_CONFIG = 0x134, SOCK_MMCSD_SDIO_MODE_CONFIG = 0x138, SOCK_MMCSD_RESPONSE = 0x144,
  SOCK_MMCSD_SDIO_SR = 0x164, SOCK_MMCSD_SYSTEM_CONTROL = 0x168, SOCK_MMCSD_SYSTEM_STATUS = 0x16c, SOCK_MS_COMMAND = 0x184,
  SOCK_MS_DATA = 0x188, SOCK_MS_STATUS = 0x18c, SOCK_MS_SYSTEM = 0x190, SOCK_FIFO_ACCESS = 0x200
}
 

Functions

struct tifm_adaptertifm_alloc_adapter (unsigned int num_sockets, struct device *dev)
 
int tifm_add_adapter (struct tifm_adapter *fm)
 
void tifm_remove_adapter (struct tifm_adapter *fm)
 
void tifm_free_adapter (struct tifm_adapter *fm)
 
void tifm_free_device (struct device *dev)
 
struct tifm_devtifm_alloc_device (struct tifm_adapter *fm, unsigned int id, unsigned char type)
 
int tifm_register_driver (struct tifm_driver *drv)
 
void tifm_unregister_driver (struct tifm_driver *drv)
 
void tifm_eject (struct tifm_dev *sock)
 
int tifm_has_ms_pif (struct tifm_dev *sock)
 
int tifm_map_sg (struct tifm_dev *sock, struct scatterlist *sg, int nents, int direction)
 
void tifm_unmap_sg (struct tifm_dev *sock, struct scatterlist *sg, int nents, int direction)
 
void tifm_queue_work (struct work_struct *work)
 

Macro Definition Documentation

#define TIFM_CTRL_FAST_CLK   0x00000100

Definition at line 65 of file tifm.h.

#define TIFM_CTRL_LED   0x00000040

Definition at line 64 of file tifm.h.

#define TIFM_CTRL_POWER_MASK   0x00000007

Definition at line 66 of file tifm.h.

#define TIFM_DMA_EN   0x00000001

Definition at line 79 of file tifm.h.

#define TIFM_DMA_RESET   0x00000002

Definition at line 77 of file tifm.h.

#define TIFM_DMA_TSIZE   0x0000007f

Definition at line 80 of file tifm.h.

#define TIFM_DMA_TX   0x00008000

Definition at line 78 of file tifm.h.

#define TIFM_FIFO_ENABLE   0x00000001

Definition at line 71 of file tifm.h.

#define TIFM_FIFO_INT_SETALL   0x0000ffff

Definition at line 74 of file tifm.h.

#define TIFM_FIFO_INTMASK   0x00000005

Definition at line 75 of file tifm.h.

#define TIFM_FIFO_MORE   0x00000008

Definition at line 73 of file tifm.h.

#define TIFM_FIFO_READY   0x00000001

Definition at line 72 of file tifm.h.

#define TIFM_SOCK_STATE_OCCUPIED   0x00000008

Definition at line 68 of file tifm.h.

#define TIFM_SOCK_STATE_POWERED   0x00000080

Definition at line 69 of file tifm.h.

#define TIFM_TYPE_MS   2

Definition at line 83 of file tifm.h.

#define TIFM_TYPE_SD   3

Definition at line 84 of file tifm.h.

#define TIFM_TYPE_XD   1

Definition at line 82 of file tifm.h.

Enumeration Type Documentation

anonymous enum
Enumerator:
FM_SET_INTERRUPT_ENABLE 
FM_CLEAR_INTERRUPT_ENABLE 
FM_INTERRUPT_STATUS 

Definition at line 22 of file tifm.h.

anonymous enum
Enumerator:
SOCK_CONTROL 
SOCK_PRESENT_STATE 
SOCK_DMA_ADDRESS 
SOCK_DMA_CONTROL 
SOCK_DMA_FIFO_INT_ENABLE_SET 
SOCK_DMA_FIFO_INT_ENABLE_CLEAR 
SOCK_DMA_FIFO_STATUS 
SOCK_FIFO_CONTROL 
SOCK_FIFO_PAGE_SIZE 
SOCK_MMCSD_COMMAND 
SOCK_MMCSD_ARG_LOW 
SOCK_MMCSD_ARG_HIGH 
SOCK_MMCSD_CONFIG 
SOCK_MMCSD_STATUS 
SOCK_MMCSD_INT_ENABLE 
SOCK_MMCSD_COMMAND_TO 
SOCK_MMCSD_DATA_TO 
SOCK_MMCSD_DATA 
SOCK_MMCSD_BLOCK_LEN 
SOCK_MMCSD_NUM_BLOCKS 
SOCK_MMCSD_BUFFER_CONFIG 
SOCK_MMCSD_SPI_CONFIG 
SOCK_MMCSD_SDIO_MODE_CONFIG 
SOCK_MMCSD_RESPONSE 
SOCK_MMCSD_SDIO_SR 
SOCK_MMCSD_SYSTEM_CONTROL 
SOCK_MMCSD_SYSTEM_STATUS 
SOCK_MS_COMMAND 
SOCK_MS_DATA 
SOCK_MS_STATUS 
SOCK_MS_SYSTEM 
SOCK_FIFO_ACCESS 

Definition at line 29 of file tifm.h.

Function Documentation

int tifm_add_adapter ( struct tifm_adapter fm)

Definition at line 195 of file tifm_core.c.

struct tifm_adapter* tifm_alloc_adapter ( unsigned int  num_sockets,
struct device dev 
)
read

Definition at line 177 of file tifm_core.c.

struct tifm_dev* tifm_alloc_device ( struct tifm_adapter fm,
unsigned int  id,
unsigned char  type 
)
read

Definition at line 250 of file tifm_core.c.

void tifm_eject ( struct tifm_dev sock)

Definition at line 281 of file tifm_core.c.

void tifm_free_adapter ( struct tifm_adapter fm)

Definition at line 237 of file tifm_core.c.

void tifm_free_device ( struct device dev)

Definition at line 243 of file tifm_core.c.

int tifm_has_ms_pif ( struct tifm_dev sock)

Definition at line 288 of file tifm_core.c.

int tifm_map_sg ( struct tifm_dev sock,
struct scatterlist sg,
int  nents,
int  direction 
)

Definition at line 295 of file tifm_core.c.

void tifm_queue_work ( struct work_struct work)

Definition at line 309 of file tifm_core.c.

int tifm_register_driver ( struct tifm_driver drv)

Definition at line 315 of file tifm_core.c.

void tifm_remove_adapter ( struct tifm_adapter fm)

Definition at line 220 of file tifm_core.c.

void tifm_unmap_sg ( struct tifm_dev sock,
struct scatterlist sg,
int  nents,
int  direction 
)

Definition at line 302 of file tifm_core.c.

void tifm_unregister_driver ( struct tifm_driver drv)

Definition at line 323 of file tifm_core.c.