#include <linux/module.h>
#include <linux/errno.h>
#include <linux/signal.h>
#include <linux/sched.h>
#include <linux/timer.h>
#include <linux/interrupt.h>
#include <linux/tty.h>
#include <linux/tty_flip.h>
#include <linux/serial.h>
#include <linux/serial_reg.h>
#include <linux/major.h>
#include <linux/string.h>
#include <linux/fcntl.h>
#include <linux/ptrace.h>
#include <linux/ioport.h>
#include <linux/mm.h>
#include <linux/delay.h>
#include <linux/pci.h>
#include <linux/bitops.h>
#include <linux/slab.h>
#include <linux/ratelimit.h>
#include <asm/io.h>
#include <asm/irq.h>
#include <asm/uaccess.h>
#include "mxser.h"
Go to the source code of this file.
|
| MODULE_DEVICE_TABLE (pci, mxser_pcibrds) |
|
| MODULE_AUTHOR ("Casper Yang") |
|
| MODULE_DESCRIPTION ("MOXA Smartio/Industio Family Multiport Board Device Driver") |
|
| module_param_array (ioaddr, ulong, NULL, 0) |
|
| MODULE_PARM_DESC (ioaddr,"ISA io addresses to look for a moxa board") |
|
| module_param (ttymajor, int, 0) |
|
| MODULE_LICENSE ("GPL") |
|
| module_param (allow_overlapping_vector, bool, S_IRUGO) |
|
| MODULE_PARM_DESC (allow_overlapping_vector,"whether we allow ISA cards to be configured such that vector overlabs IO ports (default=no)") |
|
| module_init (mxser_module_init) |
|
| module_exit (mxser_module_exit) |
|
#define CHIP_CS 0x04 /* Serial Chip Select in Eprom */ |
#define CHIP_DI 0x08 /* Serial Data Input in Eprom */ |
#define CHIP_DO 0x02 /* Serial Data Output in Eprom */ |
#define CHIP_SK 0x01 /* Serial Data Clock in Eprom */ |
#define EN0_DCFG 0x00E /* Data configuration reg WR */ |
#define EN0_PORT 0x010 /* Rcv missed frame error counter RD */ |
#define EN0_RCNTHI 0x00B /* Remote byte count reg WR */ |
#define EN0_RCNTLO 0x00A /* Remote byte count reg WR */ |
#define EN0_RSARHI 0x009 /* Remote start address reg 1 */ |
#define EN0_RSARLO 0x008 /* Remote start address reg 0 */ |
#define EN_CCMD 0x000 /* Chip's command register */ |
#define ENC_PAGE0 0x000 /* Select page 0 of chip registers */ |
#define ENC_PAGE3 0x0C0 /* Select page 3 of chip registers */ |
#define MOXA_MUST_MU150_HWID 0x01 |
#define MOXA_MUST_MU860_HWID 0x02 |
#define MOXA_OTHER_UART 0x00 |
#define MXSER_BOARDS 4 /* Max. boards */ |
#define MXSER_ISR_PASS_LIMIT 100 |
#define MXSER_VERSION "2.0.5" /* 1.14 */ |
#define PCI_DEVICE_ID_CB108 0x1080 |
#define PCI_DEVICE_ID_CB114 0x1142 |
#define PCI_DEVICE_ID_CB134I 0x1341 |
#define PCI_DEVICE_ID_CP102UF 0x1023 |
#define PCI_DEVICE_ID_CP112UL 0x1120 |
#define PCI_DEVICE_ID_CP114UL 0x1143 |
#define PCI_DEVICE_ID_CP138U 0x1380 |
#define PCI_DEVICE_ID_POS104UL 0x1044 |
#define UART_LSR_SPECIAL 0x1E |
#define UART_MCR_AFE 0x20 |
MODULE_AUTHOR |
( |
"Casper Yang" |
| ) |
|
MODULE_DESCRIPTION |
( |
"MOXA Smartio/Industio Family Multiport Board Device Driver" |
| ) |
|
MODULE_DEVICE_TABLE |
( |
pci |
, |
|
|
mxser_pcibrds |
|
|
) |
| |
module_exit |
( |
mxser_module_exit |
| ) |
|
module_init |
( |
mxser_module_init |
| ) |
|
module_param |
( |
ttymajor |
, |
|
|
int |
, |
|
|
0 |
|
|
) |
| |
module_param |
( |
allow_overlapping_vector |
, |
|
|
bool |
, |
|
|
S_IRUGO |
|
|
) |
| |
module_param_array |
( |
ioaddr |
, |
|
|
ulong |
, |
|
|
NULL |
, |
|
|
0 |
|
|
) |
| |
MODULE_PARM_DESC |
( |
ioaddr |
, |
|
|
"ISA io addresses to look for a moxa board" |
|
|
) |
| |