Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
bf5xx-sport.c File Reference
#include <linux/kernel.h>
#include <linux/slab.h>
#include <linux/delay.h>
#include <linux/dma-mapping.h>
#include <linux/gpio.h>
#include <linux/bug.h>
#include <linux/module.h>
#include <asm/portmux.h>
#include <asm/dma.h>
#include <asm/blackfin.h>
#include <asm/cacheflush.h>
#include "bf5xx-sport.h"

Go to the source code of this file.

Macros

#define FRAME_DELAY   (1<<12)
 

Functions

int sport_set_multichannel (struct sport_device *sport, int tdm_count, u32 mask, int packed)
 
 EXPORT_SYMBOL (sport_set_multichannel)
 
int sport_config_rx (struct sport_device *sport, unsigned int rcr1, unsigned int rcr2, unsigned int clkdiv, unsigned int fsdiv)
 
 EXPORT_SYMBOL (sport_config_rx)
 
int sport_config_tx (struct sport_device *sport, unsigned int tcr1, unsigned int tcr2, unsigned int clkdiv, unsigned int fsdiv)
 
 EXPORT_SYMBOL (sport_config_tx)
 
int sport_rx_start (struct sport_device *sport)
 
 EXPORT_SYMBOL (sport_rx_start)
 
int sport_rx_stop (struct sport_device *sport)
 
 EXPORT_SYMBOL (sport_rx_stop)
 
int sport_tx_start (struct sport_device *sport)
 
 EXPORT_SYMBOL (sport_tx_start)
 
int sport_tx_stop (struct sport_device *sport)
 
 EXPORT_SYMBOL (sport_tx_stop)
 
int sport_config_rx_dma (struct sport_device *sport, void *buf, int fragcount, size_t fragsize)
 
 EXPORT_SYMBOL (sport_config_rx_dma)
 
int sport_config_tx_dma (struct sport_device *sport, void *buf, int fragcount, size_t fragsize)
 
 EXPORT_SYMBOL (sport_config_tx_dma)
 
unsigned long sport_curr_offset_rx (struct sport_device *sport)
 
 EXPORT_SYMBOL (sport_curr_offset_rx)
 
unsigned long sport_curr_offset_tx (struct sport_device *sport)
 
 EXPORT_SYMBOL (sport_curr_offset_tx)
 
void sport_incfrag (struct sport_device *sport, int *frag, int tx)
 
 EXPORT_SYMBOL (sport_incfrag)
 
void sport_decfrag (struct sport_device *sport, int *frag, int tx)
 
 EXPORT_SYMBOL (sport_decfrag)
 
int sport_dump_stat (struct sport_device *sport, char *buf, size_t len)
 
int sport_set_rx_callback (struct sport_device *sport, void(*rx_callback)(void *), void *rx_data)
 
 EXPORT_SYMBOL (sport_set_rx_callback)
 
int sport_set_tx_callback (struct sport_device *sport, void(*tx_callback)(void *), void *tx_data)
 
 EXPORT_SYMBOL (sport_set_tx_callback)
 
int sport_set_err_callback (struct sport_device *sport, void(*err_callback)(void *), void *err_data)
 
 EXPORT_SYMBOL (sport_set_err_callback)
 
struct sport_devicesport_init (struct platform_device *pdev, unsigned int wdsize, unsigned int dummy_count, size_t priv_size)
 
 EXPORT_SYMBOL (sport_init)
 
void sport_done (struct sport_device *sport)
 
 EXPORT_SYMBOL (sport_done)
 
int sport_send_and_recv (struct sport_device *sport, u8 *out_data, u8 *in_data, int len)
 
 EXPORT_SYMBOL (sport_send_and_recv)
 
 MODULE_AUTHOR ("Roy Huang")
 
 MODULE_DESCRIPTION ("SPORT driver for ADI Blackfin")
 
 MODULE_LICENSE ("GPL")
 

Macro Definition Documentation

#define FRAME_DELAY   (1<<12)

Definition at line 44 of file bf5xx-sport.c.

Function Documentation

