Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
atmel-mci.c File Reference
#include <linux/blkdev.h>
#include <linux/clk.h>
#include <linux/debugfs.h>
#include <linux/device.h>
#include <linux/dmaengine.h>
#include <linux/dma-mapping.h>
#include <linux/err.h>
#include <linux/gpio.h>
#include <linux/init.h>
#include <linux/interrupt.h>
#include <linux/ioport.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/of_device.h>
#include <linux/of_gpio.h>
#include <linux/platform_device.h>
#include <linux/scatterlist.h>
#include <linux/seq_file.h>
#include <linux/slab.h>
#include <linux/stat.h>
#include <linux/types.h>
#include <linux/mmc/host.h>
#include <linux/mmc/sdio.h>
#include <mach/atmel-mci.h>
#include <linux/atmel-mci.h>
#include <linux/atmel_pdc.h>
#include <asm/io.h>
#include <asm/unaligned.h>
#include <mach/cpu.h>
#include <mach/board.h>
#include "atmel-mci-regs.h"

Go to the source code of this file.

Data Structures

struct  atmel_mci_caps
 
struct  atmel_mci_dma
 
struct  atmel_mci
 
struct  atmel_mci_slot
 

Macros

#define ATMCI_DATA_ERROR_FLAGS   (ATMCI_DCRCE | ATMCI_DTOE | ATMCI_OVRE | ATMCI_UNRE)
 
#define ATMCI_DMA_THRESHOLD   16
 
#define ATMCI_CARD_PRESENT   0
 
#define ATMCI_CARD_NEED_INIT   1
 
#define ATMCI_SHUTDOWN   2
 
#define ATMCI_SUSPENDED   3
 
#define atmci_test_and_clear_pending(host, event)   test_and_clear_bit(event, &host->pending_events)
 
#define atmci_set_completed(host, event)   set_bit(event, &host->completed_events)
 
#define atmci_set_pending(host, event)   set_bit(event, &host->pending_events)
 
#define ATMCI_PM_OPS   NULL
 

Enumerations

enum  { EVENT_CMD_RDY = 0, EVENT_XFER_COMPLETE, EVENT_NOTBUSY, EVENT_DATA_ERROR }
 
enum  atmel_mci_state {
  STATE_IDLE = 0, STATE_SENDING_CMD, STATE_DATA_XFER, STATE_WAITING_NOTBUSY,
  STATE_SENDING_STOP, STATE_END_REQUEST
}
 
enum  atmci_xfer_dir { XFER_RECEIVE = 0, XFER_TRANSMIT }
 
enum  atmci_pdc_buf { PDC_FIRST_BUF = 0, PDC_SECOND_BUF }
 

Functions

 late_initcall (atmci_init)
 
 module_exit (atmci_exit)
 
 MODULE_DESCRIPTION ("Atmel Multimedia Card Interface driver")
 
 MODULE_AUTHOR ("Haavard Skinnemoen (Atmel)")
 
 MODULE_LICENSE ("GPL v2")
 

Macro Definition Documentation

#define ATMCI_CARD_NEED_INIT   1

Definition at line 257 of file atmel-mci.c.

#define ATMCI_CARD_PRESENT   0

Definition at line 256 of file atmel-mci.c.

#define ATMCI_DATA_ERROR_FLAGS   (ATMCI_DCRCE | ATMCI_DTOE | ATMCI_OVRE | ATMCI_UNRE)

Definition at line 47 of file atmel-mci.c.

#define ATMCI_DMA_THRESHOLD   16

Definition at line 48 of file atmel-mci.c.

#define ATMCI_PM_OPS   NULL

Definition at line 2562 of file atmel-mci.c.

#define atmci_set_completed (   host,
  event 
)    set_bit(event, &host->completed_events)

Definition at line 270 of file atmel-mci.c.

#define atmci_set_pending (   host,
  event 
)    set_bit(event, &host->pending_events)

Definition at line 272 of file atmel-mci.c.

#define ATMCI_SHUTDOWN   2

Definition at line 258 of file atmel-mci.c.

#define ATMCI_SUSPENDED   3

Definition at line 259 of file atmel-mci.c.

#define atmci_test_and_clear_pending (   host,
  event 
)    test_and_clear_bit(event, &host->pending_events)

Definition at line 268 of file atmel-mci.c.

Enumeration Type Documentation

anonymous enum
Enumerator:
EVENT_CMD_RDY 
EVENT_XFER_COMPLETE 
EVENT_NOTBUSY 
EVENT_DATA_ERROR 

Definition at line 50 of file atmel-mci.c.

Enumerator:
PDC_FIRST_BUF 
PDC_SECOND_BUF 

Definition at line 71 of file atmel-mci.c.

Enumerator:
XFER_RECEIVE 
XFER_TRANSMIT 

Definition at line 66 of file atmel-mci.c.

Enumerator:
STATE_IDLE 
STATE_SENDING_CMD 
STATE_DATA_XFER 
STATE_WAITING_NOTBUSY 
STATE_SENDING_STOP 
STATE_END_REQUEST 

Definition at line 57 of file atmel-mci.c.

Function Documentation

late_initcall ( atmci_init  )
MODULE_AUTHOR ( "Haavard Skinnemoen (Atmel)"  )
MODULE_DESCRIPTION ( "Atmel Multimedia Card Interface driver )
module_exit ( atmci_exit  )
MODULE_LICENSE ( "GPL v2 )