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

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

?? istallion.c

?? linux和2410結合開發 用他可以生成2410所需的zImage文件
?? C
?? 第 1 頁 / 共 5 頁
字號:
static unsigned long stli_atol(char *str){	unsigned long	val;	int		base, c;	char		*sp;	val = 0;	sp = str;	if ((*sp == '0') && (*(sp+1) == 'x')) {		base = 16;		sp += 2;	} else if (*sp == '0') {		base = 8;		sp++;	} else {		base = 10;	}	for (; (*sp != 0); sp++) {		c = (*sp > '9') ? (TOLOWER(*sp) - 'a' + 10) : (*sp - '0');		if ((c < 0) || (c >= base)) {			printk("STALLION: invalid argument %s\n", str);			val = 0;			break;		}		val = (val * base) + c;	}	return(val);}/*****************************************************************************//* *	Parse the supplied argument string, into the board conf struct. */static int stli_parsebrd(stlconf_t *confp, char **argp){	char	*sp;	int	nrbrdnames, i;#if DEBUG	printk("stli_parsebrd(confp=%x,argp=%x)\n", (int) confp, (int) argp);#endif	if ((argp[0] == (char *) NULL) || (*argp[0] == 0))		return(0);	for (sp = argp[0], i = 0; ((*sp != 0) && (i < 25)); sp++, i++)		*sp = TOLOWER(*sp);	nrbrdnames = sizeof(stli_brdstr) / sizeof(stlibrdtype_t);	for (i = 0; (i < nrbrdnames); i++) {		if (strcmp(stli_brdstr[i].name, argp[0]) == 0)			break;	}	if (i >= nrbrdnames) {		printk("STALLION: unknown board name, %s?\n", argp[0]);		return(0);	}	confp->brdtype = stli_brdstr[i].type;	if ((argp[1] != (char *) NULL) && (*argp[1] != 0))		confp->ioaddr1 = stli_atol(argp[1]);	if ((argp[2] != (char *) NULL) && (*argp[2] != 0))		confp->memaddr = stli_atol(argp[2]);	return(1);}#endif/*****************************************************************************//* *	Local driver kernel malloc routine. */static void *stli_memalloc(int len){	return((void *) kmalloc(len, GFP_KERNEL));}/*****************************************************************************/static int stli_open(struct tty_struct *tty, struct file *filp){	stlibrd_t	*brdp;	stliport_t	*portp;	unsigned int	minordev;	int		brdnr, portnr, rc;#if DEBUG	printk("stli_open(tty=%x,filp=%x): device=%x\n", (int) tty,		(int) filp, tty->device);#endif	minordev = MINOR(tty->device);	brdnr = MINOR2BRD(minordev);	if (brdnr >= stli_nrbrds)		return(-ENODEV);	brdp = stli_brds[brdnr];	if (brdp == (stlibrd_t *) NULL)		return(-ENODEV);	if ((brdp->state & BST_STARTED) == 0)		return(-ENODEV);	portnr = MINOR2PORT(minordev);	if ((portnr < 0) || (portnr > brdp->nrports))		return(-ENODEV);	portp = brdp->ports[portnr];	if (portp == (stliport_t *) NULL)		return(-ENODEV);	if (portp->devnr < 1)		return(-ENODEV);	MOD_INC_USE_COUNT;/* *	Check if this port is in the middle of closing. If so then wait *	until it is closed then return error status based on flag settings. *	The sleep here does not need interrupt protection since the wakeup *	for it is done with the same context. */	if (portp->flags & ASYNC_CLOSING) {		interruptible_sleep_on(&portp->close_wait);		if (portp->flags & ASYNC_HUP_NOTIFY)			return(-EAGAIN);		return(-ERESTARTSYS);	}/* *	On the first open of the device setup the port hardware, and *	initialize the per port data structure. Since initializing the port *	requires several commands to the board we will need to wait for any *	other open that is already initializing the port. */	portp->tty = tty;	tty->driver_data = portp;	portp->refcount++;	while (test_bit(ST_INITIALIZING, &portp->state)) {		if (signal_pending(current))			return(-ERESTARTSYS);		interruptible_sleep_on(&portp->raw_wait);	}	if ((portp->flags & ASYNC_INITIALIZED) == 0) {		set_bit(ST_INITIALIZING, &portp->state);		if ((rc = stli_initopen(brdp, portp)) >= 0) {			portp->flags |= ASYNC_INITIALIZED;			clear_bit(TTY_IO_ERROR, &tty->flags);		}		clear_bit(ST_INITIALIZING, &portp->state);		wake_up_interruptible(&portp->raw_wait);		if (rc < 0)			return(rc);	}/* *	Check if this port is in the middle of closing. If so then wait *	until it is closed then return error status, based on flag settings. *	The sleep here does not need interrupt protection since the wakeup *	for it is done with the same context. */	if (portp->flags & ASYNC_CLOSING) {		interruptible_sleep_on(&portp->close_wait);		if (portp->flags & ASYNC_HUP_NOTIFY)			return(-EAGAIN);		return(-ERESTARTSYS);	}/* *	Based on type of open being done check if it can overlap with any *	previous opens still in effect. If we are a normal serial device *	then also we might have to wait for carrier. */	if (tty->driver.subtype == STL_DRVTYPCALLOUT) {		if (portp->flags & ASYNC_NORMAL_ACTIVE)			return(-EBUSY);		if (portp->flags & ASYNC_CALLOUT_ACTIVE) {			if ((portp->flags & ASYNC_SESSION_LOCKOUT) &&			    (portp->session != current->session))				return(-EBUSY);			if ((portp->flags & ASYNC_PGRP_LOCKOUT) &&			    (portp->pgrp != current->pgrp))				return(-EBUSY);		}		portp->flags |= ASYNC_CALLOUT_ACTIVE;	} else {		if (filp->f_flags & O_NONBLOCK) {			if (portp->flags & ASYNC_CALLOUT_ACTIVE)				return(-EBUSY);		} else {			if ((rc = stli_waitcarrier(brdp, portp, filp)) != 0)				return(rc);		}		portp->flags |= ASYNC_NORMAL_ACTIVE;	}	if ((portp->refcount == 1) && (portp->flags & ASYNC_SPLIT_TERMIOS)) {		if (tty->driver.subtype == STL_DRVTYPSERIAL)			*tty->termios = portp->normaltermios;		else			*tty->termios = portp->callouttermios;		stli_setport(portp);	}	portp->session = current->session;	portp->pgrp = current->pgrp;	return(0);}/*****************************************************************************/static void stli_close(struct tty_struct *tty, struct file *filp){	stlibrd_t	*brdp;	stliport_t	*portp;	unsigned long	flags;#if DEBUG	printk("stli_close(tty=%x,filp=%x)\n", (int) tty, (int) filp);#endif	portp = tty->driver_data;	if (portp == (stliport_t *) NULL)		return;	save_flags(flags);	cli();	if (tty_hung_up_p(filp)) {		MOD_DEC_USE_COUNT;		restore_flags(flags);		return;	}	if ((tty->count == 1) && (portp->refcount != 1))		portp->refcount = 1;	if (portp->refcount-- > 1) {		MOD_DEC_USE_COUNT;		restore_flags(flags);		return;	}	portp->flags |= ASYNC_CLOSING;	if (portp->flags & ASYNC_NORMAL_ACTIVE)		portp->normaltermios = *tty->termios;	if (portp->flags & ASYNC_CALLOUT_ACTIVE)		portp->callouttermios = *tty->termios;/* *	May want to wait for data to drain before closing. The BUSY flag *	keeps track of whether we are still transmitting or not. It is *	updated by messages from the slave - indicating when all chars *	really have drained. */	if (tty == stli_txcooktty)		stli_flushchars(tty);	tty->closing = 1;	if (portp->closing_wait != ASYNC_CLOSING_WAIT_NONE)		tty_wait_until_sent(tty, portp->closing_wait);	portp->flags &= ~ASYNC_INITIALIZED;	brdp = stli_brds[portp->brdnr];	stli_rawclose(brdp, portp, 0, 0);	if (tty->termios->c_cflag & HUPCL) {		stli_mkasysigs(&portp->asig, 0, 0);		if (test_bit(ST_CMDING, &portp->state))			set_bit(ST_DOSIGS, &portp->state);		else			stli_sendcmd(brdp, portp, A_SETSIGNALS, &portp->asig,				sizeof(asysigs_t), 0);	}	clear_bit(ST_TXBUSY, &portp->state);	clear_bit(ST_RXSTOP, &portp->state);	set_bit(TTY_IO_ERROR, &tty->flags);	if (tty->ldisc.flush_buffer)		(tty->ldisc.flush_buffer)(tty);	set_bit(ST_DOFLUSHRX, &portp->state);	stli_flushbuffer(tty);	tty->closing = 0;	portp->tty = (struct tty_struct *) NULL;	if (portp->openwaitcnt) {		if (portp->close_delay)			stli_delay(portp->close_delay);		wake_up_interruptible(&portp->open_wait);	}	portp->flags &= ~(ASYNC_CALLOUT_ACTIVE | ASYNC_NORMAL_ACTIVE |		ASYNC_CLOSING);	wake_up_interruptible(&portp->close_wait);	MOD_DEC_USE_COUNT;	restore_flags(flags);}/*****************************************************************************//* *	Carry out first open operations on a port. This involves a number of *	commands to be sent to the slave. We need to open the port, set the *	notification events, set the initial port settings, get and set the *	initial signal values. We sleep and wait in between each one. But *	this still all happens pretty quickly. */static int stli_initopen(stlibrd_t *brdp, stliport_t *portp){	struct tty_struct	*tty;	asynotify_t		nt;	asyport_t		aport;	int			rc;#if DEBUG	printk("stli_initopen(brdp=%x,portp=%x)\n", (int) brdp, (int) portp);#endif	if ((rc = stli_rawopen(brdp, portp, 0, 1)) < 0)		return(rc);	memset(&nt, 0, sizeof(asynotify_t));	nt.data = (DT_TXLOW | DT_TXEMPTY | DT_RXBUSY | DT_RXBREAK);	nt.signal = SG_DCD;	if ((rc = stli_cmdwait(brdp, portp, A_SETNOTIFY, &nt,	    sizeof(asynotify_t), 0)) < 0)		return(rc);	tty = portp->tty;	if (tty == (struct tty_struct *) NULL)		return(-ENODEV);	stli_mkasyport(portp, &aport, tty->termios);	if ((rc = stli_cmdwait(brdp, portp, A_SETPORT, &aport,	    sizeof(asyport_t), 0)) < 0)		return(rc);	set_bit(ST_GETSIGS, &portp->state);	if ((rc = stli_cmdwait(brdp, portp, A_GETSIGNALS, &portp->asig,	    sizeof(asysigs_t), 1)) < 0)		return(rc);	if (test_and_clear_bit(ST_GETSIGS, &portp->state))		portp->sigs = stli_mktiocm(portp->asig.sigvalue);	stli_mkasysigs(&portp->asig, 1, 1);	if ((rc = stli_cmdwait(brdp, portp, A_SETSIGNALS, &portp->asig,	    sizeof(asysigs_t), 0)) < 0)		return(rc);	return(0);}/*****************************************************************************//* *	Send an open message to the slave. This will sleep waiting for the *	acknowledgement, so must have user context. We need to co-ordinate *	with close events here, since we don't want open and close events *	to overlap. */static int stli_rawopen(stlibrd_t *brdp, stliport_t *portp, unsigned long arg, int wait){	volatile cdkhdr_t	*hdrp;	volatile cdkctrl_t	*cp;	volatile unsigned char	*bits;	unsigned long		flags;	int			rc;#if DEBUG	printk("stli_rawopen(brdp=%x,portp=%x,arg=%x,wait=%d)\n",		(int) brdp, (int) portp, (int) arg, wait);#endif/* *	Send a message to the slave to open this port. */	save_flags(flags);	cli();/* *	Slave is already closing this port. This can happen if a hangup *	occurs on this port. So we must wait until it is complete. The *	order of opens and closes may not be preserved across shared *	memory, so we must wait until it is complete. */	while (test_bit(ST_CLOSING, &portp->state)) {		if (signal_pending(current)) {			restore_flags(flags);			return(-ERESTARTSYS);		}		interruptible_sleep_on(&portp->raw_wait);	}/* *	Everything is ready now, so write the open message into shared *	memory. Once the message is in set the service bits to say that *	this port wants service. */	EBRDENABLE(brdp);	cp = &((volatile cdkasy_t *) EBRDGETMEMPTR(brdp, portp->addr))->ctrl;	cp->openarg = arg;	cp->open = 1;	hdrp = (volatile cdkhdr_t *) EBRDGETMEMPTR(brdp, CDK_CDKADDR);	bits = ((volatile unsigned char *) hdrp) + brdp->slaveoffset +		portp->portidx;	*bits |= portp->portbit;	EBRDDISABLE(brdp);	if (wait == 0) {		restore_flags(flags);		return(0);	}/* *	Slave is in action, so now we must wait for the open acknowledgment *	to come back. */	rc = 0;	set_bit(ST_OPENING, &portp->state);	while (test_bit(ST_OPENING, &portp->state)) {		if (signal_pending(current)) {			rc = -ERESTARTSYS;			break;		}		interruptible_sleep_on(&portp->raw_wait);	}	restore_flags(flags);	if ((rc == 0) && (portp->rc != 0))		rc = -EIO;	return(rc);}/*****************************************************************************//* *	Send a close message to the slave. Normally this will sleep waiting *	for the acknowledgement, but if wait parameter is 0 it will not. If *	wait is true then must have user context (to sleep). */static int stli_rawclose(stlibrd_t *brdp, stliport_t *portp, unsigned long arg, int wait){	volatile cdkhdr_t	*hdrp;	volatile cdkctrl_t	*cp;	volatile unsigned char	*bits;	unsigned long		flags;	int			rc;#if DEBUG	printk("stli_rawclose(brdp=%x,portp=%x,arg=%x,wait=%d)\n",		(int) brdp, (int) portp, (int) arg, wait);#endif	save_flags(flags);	cli();/* *	Slave is already closing this port. This can happen if a hangup *	occurs on this port. */	if (wait) {		while (test_bit(ST_CLOSING, &portp->state)) {			if (signal_pending(current)) {				restore_flags(flags);				return(-ERESTARTSYS);			}			interruptible_sleep_on(&portp->raw_wait);		}	}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
一区二区三区不卡视频在线观看| 日韩有码一区二区三区| 亚洲一区二区三区美女| 国产一区二区三区四区五区入口 | 五月天亚洲精品| 国产成人精品一区二区三区四区| 欧美日韩免费高清一区色橹橹| 国产视频一区在线观看| 日韩国产欧美一区二区三区| proumb性欧美在线观看| 精品国产一区a| 婷婷久久综合九色综合绿巨人| 99国产精品国产精品毛片| 精品欧美一区二区久久| 亚洲一区二区三区四区的| 成人动漫一区二区| 久久久久久久久岛国免费| 蜜臀国产一区二区三区在线播放 | 亚洲va欧美va人人爽| 成人av一区二区三区| 精品噜噜噜噜久久久久久久久试看 | 亚洲欧美日韩人成在线播放| 久久国内精品自在自线400部| 91豆麻精品91久久久久久| 国产精品久久夜| 国产一区免费电影| 久久伊人蜜桃av一区二区| 另类小说图片综合网| 欧美一区二区成人| 五月天精品一区二区三区| 欧美日韩不卡一区| 亚洲1区2区3区4区| 91精品免费在线| 美腿丝袜一区二区三区| 欧美电影免费观看高清完整版在线观看| 亚洲国产综合在线| 欧美精品v日韩精品v韩国精品v| 一卡二卡欧美日韩| 欧美日韩亚洲综合在线 | 国产一区二区三区在线观看免费| 欧美成人性福生活免费看| 日韩激情在线观看| 精品国产一区二区精华| 国内外成人在线| 中国色在线观看另类| www.亚洲精品| 一卡二卡欧美日韩| 欧美一区二区三区在| 精品一二三四区| 国产婷婷色一区二区三区| 国产91精品入口| 中文字幕一区二区视频| 97久久人人超碰| 伊人一区二区三区| 欧美日韩午夜在线视频| 韩国v欧美v日本v亚洲v| 国产精品美女久久久久久久久久久 | 国产高清无密码一区二区三区| 精品久久久久久久久久久久久久久| 另类调教123区 | 精品国产一区二区国模嫣然| 国产成人免费视| 一区二区三区四区在线| 91精品午夜视频| 成人免费视频播放| 亚洲国产色一区| 精品国产乱码久久久久久牛牛| 成人丝袜18视频在线观看| 亚洲自拍偷拍av| 久久久久国产成人精品亚洲午夜| 国产激情偷乱视频一区二区三区| 亚洲日本va午夜在线电影| 正在播放亚洲一区| 99久久久国产精品| 日本欧美在线观看| 国产精品福利一区| 日韩欧美国产精品| 色婷婷香蕉在线一区二区| 裸体在线国模精品偷拍| 亚洲精品视频在线观看免费| 精品少妇一区二区三区日产乱码| 91麻豆产精品久久久久久| 久久se这里有精品| 亚洲一区二区五区| 国产精品区一区二区三区| 91精品一区二区三区久久久久久| 99久久er热在这里只有精品66| 日本女人一区二区三区| 亚洲精品免费一二三区| 久久亚洲一区二区三区四区| 欧美另类变人与禽xxxxx| a4yy欧美一区二区三区| 精品一区二区三区欧美| 午夜视频在线观看一区二区| 国产精品久久久久三级| 久久久亚洲国产美女国产盗摄| 欧美伊人精品成人久久综合97| 成人影视亚洲图片在线| 激情综合网最新| 日韩激情一区二区| 性做久久久久久久久| 亚洲精品一卡二卡| 自拍偷自拍亚洲精品播放| 日本一区二区免费在线| 精品国产一二三| 欧美大度的电影原声| 欧美日韩免费一区二区三区视频 | 国产美女主播视频一区| 久久精品噜噜噜成人av农村| 舔着乳尖日韩一区| 性做久久久久久免费观看欧美| 一区二区在线电影| 亚洲色图在线播放| 亚洲女与黑人做爰| 国产精品福利av| 亚洲欧美国产77777| 亚洲色图制服诱惑| 一区二区免费在线播放| 亚洲综合一区二区三区| 亚洲一卡二卡三卡四卡无卡久久| ㊣最新国产の精品bt伙计久久| 国产精品视频看| 日韩码欧中文字| 自拍av一区二区三区| 亚洲黄色av一区| 亚洲一区二区精品久久av| 亚洲自拍偷拍九九九| 三级亚洲高清视频| 久久精品国产99久久6| 国产精品12区| 91在线播放网址| 欧美高清视频一二三区| 91精品国产色综合久久久蜜香臀| 日韩一区二区在线看片| 久久久久高清精品| 亚洲视频在线一区| 日本在线观看不卡视频| 国产伦精品一区二区三区免费| 国产成人99久久亚洲综合精品| 91在线码无精品| 91精品国产色综合久久不卡电影 | 91麻豆精品国产91久久久久久| 日韩视频免费观看高清在线视频| 亚洲精品一线二线三线无人区| 国产欧美日韩中文久久| 亚洲免费观看高清完整版在线 | 亚洲国产精品久久人人爱蜜臀| 美国毛片一区二区三区| 国产又粗又猛又爽又黄91精品| 91热门视频在线观看| 91精品国产综合久久福利 | 日韩精品中文字幕在线不卡尤物| 日韩精品专区在线| 亚洲欧美电影一区二区| 免费在线看一区| 99这里都是精品| 日韩一区二区三区免费看| 国产精品亲子乱子伦xxxx裸| 亚洲综合网站在线观看| 国产成人一级电影| 欧美日韩高清一区二区不卡 | 精品卡一卡二卡三卡四在线| 中文字幕一区在线| 狠狠网亚洲精品| 欧洲激情一区二区| 国产亚洲欧美中文| 奇米综合一区二区三区精品视频| 风间由美性色一区二区三区| 欧美日本韩国一区| 最好看的中文字幕久久| 开心九九激情九九欧美日韩精美视频电影 | 欧美日韩精品专区| 亚洲欧洲国产日本综合| 经典三级一区二区| 欧美少妇一区二区| 亚洲视频一区在线| 国产精品一级二级三级| 日韩精品综合一本久道在线视频| 亚洲另类春色国产| 成人一级片在线观看| 精品欧美一区二区在线观看| 亚洲高清视频中文字幕| 91丨porny丨最新| 久久精品视频免费观看| 欧美aaaaaa午夜精品| 欧美精品久久久久久久多人混战| 亚洲欧美综合色| 国产精品一二一区| 久久影院视频免费| 久久丁香综合五月国产三级网站| 911精品产国品一二三产区| 亚洲综合丝袜美腿| 欧美在线观看一区| 亚洲一区日韩精品中文字幕| www.在线欧美| 一区二区三区波多野结衣在线观看| 成人av免费网站| 亚洲三级在线播放| 一本色道久久综合亚洲精品按摩| 国产精品国产三级国产普通话99 |