Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
peak_pci.c File Reference
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/interrupt.h>
#include <linux/netdevice.h>
#include <linux/delay.h>
#include <linux/pci.h>
#include <linux/io.h>
#include <linux/i2c.h>
#include <linux/i2c-algo-bit.h>
#include <linux/can.h>
#include <linux/can/dev.h>
#include "sja1000.h"

Go to the source code of this file.

Data Structures

struct  peak_pci_chan
 

Macros

#define DRV_NAME   "peak_pci"
 
#define PEAK_PCI_CAN_CLOCK   (16000000 / 2)
 
#define PEAK_PCI_CDR   (CDR_CBP | CDR_CLKOUT_MASK)
 
#define PEAK_PCI_OCR   OCR_TX0_PUSHPULL
 
#define PITA_ICR   0x00 /* Interrupt control register */
 
#define PITA_GPIOICR   0x18 /* GPIO interface control register */
 
#define PITA_MISC   0x1C /* Miscellaneous register */
 
#define PEAK_PCI_CFG_SIZE   0x1000 /* Size of the config PCI bar */
 
#define PEAK_PCI_CHAN_SIZE   0x0400 /* Size used by the channel */
 
#define PEAK_PCI_VENDOR_ID   0x001C /* The PCI device and vendor IDs */
 
#define PEAK_PCI_DEVICE_ID   0x0001 /* for PCI/PCIe slot cards */
 
#define PEAK_PCIEC_DEVICE_ID   0x0002 /* for ExpressCard slot cards */
 
#define PEAK_PCIE_DEVICE_ID   0x0003 /* for nextgen PCIe slot cards */
 
#define PEAK_CPCI_DEVICE_ID   0x0004 /* for nextgen cPCI slot cards */
 
#define PEAK_MPCI_DEVICE_ID   0x0005 /* for nextgen miniPCI slot cards */
 
#define PEAK_PC_104P_DEVICE_ID   0x0006 /* PCAN-PC/104+ cards */
 
#define PEAK_PCI_104E_DEVICE_ID   0x0007 /* PCAN-PCI/104 Express cards */
 
#define PEAK_MPCIE_DEVICE_ID   0x0008 /* The miniPCIe slot cards */
 
#define PEAK_PCI_CHAN_MAX   4
 

Functions

 MODULE_AUTHOR ("Stephane Grosjean <[email protected]>")
 
 MODULE_DESCRIPTION ("Socket-CAN driver for PEAK PCAN PCI family cards")
 
 MODULE_SUPPORTED_DEVICE ("PEAK PCAN PCI/PCIe/PCIeC miniPCI CAN cards")
 
 MODULE_SUPPORTED_DEVICE ("PEAK PCAN miniPCIe/cPCI PC/104+ PCI/104e CAN Cards")
 
 MODULE_LICENSE ("GPL v2")
 
 MODULE_DEVICE_TABLE (pci, peak_pci_tbl)
 
 module_pci_driver (peak_pci_driver)
 

Macro Definition Documentation

#define DRV_NAME   "peak_pci"

Definition at line 39 of file peak_pci.c.

#define PEAK_CPCI_DEVICE_ID   0x0004 /* for nextgen cPCI slot cards */

Definition at line 68 of file peak_pci.c.

#define PEAK_MPCI_DEVICE_ID   0x0005 /* for nextgen miniPCI slot cards */

Definition at line 69 of file peak_pci.c.

#define PEAK_MPCIE_DEVICE_ID   0x0008 /* The miniPCIe slot cards */

Definition at line 72 of file peak_pci.c.

#define PEAK_PC_104P_DEVICE_ID   0x0006 /* PCAN-PC/104+ cards */

Definition at line 70 of file peak_pci.c.

#define PEAK_PCI_104E_DEVICE_ID   0x0007 /* PCAN-PCI/104 Express cards */

Definition at line 71 of file peak_pci.c.

#define PEAK_PCI_CAN_CLOCK   (16000000 / 2)

Definition at line 49 of file peak_pci.c.

#define PEAK_PCI_CDR   (CDR_CBP | CDR_CLKOUT_MASK)

Definition at line 51 of file peak_pci.c.

#define PEAK_PCI_CFG_SIZE   0x1000 /* Size of the config PCI bar */

Definition at line 61 of file peak_pci.c.

#define PEAK_PCI_CHAN_MAX   4

Definition at line 74 of file peak_pci.c.

#define PEAK_PCI_CHAN_SIZE   0x0400 /* Size used by the channel */

Definition at line 62 of file peak_pci.c.

#define PEAK_PCI_DEVICE_ID   0x0001 /* for PCI/PCIe slot cards */

Definition at line 65 of file peak_pci.c.

#define PEAK_PCI_OCR   OCR_TX0_PUSHPULL

Definition at line 52 of file peak_pci.c.

#define PEAK_PCI_VENDOR_ID   0x001C /* The PCI device and vendor IDs */

Definition at line 64 of file peak_pci.c.

#define PEAK_PCIE_DEVICE_ID   0x0003 /* for nextgen PCIe slot cards */

Definition at line 67 of file peak_pci.c.

#define PEAK_PCIEC_DEVICE_ID   0x0002 /* for ExpressCard slot cards */

Definition at line 66 of file peak_pci.c.

#define PITA_GPIOICR   0x18 /* GPIO interface control register */

Definition at line 58 of file peak_pci.c.

#define PITA_ICR   0x00 /* Interrupt control register */

Definition at line 57 of file peak_pci.c.

#define PITA_MISC   0x1C /* Miscellaneous register */

Definition at line 59 of file peak_pci.c.

Function Documentation

MODULE_AUTHOR ( "Stephane Grosjean <[email protected]>"  )
MODULE_DESCRIPTION ( "Socket-CAN driver for PEAK PCAN PCI family cards )
MODULE_DEVICE_TABLE ( pci  ,
peak_pci_tbl   
)
MODULE_LICENSE ( "GPL v2 )
module_pci_driver ( peak_pci_driver  )
MODULE_SUPPORTED_DEVICE ( "PEAK PCAN PCI/PCIe/PCIeC miniPCI CAN cards )
MODULE_SUPPORTED_DEVICE ( "PEAK PCAN miniPCIe/cPCI PC/104+ PCI/104e CAN Cards"  )