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

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

?? i2o1.c

?? 支持linux-2.4以后的啟動參數設置
?? C
?? 第 1 頁 / 共 2 頁
字號:
/********************************************************* * $Id * * copyright @ Motorola, 1999 *********************************************************/#include "i2o.h"extern unsigned int load_runtime_reg( unsigned int eumbbar, unsigned int reg );#pragma Alias( load_runtime_reg, "load_runtime_reg" );extern void store_runtime_reg( unsigned int eumbbar, unsigned int reg, unsigned int val );#pragma Alias( store_runtime_reg, "store_runtime_reg" );typedef struct _fifo_stat{    QUEUE_SIZE   qsz;    unsigned int qba;} FIFOSTAT;FIFOSTAT fifo_stat = { QSIZE_4K, 0xffffffff };/********************************************************************************** * function: I2OMsgEnable * * description: Enable the interrupt associated with in/out bound msg *              return I2OSUCCESS if no error, otherwise return I2OMSGINVALID. * *              All previously enabled interrupts are preserved. * note: * Inbound message interrupt generated by PCI master and serviced by local processor * Outbound message interrupt generated by local processor and serviced by PCI master * * local processor needs to enable its inbound interrupts it wants to handle(LOCAL) * PCI master needs to enable the outbound interrupts of devices it wants to handle(REMOTE) ************************************************************************************/I2OSTATUS I2OMsgEnable ( LOCATION loc,        /*  REMOTE/LOCAL   */			 unsigned int base,   /* pcsrbar/eumbbar */			 unsigned char n )    /* b'1' - msg 0					       * b'10'- msg 1					       * b'11'- both					       */{    unsigned int reg, val;    if ( ( n & 0x3 ) == 0 )    {	/* neither msg 0, nor msg 1 */	return I2OMSGINVALID;    }    n = (~n) & 0x3;    /* LOCATION - REMOTE : enable outbound message of device, pcsrbar as base     *            LOCAL  : enable local inbound message, eumbbar as base     */    reg = ( loc == REMOTE ? I2O_OMIMR : I2O_IMIMR );    val = load_runtime_reg( base, reg );    val &= 0xfffffffc; /* masked out the msg interrupt bits */    val |= n;          /* LSB are the one we want */    store_runtime_reg( base, reg, val );    return I2OSUCCESS;}/********************************************************************************* * function: I2OMsgDisable * * description: Disable the interrupt associated with in/out bound msg *              Other previously enabled interrupts are preserved. *              return I2OSUCCESS if no error otherwise return I2OMSGINVALID * * note: *  local processor needs to disable its inbound interrupts it is not interested(LOCAL) *  PCI master needs to disable outbound interrupts of devices it is not interested(REMOTE) *********************************************************************************/I2OSTATUS I2OMsgDisable( LOCATION loc,      /*  REMOTE/LOCAL   */			 unsigned int base, /* pcsrbar/eumbbar */			 unsigned char n )  /* b'1' - msg 0					     * b'10'- msg 1					     * b'11'- both					     */{    unsigned int reg, val;    if ( ( n & 0x3 ) == 0 )    {	/* neither msg 0, nor msg 1 */	return I2OMSGINVALID;    }    /* LOCATION - REMOTE : disable outbound message interrupt of device, pcsrbar as base     *            LOCAL  : disable local inbound message interrupt, eumbbar as base     */    reg = ( loc == REMOTE ? I2O_OMIMR : I2O_IMIMR );    val = load_runtime_reg( base, reg );    val &= 0xfffffffc; /* masked out the msg interrupt bits */    val |= ( n & 0x3 );    store_runtime_reg( base, reg, val );    return I2OSUCCESS;}/************************************************************************** * function: I2OMsgGet * * description: Local processor reads the nth Msg register from its inbound msg, *              or a PCI Master reads nth outbound msg from device * *              return I2OSUCCESS if no error, otherwise return I2OMSGINVALID. * * note: * If it is not local, pcsrbar must be passed to the function. Otherwise eumbbar is passed. * If it is remote, outbound msg on the device is read; otherwise local inbound msg is read *************************************************************************/I2OSTATUS I2OMsgGet ( LOCATION loc,             /* REMOTE/LOCAL */			 unsigned int base,        /*pcsrbar/eumbbar */			 unsigned int n,           /* 0 or 1 */			 unsigned int *msg ){    if ( n >= I2O_NUM_MSG || msg == 0 )    {	return I2OMSGINVALID;    }    if ( loc == REMOTE )    {	/* read the outbound msg of the device, pcsrbar as base */	*msg = load_runtime_reg( base, I2O_OMR0+n*I2O_REG_OFFSET );    }    else    {	/* read the inbound msg sent by PCI master, eumbbar as base */	*msg = load_runtime_reg( base, I2O_IMR0+n*I2O_REG_OFFSET );    }    return I2OSUCCESS;}/*************************************************************** * function: I2OMsgPost * * description: Kahlua  writes to its nth outbound msg register *              PCI master writes to nth inbound msg register of device * *              return I2OSUCCESS if no error, otherwise return I2OMSGINVALID. * * note: * If it is not local, pcsrbar must be passed to the function. Otherwise eumbbar is passed. * * If it is remote, inbound msg on the device is written; otherwise local outbound msg is written ***************************************************************/I2OSTATUS I2OMsgPost( LOCATION loc,             /* REMOTE/LOCAL */		      unsigned int base,        /*pcsrbar/eumbbar */		      unsigned int n,           /* 0 or 1 */		      unsigned int msg ){    if ( n >= I2O_NUM_MSG )    {	return I2OMSGINVALID;    }    if ( loc == REMOTE )    {	/* write to the inbound msg register of the device, pcsrbar as base  */	store_runtime_reg( base, I2O_IMR0+n*I2O_REG_OFFSET, msg );    }    else    {	/* write to the outbound msg register for PCI master to read, eumbbar as base */	store_runtime_reg( base, I2O_OMR0+n*I2O_REG_OFFSET, msg );    }    return I2OSUCCESS;}/*********************************************************************** * function: I2ODBEnable * * description: Local processor enables it's inbound doorbell interrupt *              PCI master enables outbound doorbell interrupt of devices *              Other previously enabled interrupts are preserved. *              Return I2OSUCCESS if no error otherwise return I2ODBINVALID * * note: * In DoorBell interrupt is generated by PCI master and serviced by local processor * Out Doorbell interrupt is generated by local processor and serviced by PCI master * * Out Doorbell interrupt is generated by local processor and serviced by PCI master * PCI master needs to enable the outbound doorbell interrupts of device it wants to handle **********************************************************************/I2OSTATUS I2ODBEnable( LOCATION loc,        /*  REMOTE/LOCAL   */		  unsigned int base,   /* pcsrbar/eumbbar */		  unsigned int in_db ) /* when LOCAL, I2O_IN_DB, MC, I2O_IN_DB|MC */{    /* LOCATION - REMOTE : PCI master initializes outbound doorbell message of device     *            LOCAL  : Kahlua initializes its inbound doorbell message     */    unsigned int val;    if ( loc == LOCAL && ( in_db & 0x3 ) == 0 )    {	return I2ODBINVALID;    }    if ( loc == REMOTE )    {	/* pcsrbar is base */	val = load_runtime_reg( base, I2O_OMIMR );	val &= 0xfffffff7;	store_runtime_reg( base, I2O_OMIMR , val );    }    else    {	/* eumbbar is base */	val = load_runtime_reg( base, I2O_IMIMR);	in_db = ( (~in_db) & 0x3 ) << 3;	val = ( val & 0xffffffe7) | in_db;	store_runtime_reg( base,  I2O_IMIMR, val );    }    return I2OSUCCESS;}/********************************************************************************** * function: I2ODBDisable * * description: local processor disables its inbound DoorBell Interrupt *              PCI master disables outbound DoorBell interrupt of device *              Other previously enabled interrupts are preserved. *              return I2OSUCCESS if no error.Otherwise return I2ODBINVALID * * note: * local processor needs to disable its inbound doorbell interrupts it is not interested * * PCI master needs to disable outbound doorbell interrupts of device it is not interested ************************************************************************************/I2OSTATUS I2ODBDisable( LOCATION loc,          /*  REMOTE/LOCAL   */			unsigned int base,     /* pcsrbar/eumbbar */			unsigned int in_db )   /* when LOCAL, I2O_IN_DB, MC, I2O_IN_DB|MC */{    /* LOCATION - REMOTE : handle device's out bound message initialization     *            LOCAL  : handle local in bound message initialization     */    unsigned int val;    if ( loc == LOCAL && ( in_db & 0x3 ) == 0 )    {	    return I2ODBINVALID;    }    if ( loc == REMOTE )    {	/* pcsrbar is the base */	val = load_runtime_reg( base, I2O_OMIMR );	val |= 0x8;	store_runtime_reg( base, I2O_OMIMR, val );    }    else    {	    val = load_runtime_reg( base, I2O_IMIMR);	    in_db = ( in_db & 0x3 ) << 3;	    val |= in_db;	    store_runtime_reg( base, I2O_IMIMR, val );    }    return I2OSUCCESS;}/********************************************************************************** * function: I2ODBGet * * description: Local processor reads its in doorbell register, *              PCI master reads the outdoorbell register of device. *              After a doorbell register is read, the whole register will be cleared. *              Otherwise, HW keeps generating interrupt. * * note: * If it is not local, pcsrbar must be passed to the function. * Otherwise eumbbar is passed. * * If it is remote, out doorbell register on the device is read. * Otherwise local in doorbell is read * * If the register is not cleared by write to it, any remaining bit of b'1's * will cause interrupt pending. *********************************************************************************/unsigned int I2ODBGet( LOCATION loc,         /*  REMOTE/LOCAL   */		       unsigned int base)    /* pcsrbar/eumbbar */{    unsigned int msg, val;    if ( loc == REMOTE )    {	/* read outbound doorbell register of device, pcsrbar is the base */	val = load_runtime_reg( base, I2O_ODBR );	msg = val & 0xe0000000;	store_runtime_reg( base, I2O_ODBR, val ); /* clear the register */    }    else    {	/* read the inbound doorbell register, eumbbar is the base */	val = load_runtime_reg( base, I2O_IDBR );	store_runtime_reg( base, I2O_IDBR, val ); /* clear the register */	msg = val;    }    return msg;}/********************************************************************** * function: I2ODBPost * * description: local processor writes to a outbound doorbell register, *              PCI master writes to the inbound doorbell register of device * * note: * If it is not local, pcsrbar must be passed to the function. * Otherwise eumbbar is passed. * * If it is remote, in doorbell register on the device is written. * Otherwise local out doorbell is written *********************************************************************/void I2ODBPost( LOCATION loc,             /*  REMOTE/LOCAL   */		unsigned int base,        /* pcsrbar/eumbbar */		unsigned int msg )        /*   in   / out    */{    if ( loc == REMOTE )    {	/* write to inbound doorbell register of device, pcsrbar is the base */	store_runtime_reg( base, I2O_IDBR, msg );    }    else    {	/* write to local outbound doorbell register, eumbbar is the base */	store_runtime_reg( base, I2O_ODBR, msg & 0x1fffffff );    }}/******************************************************************** * function: I2OOutMsgStatGet * * description: PCI master reads device's outbound msg unit interrupt status. *              Reading an interrupt status register, *              the register will be cleared. * *              The value of the status register is AND with the outbound *              interrupt mask and result is returned. * * note: * pcsrbar must be passed to the function. ********************************************************************/I2OSTATUS I2OOutMsgStatGet( unsigned int pcsrbar, I2OOMSTAT *val ){    unsigned int stat;    unsigned int mask;    if ( val == 0 )    {	    return I2OINVALID;    }    /* read device's outbound status */    stat = load_runtime_reg( pcsrbar, I2O_OMISR );    mask = load_runtime_reg( pcsrbar, I2O_OMIMR );    store_runtime_reg( pcsrbar, I2O_OMISR, stat & 0xffffffd7);    stat &= mask;    val->rsvd0 = ( stat & 0xffffffc0 ) >> 6;    val->opqi  = ( stat & 0x00000020 ) >> 5;    val->rsvd1 = ( stat & 0x00000010 ) >> 4;    val->odi   = ( stat & 0x00000008 ) >> 3;    val->rsvd2 = ( stat & 0x00000004 ) >> 2;    val->om1i  = ( stat & 0x00000002 ) >> 1;    val->om0i  = ( stat & 0x00000001 );    return I2OSUCCESS;}/******************************************************************** * function: I2OInMsgStatGet * * description: Local processor reads its inbound msg unit interrupt status. *              Reading an interrupt status register, *              the register will be cleared. * *              The inbound msg interrupt status is AND with the inbound *              msg interrupt mask and result is returned. * * note: * eumbbar must be passed to the function. ********************************************************************/I2OSTATUS I2OInMsgStatGet(unsigned int eumbbar, I2OIMSTAT *val){    unsigned int stat;    unsigned int mask;    if ( val == 0 )    {	    return I2OINVALID;    }    /* read device's outbound status */    stat = load_runtime_reg( eumbbar, I2O_OMISR );    mask = load_runtime_reg( eumbbar, I2O_OMIMR );    store_runtime_reg( eumbbar, I2O_OMISR, stat & 0xffffffe7 );    stat &= mask;    val->rsvd0 = ( stat & 0xfffffe00 ) >> 9;    val->ofoi  = ( stat & 0x00000100 ) >> 8;    val->ipoi  = ( stat & 0x00000080 ) >> 7;    val->rsvd1 = ( stat & 0x00000040 ) >> 6;    val->ipqi  = ( stat & 0x00000020 ) >> 5;    val->mci   = ( stat & 0x00000010 ) >> 4;    val->idi   = ( stat & 0x00000008 ) >> 3;    val->rsvd2 = ( stat & 0x00000004 ) >> 2;    val->im1i  = ( stat & 0x00000002 ) >> 1;    val->im0i  = ( stat & 0x00000001 );    return I2OSUCCESS;}/*********************************************************** * function: I2OFIFOInit * * description: Configure the I2O FIFO, including QBAR, *              IFHPR/IFTPR, IPHPR/IPTPR, OFHPR/OFTPR, *              OPHPR/OPTPR, MUCR. * *              return I2OSUCCESS if no error, *              otherwise return I2OQUEINVALID * * note: It is NOT this driver's responsibility of initializing *       MFA blocks, i.e., FIFO queue itself. The MFA blocks *       must be initialized before I2O unit can be used. ***********************************************************/I2OSTATUS I2OFIFOInit( unsigned int eumbbar,		       QUEUE_SIZE   sz,      /* value of CQS of MUCR */		       unsigned int qba)     /* queue base address that must be aligned at 1M */{    if ( ( qba & 0xfffff ) != 0 )    {

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
蜜臀久久久99精品久久久久久| 色欧美乱欧美15图片| 国产高清久久久久| 成人精品国产福利| caoporn国产精品| 欧美色偷偷大香| 亚洲精品一区二区三区99| 国产米奇在线777精品观看| 国产电影一区二区三区| 在线中文字幕一区二区| 欧美电影免费观看高清完整版 | 日韩理论片一区二区| 亚洲自拍偷拍av| 麻豆久久久久久| 色综合欧美在线| 欧美精品黑人性xxxx| 久久久亚洲精品石原莉奈| 一区二区三区四区激情| 久久精品国产秦先生| 94色蜜桃网一区二区三区| 日韩欧美一区二区在线视频| 国产精品久久三区| 欧美aaaaaa午夜精品| av在线不卡电影| 日韩欧美电影在线| 亚洲人成人一区二区在线观看| 青青草国产精品97视觉盛宴 | 亚洲欧美日韩在线| 免费观看一级欧美片| 一本色道亚洲精品aⅴ| 精品不卡在线视频| 亚洲h动漫在线| 91网站在线观看视频| 精品国产sm最大网站免费看 | 在线播放/欧美激情| 国产精品人妖ts系列视频| 欧美a级一区二区| 91国产丝袜在线播放| 欧美激情中文字幕| 久久国产视频网| 欧美日韩成人综合在线一区二区| 国产精品美女视频| 久久99国产精品免费| 欧美日韩不卡在线| 亚洲麻豆国产自偷在线| 风间由美性色一区二区三区| 日韩一区二区视频在线观看| 亚洲制服丝袜一区| av高清不卡在线| 国产欧美日韩精品a在线观看| 老司机免费视频一区二区三区| 欧美视频在线一区| 伊人性伊人情综合网| 成人午夜碰碰视频| 久久久www免费人成精品| 老司机精品视频线观看86| 欧美午夜精品电影| 怡红院av一区二区三区| 99亚偷拍自图区亚洲| 国产欧美精品一区二区色综合朱莉| 日韩综合一区二区| 欧美日韩精品系列| 亚洲精品国产品国语在线app| 国产凹凸在线观看一区二区| 亚洲精品一区二区三区香蕉| 久久丁香综合五月国产三级网站| 欧美日韩视频在线一区二区| 亚洲最快最全在线视频| 91在线视频免费观看| 中文字幕一区二区三区四区| 成人免费高清视频| 中文字幕欧美日本乱码一线二线| 国产一区二区福利| 国产亚洲综合av| 国产成人av电影在线| 国产午夜精品一区二区三区嫩草| 国产美女主播视频一区| 久久精品一区蜜桃臀影院| 国产高清视频一区| 国产精品色哟哟网站| 白白色 亚洲乱淫| 亚洲男人电影天堂| 精品视频全国免费看| 日日摸夜夜添夜夜添亚洲女人| 欧美一级日韩免费不卡| 蜜桃久久av一区| 久久蜜桃av一区精品变态类天堂| 国产美女在线观看一区| 欧美激情中文字幕| 91在线播放网址| 亚洲一区二区在线免费看| 欧美日韩亚洲另类| 狠狠色狠狠色综合系列| 国产欧美日韩不卡免费| 日本精品免费观看高清观看| 亚洲成人免费看| 日韩精品一区在线观看| 国产v日产∨综合v精品视频| 亚洲人成伊人成综合网小说| 欧美在线播放高清精品| 日韩制服丝袜av| 国产亚洲污的网站| 91在线精品一区二区三区| 一区二区日韩电影| 日韩亚洲欧美一区| 波多野结衣一区二区三区| 亚洲综合精品久久| 欧美精品久久99久久在免费线| 国内精品视频666| 亚洲欧洲三级电影| 69p69国产精品| 国产69精品久久777的优势| 亚洲精品久久久久久国产精华液| 91精品国产全国免费观看 | 欧美国产日产图区| 欧美在线视频日韩| 国产一区二区精品久久99| 亚洲精品亚洲人成人网 | 国内精品国产成人国产三级粉色| 国产精品丝袜在线| 欧美日韩和欧美的一区二区| 国产在线一区二区| 亚洲欧美激情在线| 日韩欧美高清在线| 色婷婷综合久久久久中文一区二区 | 久久精品国产成人一区二区三区| 亚洲国产激情av| 91精品国产免费久久综合| 国产成人亚洲综合a∨猫咪| 亚洲一级电影视频| 国产午夜精品一区二区 | 极品少妇xxxx精品少妇| 亚洲男人天堂av网| 国产午夜精品在线观看| 欧美日韩国产一区| 成人一二三区视频| 久久成人免费网| 亚洲一区在线观看免费观看电影高清| 久久久久国产精品麻豆ai换脸 | 亚洲一卡二卡三卡四卡| 国产日韩欧美一区二区三区综合| 欧美精品精品一区| 色综合久久久久综合体桃花网| 激情偷乱视频一区二区三区| 亚洲影院久久精品| 国产精品久久久久久久久免费丝袜 | 欧美国产禁国产网站cc| 日韩午夜激情视频| 91福利精品第一导航| 国产成人激情av| 蜜桃av一区二区在线观看| 亚洲国产va精品久久久不卡综合 | 91小视频免费看| 国产成人精品www牛牛影视| 日av在线不卡| 亚洲自拍另类综合| **性色生活片久久毛片| 久久精品一区八戒影视| 欧美一区二区视频免费观看| 91久久久免费一区二区| www.在线欧美| 成人精品免费网站| 国产精品一区二区久激情瑜伽| 日韩不卡手机在线v区| 亚洲一二三四区| 亚洲欧美日韩系列| 1024国产精品| 最好看的中文字幕久久| 国产精品拍天天在线| 欧美激情一区在线| 久久―日本道色综合久久| 日韩欧美国产综合在线一区二区三区| 欧美日韩精品欧美日韩精品一综合| 一本大道av伊人久久综合| av中文字幕一区| 成人性生交大片免费看在线播放 | 中文字幕中文在线不卡住| 久久久久9999亚洲精品| 久久综合中文字幕| 精品国产亚洲一区二区三区在线观看| 欧美一卡在线观看| 日韩一级黄色片| 欧美一级黄色录像| 日韩一二在线观看| 精品久久久久av影院| 337p日本欧洲亚洲大胆精品| 日本不卡123| 美国av一区二区| 开心九九激情九九欧美日韩精美视频电影 | 精品一区二区三区免费播放| 日韩中文欧美在线| 久久国产精品一区二区| 国产自产v一区二区三区c| 国产久卡久卡久卡久卡视频精品| 老司机午夜精品99久久| 国产精品一区久久久久| 国产99久久久久久免费看农村| 成人av动漫在线| 91久久精品国产91性色tv| 欧美日韩精品一区二区三区|