亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? istallion.c

?? linux和2410結合開發 用他可以生成2410所需的zImage文件
?? C
?? 第 1 頁 / 共 5 頁
字號:
/*****************************************************************************//* *	istallion.c  -- stallion intelligent multiport serial driver. * *	Copyright (C) 1996-1999  Stallion Technologies (support@stallion.oz.au). *	Copyright (C) 1994-1996  Greg Ungerer. * *	This code is loosely based on the Linux serial driver, written by *	Linus Torvalds, Theodore T'so and others. * *	This program is free software; you can redistribute it and/or modify *	it under the terms of the GNU General Public License as published by *	the Free Software Foundation; either version 2 of the License, or *	(at your option) any later version. * *	This program is distributed in the hope that it will be useful, *	but WITHOUT ANY WARRANTY; without even the implied warranty of *	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the *	GNU General Public License for more details. * *	You should have received a copy of the GNU General Public License *	along with this program; if not, write to the Free Software *	Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. *//*****************************************************************************/#include <linux/config.h>#include <linux/module.h>#include <linux/slab.h>#include <linux/interrupt.h>#include <linux/tty.h>#include <linux/tty_flip.h>#include <linux/serial.h>#include <linux/cdk.h>#include <linux/comstats.h>#include <linux/version.h>#include <linux/istallion.h>#include <linux/ioport.h>#include <linux/delay.h>#include <linux/init.h>#include <linux/devfs_fs_kernel.h>#include <asm/io.h>#include <asm/uaccess.h>#ifdef CONFIG_PCI#include <linux/pci.h>#endif/*****************************************************************************//* *	Define different board types. Not all of the following board types *	are supported by this driver. But I will use the standard "assigned" *	board numbers. Currently supported boards are abbreviated as: *	ECP = EasyConnection 8/64, ONB = ONboard, BBY = Brumby and *	STAL = Stallion. */#define	BRD_UNKNOWN	0#define	BRD_STALLION	1#define	BRD_BRUMBY4	2#define	BRD_ONBOARD2	3#define	BRD_ONBOARD	4#define	BRD_BRUMBY8	5#define	BRD_BRUMBY16	6#define	BRD_ONBOARDE	7#define	BRD_ONBOARD32	9#define	BRD_ONBOARD2_32	10#define	BRD_ONBOARDRS	11#define	BRD_EASYIO	20#define	BRD_ECH		21#define	BRD_ECHMC	22#define	BRD_ECP		23#define BRD_ECPE	24#define	BRD_ECPMC	25#define	BRD_ECHPCI	26#define	BRD_ECH64PCI	27#define	BRD_EASYIOPCI	28#define	BRD_ECPPCI	29#define	BRD_BRUMBY	BRD_BRUMBY4/* *	Define a configuration structure to hold the board configuration. *	Need to set this up in the code (for now) with the boards that are *	to be configured into the system. This is what needs to be modified *	when adding/removing/modifying boards. Each line entry in the *	stli_brdconf[] array is a board. Each line contains io/irq/memory *	ranges for that board (as well as what type of board it is). *	Some examples: *		{ BRD_ECP, 0x2a0, 0, 0xcc000, 0, 0 }, *	This line will configure an EasyConnection 8/64 at io address 2a0, *	and shared memory address of cc000. Multiple EasyConnection 8/64 *	boards can share the same shared memory address space. No interrupt *	is required for this board type. *	Another example: *		{ BRD_ECPE, 0x5000, 0, 0x80000000, 0, 0 }, *	This line will configure an EasyConnection 8/64 EISA in slot 5 and *	shared memory address of 0x80000000 (2 GByte). Multiple *	EasyConnection 8/64 EISA boards can share the same shared memory *	address space. No interrupt is required for this board type. *	Another example: *		{ BRD_ONBOARD, 0x240, 0, 0xd0000, 0, 0 }, *	This line will configure an ONboard (ISA type) at io address 240, *	and shared memory address of d0000. Multiple ONboards can share *	the same shared memory address space. No interrupt required. *	Another example: *		{ BRD_BRUMBY4, 0x360, 0, 0xc8000, 0, 0 }, *	This line will configure a Brumby board (any number of ports!) at *	io address 360 and shared memory address of c8000. All Brumby boards *	configured into a system must have their own separate io and memory *	addresses. No interrupt is required. *	Another example: *		{ BRD_STALLION, 0x330, 0, 0xd0000, 0, 0 }, *	This line will configure an original Stallion board at io address 330 *	and shared memory address d0000 (this would only be valid for a "V4.0" *	or Rev.O Stallion board). All Stallion boards configured into the *	system must have their own separate io and memory addresses. No *	interrupt is required. */typedef struct {	int		brdtype;	int		ioaddr1;	int		ioaddr2;	unsigned long	memaddr;	int		irq;	int		irqtype;} stlconf_t;static stlconf_t	stli_brdconf[] = {	/*{ BRD_ECP, 0x2a0, 0, 0xcc000, 0, 0 },*/};static int	stli_nrbrds = sizeof(stli_brdconf) / sizeof(stlconf_t);/* *	There is some experimental EISA board detection code in this driver. *	By default it is disabled, but for those that want to try it out, *	then set the define below to be 1. */#define	STLI_EISAPROBE	0static devfs_handle_t devfs_handle;/*****************************************************************************//* *	Define some important driver characteristics. Device major numbers *	allocated as per Linux Device Registry. */#ifndef	STL_SIOMEMMAJOR#define	STL_SIOMEMMAJOR		28#endif#ifndef	STL_SERIALMAJOR#define	STL_SERIALMAJOR		24#endif#ifndef	STL_CALLOUTMAJOR#define	STL_CALLOUTMAJOR	25#endif#define	STL_DRVTYPSERIAL	1#define	STL_DRVTYPCALLOUT	2/*****************************************************************************//* *	Define our local driver identity first. Set up stuff to deal with *	all the local structures required by a serial tty driver. */static char	*stli_drvtitle = "Stallion Intelligent Multiport Serial Driver";static char	*stli_drvname = "istallion";static char	*stli_drvversion = "5.6.0";static char	*stli_serialname = "ttyE";static char	*stli_calloutname = "cue";static struct tty_driver	stli_serial;static struct tty_driver	stli_callout;static struct tty_struct	*stli_ttys[STL_MAXDEVS];static struct termios		*stli_termios[STL_MAXDEVS];static struct termios		*stli_termioslocked[STL_MAXDEVS];static int			stli_refcount;/* *	We will need to allocate a temporary write buffer for chars that *	come direct from user space. The problem is that a copy from user *	space might cause a page fault (typically on a system that is *	swapping!). All ports will share one buffer - since if the system *	is already swapping a shared buffer won't make things any worse. */static char			*stli_tmpwritebuf;static DECLARE_MUTEX(stli_tmpwritesem);#define	STLI_TXBUFSIZE		4096/* *	Use a fast local buffer for cooked characters. Typically a whole *	bunch of cooked characters come in for a port, 1 at a time. So we *	save those up into a local buffer, then write out the whole lot *	with a large memcpy. Just use 1 buffer for all ports, since its *	use it is only need for short periods of time by each port. */static char			*stli_txcookbuf;static int			stli_txcooksize;static int			stli_txcookrealsize;static struct tty_struct	*stli_txcooktty;/* *	Define a local default termios struct. All ports will be created *	with this termios initially. Basically all it defines is a raw port *	at 9600 baud, 8 data bits, no parity, 1 stop bit. */static struct termios		stli_deftermios = {	c_cflag:	(B9600 | CS8 | CREAD | HUPCL | CLOCAL),	c_cc:		INIT_C_CC,};/* *	Define global stats structures. Not used often, and can be *	re-used for each stats call. */static comstats_t	stli_comstats;static combrd_t		stli_brdstats;static asystats_t	stli_cdkstats;static stlibrd_t	stli_dummybrd;static stliport_t	stli_dummyport;/*****************************************************************************/static stlibrd_t	*stli_brds[STL_MAXBRDS];static int		stli_shared;/* *	Per board state flags. Used with the state field of the board struct. *	Not really much here... All we need to do is keep track of whether *	the board has been detected, and whether it is actually running a slave *	or not. */#define	BST_FOUND	0x1#define	BST_STARTED	0x2/* *	Define the set of port state flags. These are marked for internal *	state purposes only, usually to do with the state of communications *	with the slave. Most of them need to be updated atomically, so always *	use the bit setting operations (unless protected by cli/sti). */#define	ST_INITIALIZING	1#define	ST_OPENING	2#define	ST_CLOSING	3#define	ST_CMDING	4#define	ST_TXBUSY	5#define	ST_RXING	6#define	ST_DOFLUSHRX	7#define	ST_DOFLUSHTX	8#define	ST_DOSIGS	9#define	ST_RXSTOP	10#define	ST_GETSIGS	11/* *	Define an array of board names as printable strings. Handy for *	referencing boards when printing trace and stuff. */static char	*stli_brdnames[] = {	"Unknown",	"Stallion",	"Brumby",	"ONboard-MC",	"ONboard",	"Brumby",	"Brumby",	"ONboard-EI",	(char *) NULL,	"ONboard",	"ONboard-MC",	"ONboard-MC",	(char *) NULL,	(char *) NULL,	(char *) NULL,	(char *) NULL,	(char *) NULL,	(char *) NULL,	(char *) NULL,	(char *) NULL,	"EasyIO",	"EC8/32-AT",	"EC8/32-MC",	"EC8/64-AT",	"EC8/64-EI",	"EC8/64-MC",	"EC8/32-PCI",	"EC8/64-PCI",	"EasyIO-PCI",	"EC/RA-PCI",};/*****************************************************************************/#ifdef MODULE/* *	Define some string labels for arguments passed from the module *	load line. These allow for easy board definitions, and easy *	modification of the io, memory and irq resoucres. */static char	*board0[8];static char	*board1[8];static char	*board2[8];static char	*board3[8];static char	**stli_brdsp[] = {	(char **) &board0,	(char **) &board1,	(char **) &board2,	(char **) &board3};/* *	Define a set of common board names, and types. This is used to *	parse any module arguments. */typedef struct stlibrdtype {	char	*name;	int	type;} stlibrdtype_t;static stlibrdtype_t	stli_brdstr[] = {	{ "stallion", BRD_STALLION },	{ "1", BRD_STALLION },	{ "brumby", BRD_BRUMBY },	{ "brumby4", BRD_BRUMBY },	{ "brumby/4", BRD_BRUMBY },	{ "brumby-4", BRD_BRUMBY },	{ "brumby8", BRD_BRUMBY },	{ "brumby/8", BRD_BRUMBY },	{ "brumby-8", BRD_BRUMBY },	{ "brumby16", BRD_BRUMBY },	{ "brumby/16", BRD_BRUMBY },	{ "brumby-16", BRD_BRUMBY },	{ "2", BRD_BRUMBY },	{ "onboard2", BRD_ONBOARD2 },	{ "onboard-2", BRD_ONBOARD2 },	{ "onboard/2", BRD_ONBOARD2 },	{ "onboard-mc", BRD_ONBOARD2 },	{ "onboard/mc", BRD_ONBOARD2 },	{ "onboard-mca", BRD_ONBOARD2 },	{ "onboard/mca", BRD_ONBOARD2 },	{ "3", BRD_ONBOARD2 },	{ "onboard", BRD_ONBOARD },	{ "onboardat", BRD_ONBOARD },	{ "4", BRD_ONBOARD },	{ "onboarde", BRD_ONBOARDE },	{ "onboard-e", BRD_ONBOARDE },	{ "onboard/e", BRD_ONBOARDE },	{ "onboard-ei", BRD_ONBOARDE },	{ "onboard/ei", BRD_ONBOARDE },	{ "7", BRD_ONBOARDE },	{ "ecp", BRD_ECP },	{ "ecpat", BRD_ECP },	{ "ec8/64", BRD_ECP },	{ "ec8/64-at", BRD_ECP },	{ "ec8/64-isa", BRD_ECP },	{ "23", BRD_ECP },	{ "ecpe", BRD_ECPE },	{ "ecpei", BRD_ECPE },	{ "ec8/64-e", BRD_ECPE },	{ "ec8/64-ei", BRD_ECPE },	{ "24", BRD_ECPE },	{ "ecpmc", BRD_ECPMC },	{ "ec8/64-mc", BRD_ECPMC },	{ "ec8/64-mca", BRD_ECPMC },	{ "25", BRD_ECPMC },	{ "ecppci", BRD_ECPPCI },	{ "ec/ra", BRD_ECPPCI },	{ "ec/ra-pc", BRD_ECPPCI },	{ "ec/ra-pci", BRD_ECPPCI },	{ "29", BRD_ECPPCI },};/* *	Define the module agruments. */MODULE_AUTHOR("Greg Ungerer");MODULE_DESCRIPTION("Stallion Intelligent Multiport Serial Driver");MODULE_LICENSE("GPL");MODULE_PARM(board0, "1-3s");MODULE_PARM_DESC(board0, "Board 0 config -> name[,ioaddr[,memaddr]");MODULE_PARM(board1, "1-3s");MODULE_PARM_DESC(board1, "Board 1 config -> name[,ioaddr[,memaddr]");MODULE_PARM(board2, "1-3s");MODULE_PARM_DESC(board2, "Board 2 config -> name[,ioaddr[,memaddr]");MODULE_PARM(board3, "1-3s");MODULE_PARM_DESC(board3, "Board 3 config -> name[,ioaddr[,memaddr]");#endif/* *	Set up a default memory address table for EISA board probing. *	The default addresses are all bellow 1Mbyte, which has to be the *	case anyway. They should be safe, since we only read values from *	them, and interrupts are disabled while we do it. If the higher *	memory support is compiled in then we also try probing around *	the 1Gb, 2Gb and 3Gb areas as well... */static unsigned long	stli_eisamemprobeaddrs[] = {	0xc0000,    0xd0000,    0xe0000,    0xf0000,	0x80000000, 0x80010000, 0x80020000, 0x80030000,	0x40000000, 0x40010000, 0x40020000, 0x40030000,	0xc0000000, 0xc0010000, 0xc0020000, 0xc0030000,	0xff000000, 0xff010000, 0xff020000, 0xff030000,};static int	stli_eisamempsize = sizeof(stli_eisamemprobeaddrs) / sizeof(unsigned long);int		stli_eisaprobe = STLI_EISAPROBE;/* *	Define the Stallion PCI vendor and device IDs. */#ifdef CONFIG_PCI#ifndef	PCI_VENDOR_ID_STALLION#define	PCI_VENDOR_ID_STALLION		0x124d#endif#ifndef PCI_DEVICE_ID_ECRA#define	PCI_DEVICE_ID_ECRA		0x0004#endif#endifstatic struct pci_device_id istallion_pci_tbl[] = {	{ PCI_VENDOR_ID_STALLION, PCI_DEVICE_ID_ECRA, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 },	{ 0 }};MODULE_DEVICE_TABLE(pci, istallion_pci_tbl);/*****************************************************************************//* *	Hardware configuration info for ECP boards. These defines apply *	to the directly accessible io ports of the ECP. There is a set of *	defines for each ECP board type, ISA, EISA, MCA and PCI. */#define	ECP_IOSIZE	4#define	ECP_MEMSIZE	(128 * 1024)#define	ECP_PCIMEMSIZE	(256 * 1024)#define	ECP_ATPAGESIZE	(4 * 1024)#define	ECP_MCPAGESIZE	(4 * 1024)#define	ECP_EIPAGESIZE	(64 * 1024)#define	ECP_PCIPAGESIZE	(64 * 1024)#define	STL_EISAID	0x8c4e/* *	Important defines for the ISA class of ECP board. */#define	ECP_ATIREG	0#define	ECP_ATCONFR	1#define	ECP_ATMEMAR	2#define	ECP_ATMEMPR	3#define	ECP_ATSTOP	0x1#define	ECP_ATINTENAB	0x10#define	ECP_ATENABLE	0x20#define	ECP_ATDISABLE	0x00#define	ECP_ATADDRMASK	0x3f000

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
337p亚洲精品色噜噜噜| 成人福利视频在线看| 日韩影院在线观看| 看片的网站亚洲| 麻豆精品蜜桃视频网站| 国产一区二区三区| 成人一级片在线观看| 91一区二区三区在线观看| 色乱码一区二区三区88| 欧美日韩免费不卡视频一区二区三区 | 国产精品情趣视频| 亚洲制服欧美中文字幕中文字幕| 日本一区二区不卡视频| 久久精品亚洲乱码伦伦中文| 久久久精品2019中文字幕之3| 亚洲精选视频免费看| 免费一级片91| 99国产精品国产精品毛片| 精品视频1区2区| 国产精品久久久久久久久免费丝袜| 亚洲成人免费电影| 国产精品亚洲人在线观看| 欧美久久高跟鞋激| 亚洲视频狠狠干| 高清成人在线观看| 国产亚洲精品福利| 久久99久久精品| 日韩视频在线你懂得| 亚洲成人免费在线| 欧美日韩日日摸| 亚洲成人在线网站| 在线精品亚洲一区二区不卡| 国产精品色呦呦| 白白色 亚洲乱淫| 国产精品成人午夜| 成人免费毛片app| www国产精品av| 视频在线在亚洲| 7777精品伊人久久久大香线蕉最新版| 国产精品久久久久久久久久久免费看| 国内一区二区在线| 久久九九久精品国产免费直播| 狠狠久久亚洲欧美| 日本一区二区三级电影在线观看| 国产主播一区二区三区| 久久久天堂av| av不卡在线播放| 亚洲图片自拍偷拍| 精品国产91九色蝌蚪| 国产九九视频一区二区三区| 中国av一区二区三区| 色婷婷狠狠综合| 三级精品在线观看| 久久久国产综合精品女国产盗摄| 欧美怡红院视频| 亚洲6080在线| 久久久久88色偷偷免费| 日本韩国欧美三级| 久久99热这里只有精品| 亚洲欧美视频一区| 久久影音资源网| 精品一区二区三区香蕉蜜桃 | 亚洲蜜桃精久久久久久久| 91精品啪在线观看国产60岁| 国产高清一区日本| 婷婷丁香激情综合| 亚洲欧美区自拍先锋| 精品国产青草久久久久福利| 精品视频在线免费观看| www.欧美日韩国产在线| 精品一区精品二区高清| 亚洲成人一区二区| 18涩涩午夜精品.www| 国产视频一区在线播放| 欧美成人三级电影在线| 7777精品伊人久久久大香线蕉的 | 国产精品久久久久精k8| 精品三级av在线| 日韩精品影音先锋| 91精品国产福利在线观看| 欧美女孩性生活视频| 欧美无砖专区一中文字| 99久久精品免费看国产| 日本亚洲免费观看| 久久久久久久久久看片| 日韩欧美亚洲另类制服综合在线| 欧日韩精品视频| 欧美日韩一区二区不卡| 欧美精品在线一区二区| 91精品国产综合久久久久久久久久 | 欧美视频一区二区三区四区 | **网站欧美大片在线观看| 国产欧美日韩精品在线| 欧美激情综合五月色丁香| 国产精品久久久久影院色老大| 欧美国产综合色视频| 亚洲男女毛片无遮挡| 亚洲午夜电影在线观看| 老司机一区二区| 蜜桃视频一区二区三区在线观看| 日本欧美韩国一区三区| 成人性色生活片免费看爆迷你毛片| 成人av在线观| 在线电影国产精品| 国产日韩精品视频一区| 久久婷婷国产综合国色天香| 国产午夜精品一区二区| 午夜精品一区二区三区免费视频| 日本人妖一区二区| 在线观看视频一区| 国产女主播视频一区二区| 亚洲激情第一区| 成人性生交大合| 日韩欧美一区中文| 亚洲综合无码一区二区| 国产+成+人+亚洲欧洲自线| 欧美另类久久久品| 亚洲欧美另类在线| 国产美女视频91| 精品国产a毛片| 蜜臀精品一区二区三区在线观看| 91在线视频观看| 国产清纯白嫩初高生在线观看91| 亚洲最大色网站| 一本久久精品一区二区| 亚洲国产精品高清| 国产精品亚洲成人| 精品国产3级a| 国产精品一二三| 26uuu国产在线精品一区二区| 日本欧美久久久久免费播放网| 欧美午夜理伦三级在线观看| 亚洲伦在线观看| 91黄色免费观看| 亚洲一区二区三区影院| 免费在线看成人av| 日韩视频免费观看高清完整版在线观看 | 2022国产精品视频| 风间由美一区二区av101 | 成人网男人的天堂| 国产精品国产三级国产有无不卡| www.亚洲免费av| 亚洲小说春色综合另类电影| 欧美tickle裸体挠脚心vk| 国产综合成人久久大片91| 久久先锋影音av鲁色资源网| 成人性生交大合| 亚州成人在线电影| 欧美成人a∨高清免费观看| 成人av动漫在线| 水野朝阳av一区二区三区| 国产精品免费av| 日韩欧美在线影院| 欧美综合在线视频| 国产成人夜色高潮福利影视| 亚洲永久免费视频| 国产精品久久久久久久久动漫| 日本国产一区二区| 精品在线亚洲视频| 手机精品视频在线观看| 日韩伦理免费电影| 国产欧美一二三区| 在线成人小视频| 国产在线一区二区| 日韩在线播放一区二区| 亚洲免费观看高清完整版在线观看熊 | 6080午夜不卡| 日本道精品一区二区三区| 成人的网站免费观看| 国产一区二三区| 国产一区二区按摩在线观看| 午夜精品久久久久久久久| 亚洲国产美国国产综合一区二区| 精品国产一区二区国模嫣然| 日韩视频永久免费| 91精品国产综合久久精品性色| 欧美日韩国产123区| 91麻豆精品国产自产在线| 欧美精品亚洲一区二区在线播放| 欧美性色aⅴ视频一区日韩精品| 99久久亚洲一区二区三区青草| 不卡的av中国片| 一本大道久久精品懂色aⅴ| 色综合咪咪久久| 欧美日韩亚州综合| 日韩区在线观看| 欧美韩国一区二区| 一区二区三区免费观看| 日本不卡一二三区黄网| 国产精品一二一区| 欧美色综合久久| 久久女同精品一区二区| 亚洲精品国产高清久久伦理二区| 洋洋av久久久久久久一区| 国产亚洲成年网址在线观看| 国产精品国产馆在线真实露脸| 亚洲日本在线a| 国产精品一二三| 欧美久久久久久久久中文字幕| 国产精品三级av|