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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? sysscsi.c

?? mtx604在vxworks下的bsp源代碼
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* sysScsi.c - Motorola MVME2600 series SCSI-2 initialization for sysLib.c *//* Copyright 1984-2000 Wind River Systems, Inc. *//* Copyright 1996,1997,1998,1999 Motorola, Inc., All Rights Reserved */#include "copyright_wrs.h"/*modification history--------------------01a,09nov00,dat  new version just for MTX, (from mcp750, ver 01p)*//* DescriptionThis file contains the sysScsiInit() and related routines necessary forinitializing the SCSI subsystem. It also contains BSP-specific SCSI I/O routines required by the ncr810 driver.The constant PCI2DRAM_BASE_ADRS must be defined in the BSP.*/#ifdef	INCLUDE_SCSI/* includes */#include "drv/scsi/ncr810.h"#include "tapeFsLib.h"/* external declarations */extern int   ncr810PciMemOffset;extern int   ncr810DelayCount;extern ULONG NCR810_INSTRUCTIONS;extern ULONG ncr810Wait[];extern BOOL  scsiDebug;extern void  eieioExecute();extern void  vxEieio ();extern UCHAR sysInByte (ULONG);extern void  sysOutByte (ULONG,UCHAR);#ifdef  INCLUDE_SECONDARY_SCSI/* global declarations */SCSI_CTRL * pSysScsiCtrl2;#endif  /* INCLUDE_SECONDARY_SCSI *//* function declarations */LOCAL void swapScript (UINT32 * start, UINT32 * end);struct ncr810Params {	int devType;  		/* 0 for dynamic detection */	int clockCode;		/* clock speed */	NCR810_HW_REGS hwRegs;  /* register bits */    };    /* * This structure contains the information to setup two  * NCR 8xx controllers.  Each device is a separate entry. * The code below will scan for NCR SCSI controllers and * the first one found will be device 0, and use data from * element 0 of this table.  The second device found will * use data from element 1 of this table. */struct ncr810Params scsiCtlrParams[] = {	{	/* Data for device #0 */#ifdef SCSI_WIDE_ENABLE	0,			/* allow any wide/narrow connection */#else	NCR810_DEVICE_ID,	/* Force a narrow-only connection */#endif	NCR810_40MHZ,	SYS_REG_SIOP_HW_REGS	}#ifdef INCLUDE_SECONDARY_SCSI	/* Data for Device #1 */	,{	0, 			/* Device 1 can be any narrow or wide */	NCR810_40MHZ,	SYS_REG_SIOP_HW_REGS	/* uses same params as device 0 ? */	}#endif    };#define NCR_VENDOR_ID	0x1000		/* NCR Vendor ID */#define SCSI_CTLR_CLASS_ID 0x10000	/* SCSI Ctlr Class ID *//********************************************************************************* sysScsiInit - initialize an on-board SCSI port** This routine creates and initializes an NCR 53C8\f2xx\f1 SCSI I/O* processor (SIOP) structure(s), enabling use of the on-board SCSI port.  It* connects the proper interrupt service routine to the desired vector, and* enables the interrupt at the desired level.** RETURNS: OK, or ERROR if the SIOP structure cannot be created, the* controller cannot be initialized, valid values cannot be set up in the* SIOP registers, or the interrupt service routine cannot be connected.*/ STATUS sysScsiInit ()    {    int			pciBusNo;    int			pciDevNo;    int			pciFuncNo;    UINT16		devType;    static BOOL		firstTime = TRUE;    UINT32 		iobaseCsr;    char 		irq;    NCR_810_SCSI_CTRL *	pScsiCtrl;    int			instance; /* ncr device instance */    int 		ix;	/* index for find class */     /* Set CPU <-> PCI address offset */    ncr810PciMemOffset = PCI2DRAM_BASE_ADRS;    /*      * Since the PCI bus is little endian, and the PPC CPU's are big endian,     * the ncr8xx scripts need to be byte swapped in memory. However, they     * should only be swapped the first time that sysScsiInit() is invoked.     */    if (firstTime)	{        swapScript ((UINT32 *) &ncr810Wait, (UINT32 *) 		    ((UINT32) &ncr810Wait + 		     (UINT32)(NCR810_INSTRUCTIONS * 8)));	firstTime = FALSE;	}    ncr810DelayCount = (sysGetBusSpd () * NCR810_DELAY_MULT);    instance = ix = 0;    while (pciFindClass (SCSI_CTLR_CLASS_ID, ix++, &pciBusNo, &pciDevNo,	    &pciFuncNo) == OK)	{	USHORT vendor;	USHORT deviceId;	if (pciConfigInWord (pciBusNo, pciDevNo, pciFuncNo,				PCI_CFG_VENDOR_ID, &vendor) == OK	 && vendor == NCR_VENDOR_ID)	    {	    pciConfigInWord (pciBusNo, pciDevNo, pciFuncNo,				PCI_CFG_DEVICE_ID, &deviceId);	    SCSI_DEBUG_MSG ("Found SCSI Controller - Ven/Dev ID = 0x%x 0x%x\n",				vendor,deviceId,0,0,0,0);	    /* use forced devType, or read from PCI header */	    devType = scsiCtlrParams[instance].devType;	    if (devType == 0)		devType = deviceId;	    /* read the configuration parameters */	    pciConfigInLong(pciBusNo, pciDevNo, pciFuncNo,				PCI_CFG_BASE_ADDRESS_0, &iobaseCsr);    	    pciConfigInByte(pciBusNo, pciDevNo, pciFuncNo,				PCI_CFG_DEV_INT_LINE, &irq);	    /* Translate bus physical to virtual address */	    iobaseCsr  &= PCI_IOBASE_MASK;	    iobaseCsr  |= ISA_MSTR_IO_LOCAL;	    /* Create the SCSI controller */	    if ((pScsiCtrl = ncr810CtrlCreate 				      (				      (UINT8 *) iobaseCsr,				      scsiCtlrParams[instance].clockCode,				      devType      				      )) == NULL)		{		logMsg ("sysScsiInit: error returned by ncr810CtrlCreate\n",			0,0,0,0,0,0);		return (ERROR);		}	    if (ncr810SetHwRegister (pScsiCtrl,			    &(scsiCtlrParams[instance].hwRegs)) == ERROR)		{		logMsg ("sysScsiInit: error returned by ncr810SetHwRegister\n",			0,0,0,0,0,0);		return (ERROR);		}	    /* connect the SCSI controller's interrupt service routine */	 	    if (intConnect (INUM_TO_IVEC ((int)irq),			    ncr810Intr, (int) pScsiCtrl) == ERROR)		{		logMsg ("sysScsiInit: error returned by intConnect\n",			0,0,0,0,0,0);		return (ERROR);		}	 	    /* Enable SCSI interrupts */	    intEnable (irq);	    /* activate the controller */	    if (ncr810CtrlInit (pScsiCtrl, SCSI_DEF_CTRL_BUS_ID) == ERROR)		{		logMsg ("sysScsiInit: error returned by ncr810CtrlInit\n",			0,0,0,0,0,0);		return (ERROR);		}#if (USER_D_CACHE_MODE &  CACHE_SNOOP_ENABLE)	    scsiCacheSnoopEnable ((SCSI_CTRL *) pScsiCtrl);#else 	    scsiCacheSnoopDisable ((SCSI_CTRL *) pScsiCtrl);#endif	    /* init the global pointer if this is the first */	    if (pSysScsiCtrl == NULL)		pSysScsiCtrl = (SCSI_CTRL *)pScsiCtrl;	    /* Stop searching if we have no more data */	    if (++instance >= NELEMENTS(scsiCtlrParams))		break;	    }	}    /* Include tape support if configured in config.h */ #ifdef  INCLUDE_TAPEFS    tapeFsInit ();                     /* initialise tapeFs */#endif  /* INCLUDE_TAPEFS */     return (OK);    }/********************************************************************************* swapScript - byte swaps the 32 bit NCR8XX scripts** This routine byte swaps 4 byte (32 bit) long scripts instructions due to* the fact that the PPC processor is big endian and the PCI SCSI device is* little endian. ** The two parameters supplied <start> and <end> denote the start of scripts* in memory and the end of the scripts in memory. Note that both these* values are assumed to be on 4 byte boundaries. It is further assumed that* the instructions are located in a writable area of memory.** RETURNS: N/A*/LOCAL void swapScript     (    UINT32 * start,    UINT32 * end    )    {    int size;    UINT32 i;    UINT32 val;    /* determine the size (length) of the scripts */    size = (int) end - (int) start;    if (size % 4)	printf ("Incorrect length (start - end) mod 4 != 0 size: %d\n", size);    /* swap each 4 byte word in memory */    for (i=0; i < (size/4); i ++)	{	val = BYTE_SWAP_32_BIT ( (UINT32) *((UINT32 *) (start + i)) );        *((UINT32 *) start + i) = val;	}    }/********************************************************************************* inOrderExecute - enforce in-order execution of PowerPC accesses** This routine enforces in-order execution of register accesses to the SCSI* I/O processor (SIOP).  It is invoked by the SCSI-2 driver, and is a* wrapper to a PowerPC assembler instruction.** RETURNS: N/A.*/void inOrderExecute ()    {    vxEieio ();  /* defined in vxALib.s */    }/* Data for example code in sysScsiConfig, modify as needed */SCSI_PHYS_DEV *	pSpd20;SCSI_PHYS_DEV *	pSpd31;         /* SCSI_PHYS_DEV ptrs (suffix == ID, LUN) */SCSI_PHYS_DEV *	pSpd40;BLK_DEV *	pSbd0;BLK_DEV *	pSbd1;BLK_DEV *	pSbd2;          /* SCSI_BLK_DEV ptrs for Winchester */BLK_DEV *	pSbdFloppy;     /* ptr to SCSI floppy block device */

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩精品专区在线影院重磅| 日本高清成人免费播放| 亚洲综合免费观看高清完整版在线 | 在线不卡的av| 一本色道久久综合精品竹菊| 北条麻妃一区二区三区| 不卡高清视频专区| 91丨九色丨蝌蚪丨老版| 91免费国产在线| 欧美优质美女网站| 欧美日韩国产在线播放网站| 欧美日本在线观看| 日韩三级.com| 国产精品日韩精品欧美在线| 久久精品人人做| 国产精品国产三级国产普通话三级 | 国产一区二区三区免费播放 | 成人av网站免费观看| 成人天堂资源www在线| 99国产精品久久久久久久久久 | 亚洲精品成人天堂一二三| 亚洲欧美色综合| 午夜精品久久一牛影视| 婷婷丁香久久五月婷婷| 精品日韩在线观看| 日韩你懂的电影在线观看| 欧美精品一区二区三区在线播放 | 理论片日本一区| 成人精品免费网站| 欧美色中文字幕| 精品国产乱码久久久久久久| 中文字幕的久久| 日韩精品成人一区二区三区| 国产乱人伦精品一区二区在线观看| 高清在线成人网| 欧美日韩国产一区| 中文字幕不卡在线播放| 日本欧美久久久久免费播放网| 国产老妇另类xxxxx| 91国在线观看| 国产精品污网站| 日韩1区2区日韩1区2区| 99久久国产综合精品色伊| 欧美一区二区久久| 亚洲码国产岛国毛片在线| 激情综合网最新| 欧美日韩久久久| **性色生活片久久毛片| 国产一二三精品| 91精品国模一区二区三区| 中文字幕第一页久久| 精油按摩中文字幕久久| 91极品美女在线| 一区二区中文视频| 狠狠色丁香九九婷婷综合五月| 欧美中文字幕亚洲一区二区va在线 | 久久久精品蜜桃| 亚洲国产一区二区三区青草影视| 丰满白嫩尤物一区二区| 日韩欧美一区二区视频| 丝袜美腿亚洲综合| 91黄视频在线观看| 1区2区3区欧美| av在线播放成人| 中文在线免费一区三区高中清不卡| 蜜臀av一区二区| 日韩亚洲欧美一区| 日韩高清一区在线| 91精品国产入口在线| 婷婷六月综合亚洲| 欧美乱妇23p| 五月天亚洲婷婷| 欧美久久久久久久久| 亚洲成a人v欧美综合天堂| 欧美日韩激情在线| 午夜免费久久看| 日韩精品一区二| 精品在线一区二区| 久久精品人人做人人综合| 国产成人综合在线观看| 国产日韩精品久久久| 成人国产精品免费网站| 中文字幕一区二区三区在线不卡| av不卡在线播放| 亚洲精品v日韩精品| 欧美天堂亚洲电影院在线播放| 亚洲一区在线观看视频| 欧美日韩亚洲综合在线 | 久久久久久影视| 国内外成人在线| 欧美国产精品一区| 在线精品视频免费观看| 日本中文在线一区| 精品91自产拍在线观看一区| 国产高清视频一区| 亚洲人成网站色在线观看| 欧美特级限制片免费在线观看| 亚洲高清免费观看| 日韩欧美激情在线| caoporn国产精品| 五月天中文字幕一区二区| 久久一区二区视频| 日本高清不卡视频| 久久精品国产久精国产| 亚洲国产精品二十页| 在线观看亚洲精品视频| 国产自产视频一区二区三区| 亚洲欧美韩国综合色| 日韩一区二区三区电影在线观看 | 91高清在线观看| 麻豆中文一区二区| 亚洲日本在线a| 日韩一本二本av| 91亚洲男人天堂| 麻豆91在线播放免费| 亚洲人吸女人奶水| 精品91自产拍在线观看一区| 色呦呦网站一区| 国产精品99精品久久免费| 亚洲综合清纯丝袜自拍| 国产精品丝袜在线| 日韩亚洲欧美综合| 欧美日韩一区不卡| 成人av免费观看| 精品一区二区三区免费观看 | 中文字幕不卡在线| 精品女同一区二区| 欧美精品日日鲁夜夜添| 一本大道av伊人久久综合| 国产一区二区网址| 免费国产亚洲视频| 亚洲动漫第一页| 亚洲欧美二区三区| 亚洲三级久久久| 一区二区三区精品视频| 欧美精品一区二区三| 911国产精品| 4hu四虎永久在线影院成人| 日本韩国一区二区三区| 波多野结衣精品在线| 国产在线精品国自产拍免费| 亚洲成av人片| 亚洲va国产天堂va久久en| 亚洲美女在线国产| 亚洲视频资源在线| 亚洲少妇屁股交4| 亚洲少妇30p| 亚洲久草在线视频| 一区二区三区 在线观看视频 | 欧美视频你懂的| 色狠狠桃花综合| 在线观看91视频| 欧美欧美欧美欧美首页| 欧美三片在线视频观看| 欧美日韩免费观看一区三区| 欧美撒尿777hd撒尿| 色欲综合视频天天天| 欧美在线色视频| 欧美精品色综合| 欧美精品一区二区三区四区| 久久精品夜夜夜夜久久| 国产亚洲精品aa午夜观看| 中文字幕在线不卡一区二区三区 | 91丝袜呻吟高潮美腿白嫩在线观看| 国产成人av电影| av电影在线观看一区| 91小视频免费观看| 在线看一区二区| 日韩欧美高清一区| 国产欧美日韩综合| 一区二区三区av电影| 日本欧美在线观看| 国产成人在线网站| 91无套直看片红桃| 91麻豆精品国产91久久久使用方法 | 久久午夜色播影院免费高清| 久久久亚洲综合| 亚洲精品水蜜桃| 强制捆绑调教一区二区| 成人精品高清在线| 欧美吻胸吃奶大尺度电影| 日韩一卡二卡三卡四卡| 国产精品天美传媒| 天使萌一区二区三区免费观看| 蜜桃av一区二区三区电影| 丰满亚洲少妇av| 欧美精品一级二级| 亚洲欧洲国产专区| 日本美女一区二区| 91色视频在线| 26uuu国产日韩综合| 亚洲欧美另类久久久精品2019| 日韩成人一区二区三区在线观看| 国产一区二区三区四区五区美女| 91麻豆成人久久精品二区三区| 日韩免费看网站| 一区二区三区四区在线免费观看 | 欧美日韩中字一区| 国产精品毛片久久久久久久| 香蕉久久一区二区不卡无毒影院 |