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

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

?? i2o_pci.c

?? MIZI Research, Inc.發(fā)布的嵌入式Linux內(nèi)核源碼
?? C
字號(hào):
/* *	Find I2O capable controllers on the PCI bus, and register/install *	them with the I2O layer * *	(C) Copyright 1999   Red Hat Software *	 *	Written by Alan Cox, Building Number Three Ltd * 	Modified by Deepak Saxena <deepak@plexity.net> * 	Modified by Boji T Kannanthanam <boji.t.kannanthanam@intel.com> * *	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. * *	TODO: *		Support polled I2O PCI controllers.  */#include <linux/config.h>#include <linux/module.h>#include <linux/kernel.h>#include <linux/pci.h>#include <linux/i2o.h>#include <linux/errno.h>#include <linux/init.h>#include <linux/slab.h>#include <asm/io.h>#ifdef CONFIG_MTRR#include <asm/mtrr.h>#endif // CONFIG_MTRR#ifdef MODULE/* * Core function table * See <include/linux/i2o.h> for an explanation */static struct i2o_core_func_table *core;/* Core attach function */extern int i2o_pci_core_attach(struct i2o_core_func_table *);extern void i2o_pci_core_detach(void);#endif /* MODULE *//* *	Free bus specific resources */static void i2o_pci_dispose(struct i2o_controller *c){	I2O_IRQ_WRITE32(c,0xFFFFFFFF);	if(c->bus.pci.irq > 0)		free_irq(c->bus.pci.irq, c);	iounmap(((u8 *)c->post_port)-0x40);#ifdef CONFIG_MTRR	if(c->bus.pci.mtrr_reg0 > 0)		mtrr_del(c->bus.pci.mtrr_reg0, 0, 0);	if(c->bus.pci.mtrr_reg1 > 0)		mtrr_del(c->bus.pci.mtrr_reg1, 0, 0);#endif}/* *	No real bus specific handling yet (note that later we will *	need to 'steal' PCI devices on i960 mainboards) */ static int i2o_pci_bind(struct i2o_controller *c, struct i2o_device *dev){	MOD_INC_USE_COUNT;	return 0;}static int i2o_pci_unbind(struct i2o_controller *c, struct i2o_device *dev){	MOD_DEC_USE_COUNT;	return 0;}/* * Bus specific enable/disable functions */static void i2o_pci_enable(struct i2o_controller *c){	I2O_IRQ_WRITE32(c, 0);	c->enabled = 1;}static void i2o_pci_disable(struct i2o_controller *c){	I2O_IRQ_WRITE32(c, 0xFFFFFFFF);	c->enabled = 0;}/* *	Bus specific interrupt handler */ static void i2o_pci_interrupt(int irq, void *dev_id, struct pt_regs *r){	struct i2o_controller *c = dev_id;#ifdef MODULE	core->run_queue(c);#else	i2o_run_queue(c);#endif /* MODULE */}	/* *	Install a PCI (or in theory AGP) i2o controller * * TODO: Add support for polled controllers */int __init i2o_pci_install(struct pci_dev *dev){	struct i2o_controller *c=kmalloc(sizeof(struct i2o_controller),						GFP_KERNEL);	u8 *mem;	u32 memptr = 0;	u32 size;		int i;	if(c==NULL)	{		printk(KERN_ERR "i2o: Insufficient memory to add controller.\n");		return -ENOMEM;	}	memset(c, 0, sizeof(*c));	for(i=0; i<6; i++)	{		/* Skip I/O spaces */		if(!(pci_resource_flags(dev, i) & IORESOURCE_IO))		{			memptr = pci_resource_start(dev, i);			break;		}	}		if(i==6)	{		printk(KERN_ERR "i2o: I2O controller has no memory regions defined.\n");		kfree(c);		return -EINVAL;	}		size = dev->resource[i].end-dev->resource[i].start+1;		/* Map the I2O controller */		printk(KERN_INFO "i2o: PCI I2O controller at 0x%08X size=%d\n", memptr, size);	mem = ioremap(memptr, size);	if(mem==NULL)	{		printk(KERN_ERR "i2o: Unable to map controller.\n");		kfree(c);		return -EINVAL;	}	c->bus.pci.irq = -1;	c->bus.pci.queue_buggy = 0;	c->bus.pci.dpt = 0;	c->bus.pci.short_req = 0;	c->pdev = dev;	c->irq_mask = (u32 *)(mem+0x34);	c->post_port = (u32 *)(mem+0x40);	c->reply_port = (u32 *)(mem+0x44);	c->mem_phys = memptr;	c->mem_offset = (u32)mem;	c->destructor = i2o_pci_dispose;		c->bind = i2o_pci_bind;	c->unbind = i2o_pci_unbind;	c->bus_enable = i2o_pci_enable;	c->bus_disable = i2o_pci_disable;		c->type = I2O_TYPE_PCI;	/*	 *	Cards that fall apart if you hit them with large I/O	 *	loads...	 */	 	if(dev->vendor == PCI_VENDOR_ID_NCR && dev->device == 0x0630)	{		c->bus.pci.short_req=1;		printk(KERN_INFO "I2O: Symbios FC920 workarounds activated.\n");	}	if(dev->subsystem_vendor == PCI_VENDOR_ID_PROMISE)	{		c->bus.pci.queue_buggy=1;		if (dev->subsystem_device == 0x0000) /* SX6000 ???? */			c->bus.pci.queue_buggy=2;		printk(KERN_INFO "I2O: Promise workarounds activated.\n");	}	/*	 *	Cards that go bananas if you quiesce them before you reset	 *	them	 */	 	if(dev->vendor == PCI_VENDOR_ID_DPT)		c->bus.pci.dpt=1;		/* 	 * Enable Write Combining MTRR for IOP's memory region	 */#ifdef CONFIG_MTRR	c->bus.pci.mtrr_reg0 =		mtrr_add(c->mem_phys, size, MTRR_TYPE_WRCOMB, 1);/** If it is an INTEL i960 I/O processor then set the first 64K to Uncacheable* since the region contains the Messaging unit which shouldn't be cached.*/	c->bus.pci.mtrr_reg1 = -1;	if(dev->vendor == PCI_VENDOR_ID_INTEL || dev->vendor == PCI_VENDOR_ID_DPT)	{		printk(KERN_INFO "I2O: MTRR workaround for Intel i960 processor\n"); 		c->bus.pci.mtrr_reg1 =	mtrr_add(c->mem_phys, 65536, MTRR_TYPE_UNCACHABLE, 1);		if(c->bus.pci.mtrr_reg1< 0)		{			printk(KERN_INFO "i2o_pci: Error in setting MTRR_TYPE_UNCACHABLE\n");			mtrr_del(c->bus.pci.mtrr_reg0, c->mem_phys, size);			c->bus.pci.mtrr_reg0 = -1;		}	}#endif	I2O_IRQ_WRITE32(c,0xFFFFFFFF);#ifdef MODULE	i = core->install(c);#else	i = i2o_install_controller(c);#endif /* MODULE */		if(i<0)	{		printk(KERN_ERR "i2o: Unable to install controller.\n");		kfree(c);		iounmap(mem);		return i;	}	c->bus.pci.irq = dev->irq;	if(c->bus.pci.irq)	{		i=request_irq(dev->irq, i2o_pci_interrupt, SA_SHIRQ,			c->name, c);		if(i<0)		{			printk(KERN_ERR "%s: unable to allocate interrupt %d.\n",				c->name, dev->irq);			c->bus.pci.irq = -1;#ifdef MODULE			core->delete(c);#else			i2o_delete_controller(c);#endif /* MODULE */				iounmap(mem);			return -EBUSY;		}	}	printk(KERN_INFO "%s: Installed at IRQ%d\n", c->name, dev->irq);	I2O_IRQ_WRITE32(c,0x0);	c->enabled = 1;	return 0;	}int __init i2o_pci_scan(void){	struct pci_dev *dev;	int count=0;		printk(KERN_INFO "i2o: Checking for PCI I2O controllers...\n");	pci_for_each_dev(dev)		{		if((dev->class>>8)!=PCI_CLASS_INTELLIGENT_I2O)			continue;		if(dev->vendor == PCI_VENDOR_ID_DPT)		{			if(dev->device == 0xA501 || dev->device == 0xA511)			{				printk(KERN_INFO "i2o: Skipping Adaptec/DPT I2O raid with preferred native driver.\n");				continue;			}		}		if((dev->class&0xFF)>1)		{			printk(KERN_INFO "i2o: I2O Controller found but does not support I2O 1.5 (skipping).\n");			continue;		}		if (pci_enable_device(dev))			continue;		printk(KERN_INFO "i2o: I2O controller on bus %d at %d.\n",			dev->bus->number, dev->devfn);		pci_set_master(dev);		if(i2o_pci_install(dev)==0)			count++;	}	if(count)		printk(KERN_INFO "i2o: %d I2O controller%s found and installed.\n", count,			count==1?"":"s");	return count?count:-ENODEV;}#ifdef I2O_HOTPLUG_SUPPORT/* * Activate a newly found PCI I2O controller * Not used now, but will be needed in future for * hot plug PCI support */static void i2o_pci_activate(i2o_controller * c){	int i=0;	struct i2o_controller *c;		if(c->type == I2O_TYPE_PCI)	{		I2O_IRQ_WRITE32(c,0);#ifdef MODULE		if(core->activate(c))#else		if(i2o_activate_controller(c))#endif /* MODULE */		{			printk("%s: Failed to initialize.\n", c->name);#ifdef MODULE			core->unlock(c);			core->delete(c);#else			i2o_unlock_controller(c);			i2o_delete_controller(c);#endif			continue;		}	}}#endif // I2O_HOTPLUG_SUPPORT#ifdef MODULEint i2o_pci_core_attach(struct i2o_core_func_table *table){	MOD_INC_USE_COUNT;	core = table;	return i2o_pci_scan();}void i2o_pci_core_detach(void){	core = NULL;	MOD_DEC_USE_COUNT;}int init_module(void){	printk(KERN_INFO "Linux I2O PCI support (c) 1999 Red Hat Software.\n");		core = NULL; 	return 0; }void cleanup_module(void){}EXPORT_SYMBOL(i2o_pci_core_attach);EXPORT_SYMBOL(i2o_pci_core_detach);MODULE_AUTHOR("Red Hat Software");MODULE_DESCRIPTION("I2O PCI Interface");MODULE_LICENSE("GPL");#elsevoid __init i2o_pci_init(void){	printk(KERN_INFO "Linux I2O PCI support (c) 1999 Red Hat Software.\n");	i2o_pci_scan();}#endif

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
蜜臀av一级做a爰片久久| 日韩视频在线永久播放| heyzo一本久久综合| 99精品在线观看视频| 在线欧美小视频| 亚洲色欲色欲www| 国产成人亚洲综合a∨猫咪| 大白屁股一区二区视频| 欧美在线观看视频一区二区| 欧美老女人在线| 久久丝袜美腿综合| 亚洲成av人片在www色猫咪| 极品瑜伽女神91| 欧美日韩一区二区在线观看 | 亚洲一区二区三区四区在线观看| 国产麻豆一精品一av一免费| 欧美日韩一级视频| 日本一区二区在线不卡| 麻豆国产一区二区| 色美美综合视频| 日本一区二区三区在线不卡| 日本不卡中文字幕| 欧美日韩亚洲丝袜制服| 亚洲精品国产第一综合99久久| 国产一区二区0| 久久久久亚洲蜜桃| 狠狠色伊人亚洲综合成人| 欧美日韩五月天| 亚洲无线码一区二区三区| 夜夜精品视频一区二区| 不卡av在线免费观看| 久久毛片高清国产| 国内一区二区视频| 亚洲精品在线观看视频| 久久99久久久久| 欧美va在线播放| 国产aⅴ综合色| 国产精品剧情在线亚洲| 99在线热播精品免费| 综合久久给合久久狠狠狠97色 | 久久久久高清精品| 在线看国产一区| 亚洲v中文字幕| 久久久精品一品道一区| 99re成人精品视频| 日日欢夜夜爽一区| 久久久99久久精品欧美| 懂色av一区二区三区免费观看| 一区二区日韩电影| 日韩午夜三级在线| 99re视频精品| 久久成人免费网| 一级日本不卡的影视| 精品少妇一区二区三区免费观看 | 亚洲精品一区二区三区99| a亚洲天堂av| 国产呦萝稀缺另类资源| 亚洲一二三区在线观看| 中文字幕av一区二区三区高| 欧美猛男超大videosgay| www.亚洲色图| 韩国av一区二区三区在线观看| 亚洲成人三级小说| 成人欧美一区二区三区| 久久久久久久网| 欧美日韩中文国产| 91麻豆精品在线观看| 国产精品一区二区免费不卡| 日韩黄色一级片| 日韩激情视频网站| 蜜臀精品一区二区三区在线观看| 亚洲一区二区综合| 亚洲丶国产丶欧美一区二区三区| 国产精品久久久久一区二区三区共| 欧美成人video| 精品99999| 久久精品视频一区| 亚洲精品一二三| 亚洲黄色小说网站| 亚洲美女视频在线| 亚洲国产cao| 免费欧美在线视频| 精品一区二区三区免费视频| 蜜臀av一区二区在线免费观看 | 欧美男人的天堂一二区| 欧美高清hd18日本| 精品国产91九色蝌蚪| 国产亚洲成aⅴ人片在线观看| 欧美国产激情一区二区三区蜜月| 中文字幕一区二区三区四区| 亚洲激情网站免费观看| 日韩成人午夜精品| 国产精品综合av一区二区国产馆| av电影天堂一区二区在线 | 日韩综合一区二区| 国产成人久久精品77777最新版本 国产成人鲁色资源国产91色综 | 色婷婷av一区| 久久综合九色综合久久久精品综合| 自拍偷拍国产亚洲| 日本v片在线高清不卡在线观看| 一区二区三区免费看视频| 毛片一区二区三区| 欧洲人成人精品| 国产精品国产自产拍在线| 天堂va蜜桃一区二区三区| 成人国产精品视频| 欧美一区二区三区精品| 亚洲午夜一区二区三区| 国产不卡在线视频| 久久久久久日产精品| 精品亚洲免费视频| 8v天堂国产在线一区二区| 日韩毛片视频在线看| 福利一区福利二区| 国产免费成人在线视频| 美女高潮久久久| 国产精品毛片大码女人| 日本高清成人免费播放| 亚洲女子a中天字幕| 91在线免费视频观看| 中文字幕第一区| 成av人片一区二区| 亚洲色图欧洲色图| 欧美亚洲一区二区在线观看| 亚洲精品中文在线| 欧美亚洲一区二区三区四区| 亚洲国产你懂的| 91精品国产全国免费观看| 极品少妇xxxx偷拍精品少妇| 久久亚洲精华国产精华液 | 久久综合久久综合久久| 成人性视频网站| 一区二区三区产品免费精品久久75| 一本色道久久综合亚洲精品按摩| 一区二区三区国产豹纹内裤在线| 欧美美女一区二区三区| 精品中文字幕一区二区小辣椒| 久久久www成人免费无遮挡大片 | 国产一区视频在线看| 欧美一级一级性生活免费录像| 乱中年女人伦av一区二区| 久久久综合网站| 欧美中文字幕不卡| 国产精品自在在线| 亚洲一区在线观看免费观看电影高清| 在线成人免费观看| 成人黄页在线观看| 日韩福利视频导航| 亚洲精品日韩综合观看成人91| 欧美不卡一区二区三区四区| 91一区二区三区在线观看| 美女视频黄频大全不卡视频在线播放| 久久亚洲私人国产精品va媚药| 91国偷自产一区二区三区观看| 国产一区二区不卡| 蜜桃一区二区三区在线观看| 一区二区三区欧美在线观看| 久久久久青草大香线综合精品| 欧美一区二区三区四区在线观看| 日本福利一区二区| 国产精品一区二区三区99| 精品欧美一区二区久久| 欧美电影免费观看高清完整版在| 99re6这里只有精品视频在线观看| 99久久久久久| 日韩欧美中文字幕公布| 日韩免费视频线观看| 欧美成人一区二区三区| 久久综合国产精品| 欧美成人aa大片| 国产精品美女一区二区三区| 欧美激情资源网| 一区二区三区加勒比av| 婷婷综合另类小说色区| 亚洲图片有声小说| 国产资源精品在线观看| 99久久精品免费看国产免费软件| 成人高清视频在线| 欧美优质美女网站| 久久免费电影网| 亚洲免费在线视频| 欧美xxxxx牲另类人与| 欧美三级视频在线| 欧美日韩精品欧美日韩精品| 欧美国产日韩a欧美在线观看| 午夜a成v人精品| 色综合久久99| 国产精品久久久久影院色老大 | 精品日韩一区二区三区免费视频| 欧美激情艳妇裸体舞| 五月天亚洲婷婷| 欧美三级日韩三级| 日韩久久一区二区| 成人午夜免费电影| 国产女人18毛片水真多成人如厕| 日韩成人精品视频| 6080午夜不卡| 三级欧美在线一区| 精品视频一区三区九区| 亚洲精品国产a久久久久久|