Logo Search packages:      
Sourcecode: linux-fsl-imx51 version File versions  Download package

dev.c File Reference


Detailed Description

Driver for Freescale CAN Controller FlexCAN.

Definition in file dev.c.

#include <linux/kernel.h>
#include <linux/string.h>
#include <linux/errno.h>
#include <linux/unistd.h>
#include <linux/init.h>
#include <linux/delay.h>
#include <linux/netdevice.h>
#include <linux/spinlock.h>
#include <linux/device.h>
#include <linux/module.h>
#include <mach/hardware.h>
#include "flexcan.h"

Go to the source code of this file.

Enumerations

enum  {
  FLEXCAN_ATTR_STATE = 0, FLEXCAN_ATTR_BITRATE, FLEXCAN_ATTR_BR_PRESDIV, FLEXCAN_ATTR_BR_RJW,
  FLEXCAN_ATTR_BR_PROPSEG, FLEXCAN_ATTR_BR_PSEG1, FLEXCAN_ATTR_BR_PSEG2, FLEXCAN_ATTR_BR_CLKSRC,
  FLEXCAN_ATTR_MAXMB, FLEXCAN_ATTR_XMIT_MAXMB, FLEXCAN_ATTR_FIFO, FLEXCAN_ATTR_WAKEUP,
  FLEXCAN_ATTR_SRX_DIS, FLEXCAN_ATTR_WAK_SRC, FLEXCAN_ATTR_BCC, FLEXCAN_ATTR_LOCAL_PRIORITY,
  FLEXCAN_ATTR_ABORT, FLEXCAN_ATTR_LOOPBACK, FLEXCAN_ATTR_SMP, FLEXCAN_ATTR_BOFF_REC,
  FLEXCAN_ATTR_TSYN, FLEXCAN_ATTR_LISTEN, FLEXCAN_ATTR_EXTEND_MSG, FLEXCAN_ATTR_STANDARD_MSG,
  FLEXCAN_ATTR_MAX
}

Functions

struct net_device * flexcan_device_alloc (struct platform_device *pdev, void(*setup)(struct net_device *dev))
 The function allocates can device.
static int flexcan_device_attach (struct flexcan_device *flexcan)
static void flexcan_device_default (struct flexcan_device *dev)
static void flexcan_device_detach (struct flexcan_device *flexcan)
void flexcan_device_free (struct platform_device *pdev)
 The function frees can device.
static ssize_t flexcan_set_attr (struct device *dev, struct device_attribute *attr, const char *buf, size_t count)
static void flexcan_set_bitrate (struct flexcan_device *flexcan, int bitrate)
static ssize_t flexcan_show_attr (struct device *dev, struct device_attribute *attr, char *buf)
static ssize_t flexcan_show_state (struct net_device *net, char *buf)
static void flexcan_update_bitrate (struct flexcan_device *flexcan)

Variables

static struct device_attribute flexcan_dev_attr [FLEXCAN_ATTR_MAX]


Generated by  Doxygen 1.6.0   Back to index