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

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

?? pci.c

?? 根據添加了fs2410平臺的arch目錄
?? C
字號:
/*  * * This file is subject to the terms and conditions of the GNU General Public * License.  See the file "COPYING" in the main directory of this archive * for more details. * * SNI64 specific PCI support for SNI IO. * * Copyright (C) 1997, 1998, 2000 Colin Ngam */#include <linux/init.h>#include <linux/types.h>#include <linux/config.h>#include <linux/pci.h>#include <asm/sn/types.h>#include <asm/sn/sgi.h>#include <asm/sn/iobus.h>#include <asm/sn/iograph.h>#include <asm/param.h>#include <asm/sn/pio.h>#include <asm/sn/xtalk/xwidget.h>#include <asm/sn/sn_private.h>#include <asm/sn/addrs.h>#include <asm/sn/invent.h>#include <asm/sn/hcl.h>#include <asm/sn/hcl_util.h>#include <asm/sn/pci/pciio.h>#include <asm/sn/pci/pcibr.h>#include <asm/sn/pci/pcibr_private.h>#include <asm/sn/pci/bridge.h>#ifdef DEBUG_CONFIG#define DBG(x...) printk(x)#else#define DBG(x...)#endif#ifdef CONFIG_PCIextern devfs_handle_t pci_bus_to_vertex(unsigned char);extern devfs_handle_t devfn_to_vertex(unsigned char bus, unsigned char devfn);/* * snia64_read_config_byte - Read a byte from the config area of the device. */static int snia64_read_config_byte (struct pci_dev *dev,                                   int where, unsigned char *val){	unsigned long res = 0;	unsigned size = 1;	devfs_handle_t device_vertex;	if ( (dev == (struct pci_dev *)0) || (val == (unsigned char *)0) ) {		return PCIBIOS_DEVICE_NOT_FOUND;	}	device_vertex = devfn_to_vertex(dev->bus->number, dev->devfn);	if (!device_vertex) {		DBG("%s : nonexistent device: bus= 0x%x  slot= 0x%x  func= 0x%x\n", 		__FUNCTION__, dev->bus->number, PCI_SLOT(dev->devfn), PCI_FUNC(dev->devfn));		return(-1);	}	res = pciio_config_get(device_vertex, (unsigned) where, size);	*val = (unsigned char) res;	return PCIBIOS_SUCCESSFUL;}/* * snia64_read_config_word - Read 2 bytes from the config area of the device. */static int snia64_read_config_word (struct pci_dev *dev,                                   int where, unsigned short *val){	unsigned long res = 0;	unsigned size = 2; /* 2 bytes */	devfs_handle_t device_vertex;	if ( (dev == (struct pci_dev *)0) || (val == (unsigned short *)0) ) {		return PCIBIOS_DEVICE_NOT_FOUND;	}	device_vertex = devfn_to_vertex(dev->bus->number, dev->devfn);	if (!device_vertex) {		DBG("%s : nonexistent device: bus= 0x%x  slot= 0x%x  func= 0x%x\n", 		__FUNCTION__, dev->bus->number, PCI_SLOT(dev->devfn), PCI_FUNC(dev->devfn));		return(-1);	}	res = pciio_config_get(device_vertex, (unsigned) where, size);	*val = (unsigned short) res;	return PCIBIOS_SUCCESSFUL;}/* * snia64_read_config_dword - Read 4 bytes from the config area of the device. */static int snia64_read_config_dword (struct pci_dev *dev,                                    int where, unsigned int *val){	unsigned long res = 0;	unsigned size = 4; /* 4 bytes */	devfs_handle_t device_vertex;	if (where & 3) {		return PCIBIOS_BAD_REGISTER_NUMBER;	}	if ( (dev == (struct pci_dev *)0) || (val == (unsigned int *)0) ) {		return PCIBIOS_DEVICE_NOT_FOUND;	}	device_vertex = devfn_to_vertex(dev->bus->number, dev->devfn);	if (!device_vertex) {		DBG("%s : nonexistent device: bus= 0x%x  slot= 0x%x  func= 0x%x\n", 		__FUNCTION__, dev->bus->number, PCI_SLOT(dev->devfn), PCI_FUNC(dev->devfn));		return(-1);	}	res = pciio_config_get(device_vertex, (unsigned) where, size);	*val = (unsigned int) res;	return PCIBIOS_SUCCESSFUL;}/* * snia64_write_config_byte - Writes 1 byte to the config area of the device. */static int snia64_write_config_byte (struct pci_dev *dev,                                    int where, unsigned char val){	devfs_handle_t device_vertex;	if ( dev == (struct pci_dev *)0 ) {		return PCIBIOS_DEVICE_NOT_FOUND;	}	/* 	 * if it's an IOC3 then we bail out, we special	 * case them with pci_fixup_ioc3	 */	if (dev->vendor == PCI_VENDOR_ID_SGI && 	    dev->device == PCI_DEVICE_ID_SGI_IOC3 )		return PCIBIOS_SUCCESSFUL;	device_vertex = devfn_to_vertex(dev->bus->number, dev->devfn);	if (!device_vertex) {		DBG("%s : nonexistent device: bus= 0x%x  slot= 0x%x  func= 0x%x\n", 		__FUNCTION__, dev->bus->number, PCI_SLOT(dev->devfn), PCI_FUNC(dev->devfn));		return(-1);	}	pciio_config_set( device_vertex, (unsigned)where, 1, (uint64_t) val);	return PCIBIOS_SUCCESSFUL;}/* * snia64_write_config_word - Writes 2 bytes to the config area of the device. */static int snia64_write_config_word (struct pci_dev *dev,                                    int where, unsigned short val){	devfs_handle_t device_vertex = NULL;	if (where & 1) {		return PCIBIOS_BAD_REGISTER_NUMBER;	}	if ( dev == (struct pci_dev *)0 ) {		return PCIBIOS_DEVICE_NOT_FOUND;	}	/* 	 * if it's an IOC3 then we bail out, we special	 * case them with pci_fixup_ioc3	 */	if (dev->vendor == PCI_VENDOR_ID_SGI && 	    dev->device == PCI_DEVICE_ID_SGI_IOC3)		return PCIBIOS_SUCCESSFUL;	device_vertex = devfn_to_vertex(dev->bus->number, dev->devfn);	if (!device_vertex) {		DBG("%s : nonexistent device: bus= 0x%x  slot= 0x%x  func= 0x%x\n", 		__FUNCTION__, dev->bus->number, PCI_SLOT(dev->devfn), PCI_FUNC(dev->devfn));		return(-1);	}	pciio_config_set( device_vertex, (unsigned)where, 2, (uint64_t) val);	return PCIBIOS_SUCCESSFUL;}/* * snia64_write_config_dword - Writes 4 bytes to the config area of the device. */static int snia64_write_config_dword (struct pci_dev *dev,                                     int where, unsigned int val){	devfs_handle_t device_vertex;	if (where & 3) {		return PCIBIOS_BAD_REGISTER_NUMBER;	}	if ( dev == (struct pci_dev *)0 ) {		return PCIBIOS_DEVICE_NOT_FOUND;	}	/* 	 * if it's an IOC3 then we bail out, we special	 * case them with pci_fixup_ioc3	 */	if (dev->vendor == PCI_VENDOR_ID_SGI && 	    dev->device == PCI_DEVICE_ID_SGI_IOC3)		return PCIBIOS_SUCCESSFUL;	device_vertex = devfn_to_vertex(dev->bus->number, dev->devfn);	if (!device_vertex) {		DBG("%s : nonexistent device: bus= 0x%x  slot= 0x%x  func= 0x%x\n", 		__FUNCTION__, dev->bus->number, PCI_SLOT(dev->devfn), PCI_FUNC(dev->devfn));		return(-1);	}	pciio_config_set( device_vertex, (unsigned)where, 4, (uint64_t) val);	return PCIBIOS_SUCCESSFUL;}static struct pci_ops snia64_pci_ops = {	snia64_read_config_byte,	snia64_read_config_word,	snia64_read_config_dword,	snia64_write_config_byte,	snia64_write_config_word,	snia64_write_config_dword};/* * snia64_pci_find_bios - SNIA64 pci_find_bios() platform specific code. */void __initsn1_pci_find_bios(void){	extern struct pci_ops pci_conf;	/*	 * Go initialize our IO Infrastructure ..	 */	extern void sgi_master_io_infr_init(void);	sgi_master_io_infr_init();#ifdef BRINGUP	if ( IS_RUNNING_ON_SIMULATOR() )		return;#endif	/* sn1_io_infrastructure_init(); */	pci_conf = snia64_pci_ops;}voidpci_fixup_ioc3(struct pci_dev *d){        int 		i;	unsigned int 	size;	devfs_handle_t	bridge_vhdl = pci_bus_to_vertex(d->bus->number);        /* IOC3 only decodes 0x20 bytes of the config space, reading	 * beyond that is relatively benign but writing beyond that	 * (especially the base address registers) will shut down the	 * pci bus...so avoid doing so.	 * NOTE: this means we can't program the intr_pin into the device,	 *       currently we hack this with special code in 	 *	 sgi_pci_intr_support()	 */        DBG("pci_fixup_ioc3: Fixing base addresses for ioc3 device %s\n", d->slot_name);	/* I happen to know from the spec that the ioc3 needs only 0xfffff 	 * The standard pci trick of writing ~0 to the baddr and seeing	 * what comes back doesn't work with the ioc3	 */	size = 0xfffff;	d->resource[0].end = (unsigned long) d->resource[0].start + (unsigned long) size;	/*	 * Zero out the resource structure .. because we did not go through 	 * the normal PCI Infrastructure Init, garbbage are left in these 	 * fileds.	 */        for (i = 1; i <= PCI_ROM_RESOURCE; i++) {                d->resource[i].start = 0UL;                d->resource[i].end = 0UL;                d->resource[i].flags = 0UL;        }	/*	 * Hardcode Device 4 register(IOC3 is in Slot 4) to set the 	 * DEV_DIRECT bit.  This will not work if IOC3 is not on Slot 	 * 4.	 */	DBG("pci_fixup_ioc3: FIXME .. need to take NASID into account when setting IOC3 devreg 0x%x\n", *(volatile u32 *)0xc0000a000f000220); 	*(volatile u32 *)0xc0000a000f000220 |= 0x90000;         d->subsystem_vendor = 0;        d->subsystem_device = 0;}#endif /* CONFIG_PCI */

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
七七婷婷婷婷精品国产| 亚洲福利一区二区| 欧美一区二区三区色| 色天天综合久久久久综合片| 成人性生交大片免费看视频在线 | 欧美一区2区视频在线观看| 欧美综合视频在线观看| 色婷婷av一区二区三区软件| 91亚洲男人天堂| 欧美亚洲国产bt| 欧美日韩国产小视频| 欧美肥大bbwbbw高潮| 欧美精品xxxxbbbb| 日韩三级精品电影久久久| 欧美v日韩v国产v| 久久久久久久性| 国产精品网站在线观看| 亚洲三级免费观看| 亚洲男同性视频| 亚洲午夜电影网| 日韩电影一二三区| 国产美女精品在线| 成人亚洲一区二区一| 91丨九色丨国产丨porny| 欧美色综合影院| 精品国产乱码久久久久久老虎| 亚洲精品一区二区三区在线观看| 中文字幕欧美三区| 亚洲一区二区三区四区在线免费观看 | 蜜臀av一级做a爰片久久| 精品在线播放午夜| 成人高清免费观看| 欧美日韩二区三区| 国产午夜精品久久久久久久 | 成人av免费在线| 欧美日韩视频在线观看一区二区三区| 欧美日本一区二区| 精品国产网站在线观看| 亚洲视频一区二区免费在线观看| 偷窥少妇高潮呻吟av久久免费| 看电影不卡的网站| 色琪琪一区二区三区亚洲区| 欧美一级免费大片| 国产精品电影院| 久久精品国产第一区二区三区| www.久久精品| 精品免费日韩av| 亚洲在线一区二区三区| 久久se这里有精品| 在线亚洲一区二区| 国产亚洲欧美日韩俺去了| 日韩高清不卡一区| 色偷偷成人一区二区三区91| 国产亚洲综合色| 天天操天天综合网| 91小视频在线免费看| 欧美大度的电影原声| 一区二区三区四区高清精品免费观看| 美国十次了思思久久精品导航| 在线亚洲免费视频| 亚洲乱码国产乱码精品精小说 | 中文字幕精品一区| 男女男精品视频网| 欧美日韩国产美| 一区二区三区中文字幕在线观看| 国产精品亚洲а∨天堂免在线| 日韩你懂的在线观看| 五月综合激情日本mⅴ| 91蝌蚪国产九色| 亚洲欧美日韩中文播放| jvid福利写真一区二区三区| 国产午夜精品一区二区三区视频 | 天天综合日日夜夜精品| 欧美优质美女网站| 亚洲制服欧美中文字幕中文字幕| 91伊人久久大香线蕉| 亚洲欧美偷拍三级| 91蜜桃婷婷狠狠久久综合9色| 亚洲欧美中日韩| 色美美综合视频| 亚洲一区二区三区三| 欧美日韩视频在线观看一区二区三区 | 国产成人av资源| 久久精品人人做人人综合| 国产综合色在线视频区| 国产目拍亚洲精品99久久精品| 国产麻豆91精品| 欧美激情一区二区三区全黄| 成人精品鲁一区一区二区| 成人免费小视频| 91福利精品视频| 日韩精品一二三| 精品少妇一区二区三区视频免付费 | 91在线porny国产在线看| 日韩毛片视频在线看| 欧美午夜在线一二页| 日韩在线a电影| 久久久亚洲高清| 成人精品高清在线| 日韩中文字幕不卡| 久久久国产精华| 欧美性受xxxx黑人xyx性爽| 三级精品在线观看| 欧美极品美女视频| 欧美午夜片在线看| 国内久久精品视频| 亚洲欧洲日产国码二区| 91精品国产色综合久久不卡蜜臀| 国产伦理精品不卡| 亚洲国产美女搞黄色| 精品欧美一区二区在线观看| eeuss影院一区二区三区| 亚洲va欧美va人人爽| 久久久久久久网| 欧美日韩不卡在线| 不卡的av中国片| 精品一区中文字幕| 亚洲一区二区三区免费视频| 久久久无码精品亚洲日韩按摩| 91黄色激情网站| 国产精品一线二线三线| 亚洲宅男天堂在线观看无病毒| 国产色爱av资源综合区| 欧美喷水一区二区| jlzzjlzz欧美大全| 国产精品77777| 欧美aaaaaa午夜精品| 一区二区三区在线视频观看58 | 99re视频精品| 国产ts人妖一区二区| 日韩不卡免费视频| 亚洲精品乱码久久久久久| 国产视频一区二区在线| 6080亚洲精品一区二区| 色婷婷综合久久久| 懂色av一区二区三区免费观看| 美国十次了思思久久精品导航| 尤物av一区二区| 自拍视频在线观看一区二区| 精品国产91亚洲一区二区三区婷婷| 欧美视频自拍偷拍| 日本道色综合久久| 波多野结衣在线aⅴ中文字幕不卡| 国内成人自拍视频| 精品一区二区三区蜜桃| 蜜臀久久99精品久久久久久9| 亚洲超碰精品一区二区| 亚洲成年人网站在线观看| 亚洲综合成人网| 亚洲美女少妇撒尿| 亚洲另类在线一区| 亚洲猫色日本管| 亚洲黄网站在线观看| 亚洲一级在线观看| 亚洲一区二区三区四区中文字幕| 一区二区三区精品| 亚洲午夜久久久久久久久电影网| 一区二区三区四区蜜桃| 亚洲欧美aⅴ...| 亚洲一级电影视频| 肉丝袜脚交视频一区二区| 奇米色777欧美一区二区| 美国一区二区三区在线播放| 麻豆成人综合网| 国产久卡久卡久卡久卡视频精品| 国产精品亚洲专一区二区三区| 国产麻豆成人传媒免费观看| av亚洲精华国产精华| 色综合天天综合给合国产| 欧美性生活影院| 91精品国产综合久久小美女| 精品入口麻豆88视频| 欧美sm极限捆绑bd| 综合欧美一区二区三区| 一区二区三区91| 九九九精品视频| 不卡一区二区三区四区| 欧美午夜寂寞影院| 久久色成人在线| 国产精品国产三级国产| 青青青伊人色综合久久| 国产一区二区三区精品视频| 色www精品视频在线观看| 欧美一区二区三区爱爱| 国产亚洲制服色| 亚洲一区二区三区四区在线免费观看 | 亚洲色图欧美在线| 日本中文在线一区| 成熟亚洲日本毛茸茸凸凹| 91精彩视频在线| 2019国产精品| 一区二区三区四区激情| 国产一区二区视频在线| 欧美性猛片aaaaaaa做受| 欧美不卡一二三| 亚洲国产日韩a在线播放性色| 国产精品亚洲一区二区三区在线| 欧美日韩成人综合在线一区二区| 日本一区二区三区国色天香| 婷婷综合久久一区二区三区|