EXPORT_SYMBOL ( sport_set_multichannel  )
EXPORT_SYMBOL ( sport_config_rx  )
EXPORT_SYMBOL ( sport_config_tx  )
EXPORT_SYMBOL ( sport_rx_start  )
EXPORT_SYMBOL ( sport_rx_stop  )
EXPORT_SYMBOL ( sport_tx_start  )
EXPORT_SYMBOL ( sport_tx_stop  )
EXPORT_SYMBOL ( sport_config_rx_dma  )
EXPORT_SYMBOL ( sport_config_tx_dma  )
EXPORT_SYMBOL ( sport_curr_offset_rx  )
EXPORT_SYMBOL ( sport_curr_offset_tx  )
EXPORT_SYMBOL ( sport_incfrag  )
EXPORT_SYMBOL ( sport_decfrag  )
EXPORT_SYMBOL ( sport_set_rx_callback  )
EXPORT_SYMBOL ( sport_set_tx_callback  )
EXPORT_SYMBOL ( sport_set_err_callback  )
EXPORT_SYMBOL ( sport_init  )
EXPORT_SYMBOL ( sport_done  )
EXPORT_SYMBOL ( sport_send_and_recv  )
MODULE_AUTHOR ( "Roy Huang"  )
MODULE_DESCRIPTION ( "SPORT driver for ADI Blackfin"  )
MODULE_LICENSE ( "GPL"  )
int sport_config_rx ( struct sport_device sport,
unsigned int  rcr1,
unsigned int  rcr2,
unsigned int  clkdiv,
unsigned int  fsdiv 
)

Definition at line 93 of file bf5xx-sport.c.

int sport_config_rx_dma ( struct sport_device sport,
void buf,
int  fragcount,
size_t  fragsize 
)

Definition at line 389 of file bf5xx-sport.c.

int sport_config_tx ( struct sport_device sport,
unsigned int  tcr1,
unsigned int  tcr2,
unsigned int  clkdiv,
unsigned int  fsdiv 
)

Definition at line 110 of file bf5xx-sport.c.

int sport_config_tx_dma ( struct sport_device sport,
void buf,
int  fragcount,
size_t  fragsize 
)

Definition at line 454 of file bf5xx-sport.c.

unsigned long sport_curr_offset_rx ( struct sport_device sport)

Definition at line 586 of file bf5xx-sport.c.

unsigned long sport_curr_offset_tx ( struct sport_device sport)

Definition at line 594 of file bf5xx-sport.c.

void sport_decfrag ( struct sport_device sport,
int frag,
int  tx 
)

Definition at line 613 of file bf5xx-sport.c.

void sport_done ( struct sport_device sport)

Definition at line 971 of file bf5xx-sport.c.

int sport_dump_stat ( struct sport_device sport,
char buf,
size_t  len 
)

Definition at line 661 of file bf5xx-sport.c.

void sport_incfrag ( struct sport_device sport,
int frag,
int  tx 
)

Definition at line 602 of file bf5xx-sport.c.

struct sport_device* sport_init ( struct platform_device pdev,
unsigned int  wdsize,
unsigned int  dummy_count,
size_t  priv_size 
)
read

Definition at line 847 of file bf5xx-sport.c.

int sport_rx_start ( struct sport_device sport)

Definition at line 245 of file bf5xx-sport.c.

int sport_rx_stop ( struct sport_device sport)

Definition at line 274 of file bf5xx-sport.c.

int sport_send_and_recv ( struct sport_device sport,
u8 out_data,
u8 in_data,
int  len 
)

Definition at line 1010 of file bf5xx-sport.c.

int sport_set_err_callback ( struct sport_device sport,
void(*)(void *)  err_callback,
void err_data 
)

Definition at line 789 of file bf5xx-sport.c.

int sport_set_multichannel ( struct sport_device sport,
int  tdm_count,
u32  mask,
int  packed 
)

Definition at line 48 of file bf5xx-sport.c.

int sport_set_rx_callback ( struct sport_device sport,
void(*)(void *)  rx_callback,
void rx_data 
)

Definition at line 767 of file bf5xx-sport.c.

int sport_set_tx_callback ( struct sport_device sport,
void(*)(void *)  tx_callback,
void tx_data 
)

Definition at line 778 of file bf5xx-sport.c.

int sport_tx_start ( struct sport_device sport)

Definition at line 326 of file bf5xx-sport.c.

int sport_tx_stop ( struct sport_device sport)

Definition at line 356 of file bf5xx-sport.c.