Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
atmel_tclib.c File Reference
#include <linux/atmel_tc.h>
#include <linux/clk.h>
#include <linux/err.h>
#include <linux/init.h>
#include <linux/io.h>
#include <linux/ioport.h>
#include <linux/kernel.h>
#include <linux/platform_device.h>
#include <linux/module.h>
#include <linux/slab.h>
#include <linux/export.h>
#include <linux/of.h>

Go to the source code of this file.

: name to be associated with the iomem resource

atmel_tc_alloc - allocate a specified TC block : which block to allocate

Caller allocates a block. If it is available, a pointer to a pre-initialized struct atmel_tc is returned. The caller can access the registers directly through the "regs" field.

struct atmel_tcatmel_tc_alloc (unsigned block, const char *name)
 
 EXPORT_SYMBOL_GPL (atmel_tc_alloc)
 
void atmel_tc_free (struct atmel_tc *tc)
 
 EXPORT_SYMBOL_GPL (atmel_tc_free)
 
 arch_initcall (tc_init)
 

Function Documentation

arch_initcall ( tc_init  )
struct atmel_tc* atmel_tc_alloc ( unsigned  block,
const char name 
)
read

Definition at line 44 of file atmel_tclib.c.

void atmel_tc_free ( struct atmel_tc tc)

atmel_tc_free - release a specified TC block : Timer/counter block that was returned by atmel_tc_alloc()

This reverses the effect of atmel_tc_alloc(), unmapping the I/O registers, invalidating the resource returned by that routine and making the TC available to other drivers.

Definition at line 103 of file atmel_tclib.c.

EXPORT_SYMBOL_GPL ( atmel_tc_alloc  )
EXPORT_SYMBOL_GPL ( atmel_tc_free  )