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

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

?? ide-cd.c

?? linux和2410結(jié)合開發(fā) 用他可以生成2410所需的zImage文件
?? C
?? 第 1 頁 / 共 5 頁
字號:
	dest = info->buffer + info->nsectors_buffered * SECTOR_SIZE;	while (sectors_to_buffer > 0) {		atapi_input_bytes (drive, dest, SECTOR_SIZE);		--sectors_to_buffer;		--sectors_to_transfer;		++info->nsectors_buffered;		dest += SECTOR_SIZE;	}	/* Throw away any remaining data. */	while (sectors_to_transfer > 0) {		char dum[SECTOR_SIZE];		atapi_input_bytes (drive, dum, sizeof (dum));		--sectors_to_transfer;	}}/* * Check the contents of the interrupt reason register from the cdrom * and attempt to recover if there are problems.  Returns  0 if everything's * ok; nonzero if the request has been terminated. */static inlineint cdrom_read_check_ireason (ide_drive_t *drive, int len, int ireason){	ireason &= 3;	if (ireason == 2) return 0;	if (ireason == 0) {		/* Whoops... The drive is expecting to receive data from us! */		printk ("%s: cdrom_read_intr: "			"Drive wants to transfer data the wrong way!\n",			drive->name);		/* Throw some data at the drive so it doesn't hang		   and quit this request. */		while (len > 0) {			int dum = 0;			atapi_output_bytes (drive, &dum, sizeof (dum));			len -= sizeof (dum);		}	} else  if (ireason == 1) {		/* Some drives (ASUS) seem to tell us that status		 * info is available. just get it and ignore.		 */		GET_STAT();		return 0;	} else {		/* Drive wants a command packet, or invalid ireason... */		printk ("%s: cdrom_read_intr: bad interrupt reason %d\n",			drive->name, ireason);	}	cdrom_end_request (0, drive);	return -1;}/* * Interrupt routine.  Called when a read request has completed. */static ide_startstop_t cdrom_read_intr (ide_drive_t *drive){	int stat;	int ireason, len, sectors_to_transfer, nskip;	struct cdrom_info *info = drive->driver_data;	int i, dma = info->dma, dma_error = 0;	ide_startstop_t startstop;	struct request *rq = HWGROUP(drive)->rq;	/* Check for errors. */	if (dma) {		info->dma = 0;		if ((dma_error = HWIF(drive)->dmaproc(ide_dma_end, drive)))			HWIF(drive)->dmaproc(ide_dma_off, drive);	}	if (cdrom_decode_status (&startstop, drive, 0, &stat))		return startstop; 	if (dma) {		if (!dma_error) {			for (i = rq->nr_sectors; i > 0;) {				i -= rq->current_nr_sectors;				ide_end_request(1, HWGROUP(drive));			}			return ide_stopped;		} else			return ide_error (drive, "dma error", stat);	}	/* Read the interrupt reason and the transfer length. */	ireason = IN_BYTE (IDE_NSECTOR_REG);	len = IN_BYTE (IDE_LCYL_REG) + 256 * IN_BYTE (IDE_HCYL_REG);	/* If DRQ is clear, the command has completed. */	if ((stat & DRQ_STAT) == 0) {		/* If we're not done filling the current buffer, complain.		   Otherwise, complete the command normally. */		if (rq->current_nr_sectors > 0) {			printk ("%s: cdrom_read_intr: data underrun (%ld blocks)\n",				drive->name, rq->current_nr_sectors);			cdrom_end_request (0, drive);		} else			cdrom_end_request (1, drive);		return ide_stopped;	}	/* Check that the drive is expecting to do the same thing we are. */	if (cdrom_read_check_ireason (drive, len, ireason))		return ide_stopped;	/* Assume that the drive will always provide data in multiples	   of at least SECTOR_SIZE, as it gets hairy to keep track	   of the transfers otherwise. */	if ((len % SECTOR_SIZE) != 0) {		printk ("%s: cdrom_read_intr: Bad transfer size %d\n",			drive->name, len);		if (CDROM_CONFIG_FLAGS (drive)->limit_nframes)			printk ("  This drive is not supported by this version of the driver\n");		else {			printk ("  Trying to limit transfer sizes\n");			CDROM_CONFIG_FLAGS (drive)->limit_nframes = 1;		}		cdrom_end_request (0, drive);		return ide_stopped;	}	/* The number of sectors we need to read from the drive. */	sectors_to_transfer = len / SECTOR_SIZE;	/* First, figure out if we need to bit-bucket	   any of the leading sectors. */	nskip = MIN ((int)(rq->current_nr_sectors - (rq->bh->b_size >> SECTOR_BITS)),		     sectors_to_transfer);	while (nskip > 0) {		/* We need to throw away a sector. */		char dum[SECTOR_SIZE];		atapi_input_bytes (drive, dum, sizeof (dum));		--rq->current_nr_sectors;		--nskip;		--sectors_to_transfer;	}	/* Now loop while we still have data to read from the drive. */	while (sectors_to_transfer > 0) {		int this_transfer;		/* If we've filled the present buffer but there's another		   chained buffer after it, move on. */		if (rq->current_nr_sectors == 0 && rq->nr_sectors)			cdrom_end_request (1, drive);		/* If the buffers are full, cache the rest of the data in our		   internal buffer. */		if (rq->current_nr_sectors == 0) {			cdrom_buffer_sectors(drive, rq->sector, sectors_to_transfer);			sectors_to_transfer = 0;		} else {			/* Transfer data to the buffers.			   Figure out how many sectors we can transfer			   to the current buffer. */			this_transfer = MIN (sectors_to_transfer,					     rq->current_nr_sectors);			/* Read this_transfer sectors			   into the current buffer. */			while (this_transfer > 0) {				atapi_input_bytes(drive, rq->buffer, SECTOR_SIZE);				rq->buffer += SECTOR_SIZE;				--rq->nr_sectors;				--rq->current_nr_sectors;				++rq->sector;				--this_transfer;				--sectors_to_transfer;			}		}	}	/* Done moving data!	   Wait for another interrupt. */	ide_set_handler(drive, &cdrom_read_intr, WAIT_CMD, NULL);	return ide_started;}/* * Try to satisfy some of the current read request from our cached data. * Returns nonzero if the request has been completed, zero otherwise. */static int cdrom_read_from_buffer (ide_drive_t *drive){	struct cdrom_info *info = drive->driver_data;	struct request *rq = HWGROUP(drive)->rq;	/* Can't do anything if there's no buffer. */	if (info->buffer == NULL) return 0;	/* Loop while this request needs data and the next block is present	   in our cache. */	while (rq->nr_sectors > 0 &&	       rq->sector >= info->sector_buffered &&	       rq->sector < info->sector_buffered + info->nsectors_buffered) {		if (rq->current_nr_sectors == 0)			cdrom_end_request (1, drive);		memcpy (rq->buffer,			info->buffer +			(rq->sector - info->sector_buffered) * SECTOR_SIZE,			SECTOR_SIZE);		rq->buffer += SECTOR_SIZE;		--rq->current_nr_sectors;		--rq->nr_sectors;		++rq->sector;	}	/* If we've satisfied the current request,	   terminate it successfully. */	if (rq->nr_sectors == 0) {		cdrom_end_request (1, drive);		return -1;	}	/* Move on to the next buffer if needed. */	if (rq->current_nr_sectors == 0)		cdrom_end_request (1, drive);	/* If this condition does not hold, then the kluge i use to	   represent the number of sectors to skip at the start of a transfer	   will fail.  I think that this will never happen, but let's be	   paranoid and check. */	if (rq->current_nr_sectors < (rq->bh->b_size >> SECTOR_BITS) &&	    (rq->sector % SECTORS_PER_FRAME) != 0) {		printk ("%s: cdrom_read_from_buffer: buffer botch (%ld)\n",			drive->name, rq->sector);		cdrom_end_request (0, drive);		return -1;	}	return 0;}/* * Routine to send a read packet command to the drive. * This is usually called directly from cdrom_start_read. * However, for drq_interrupt devices, it is called from an interrupt * when the drive is ready to accept the command. */static ide_startstop_t cdrom_start_read_continuation (ide_drive_t *drive){	struct packet_command pc;	struct request *rq = HWGROUP(drive)->rq;	int nsect, sector, nframes, frame, nskip;	/* Number of sectors to transfer. */	nsect = rq->nr_sectors;	/* Starting sector. */	sector = rq->sector;	/* If the requested sector doesn't start on a cdrom block boundary,	   we must adjust the start of the transfer so that it does,	   and remember to skip the first few sectors.	   If the CURRENT_NR_SECTORS field is larger than the size	   of the buffer, it will mean that we're to skip a number	   of sectors equal to the amount by which CURRENT_NR_SECTORS	   is larger than the buffer size. */	nskip = (sector % SECTORS_PER_FRAME);	if (nskip > 0) {		/* Sanity check... */		if (rq->current_nr_sectors != (rq->bh->b_size >> SECTOR_BITS) &&			(rq->sector % CD_FRAMESIZE != 0)) {			printk ("%s: cdrom_start_read_continuation: buffer botch (%lu)\n",				drive->name, rq->current_nr_sectors);			cdrom_end_request (0, drive);			return ide_stopped;		}		sector -= nskip;		nsect += nskip;		rq->current_nr_sectors += nskip;	}	/* Convert from sectors to cdrom blocks, rounding up the transfer	   length if needed. */	nframes = (nsect + SECTORS_PER_FRAME-1) / SECTORS_PER_FRAME;	frame = sector / SECTORS_PER_FRAME;	/* Largest number of frames was can transfer at once is 64k-1. For	   some drives we need to limit this even more. */	nframes = MIN (nframes, (CDROM_CONFIG_FLAGS (drive)->limit_nframes) ?		(65534 / CD_FRAMESIZE) : 65535);	/* Set up the command */	memset (&pc.c, 0, sizeof (pc.c));	pc.c[0] = GPCMD_READ_10;	pc.c[7] = (nframes >> 8);	pc.c[8] = (nframes & 0xff);	put_unaligned(cpu_to_be32(frame), (unsigned int *) &pc.c[2]);	pc.timeout = WAIT_CMD;	/* Send the command to the drive and return. */	return cdrom_transfer_packet_command(drive, &pc, &cdrom_read_intr);}#define IDECD_SEEK_THRESHOLD	(1000)			/* 1000 blocks */#define IDECD_SEEK_TIMER	(5 * WAIT_MIN_SLEEP)	/* 100 ms */#define IDECD_SEEK_TIMEOUT     WAIT_CMD			/* 10 sec */static ide_startstop_t cdrom_seek_intr (ide_drive_t *drive){	struct cdrom_info *info = drive->driver_data;	int stat;	static int retry = 10;	ide_startstop_t startstop;	if (cdrom_decode_status (&startstop, drive, 0, &stat))		return startstop;	CDROM_CONFIG_FLAGS(drive)->seeking = 1;	if (retry && jiffies - info->start_seek > IDECD_SEEK_TIMER) {		if (--retry == 0) {			/*			 * this condition is far too common, to bother			 * users about it			 */#if 0			printk("%s: disabled DSC seek overlap\n", drive->name);#endif			drive->dsc_overlap = 0;		}	}	return ide_stopped;}static ide_startstop_t cdrom_start_seek_continuation (ide_drive_t *drive){	struct packet_command pc;	struct request *rq = HWGROUP(drive)->rq;	int sector, frame, nskip;	sector = rq->sector;	nskip = (sector % SECTORS_PER_FRAME);	if (nskip > 0)		sector -= nskip;	frame = sector / SECTORS_PER_FRAME;	memset (&pc.c, 0, sizeof (pc.c));	pc.c[0] = GPCMD_SEEK;	put_unaligned(cpu_to_be32(frame), (unsigned int *) &pc.c[2]);	pc.timeout = WAIT_CMD;	return cdrom_transfer_packet_command(drive, &pc, &cdrom_seek_intr);}static ide_startstop_t cdrom_start_seek (ide_drive_t *drive, unsigned int block){	struct cdrom_info *info = drive->driver_data;	info->dma = 0;	info->cmd = 0;	info->start_seek = jiffies;	return cdrom_start_packet_command (drive, 0, cdrom_start_seek_continuation);}static inline int cdrom_merge_requests(struct request *rq, struct request *nxt){	int ret = 1;	/*	 * partitions not really working, but better check anyway...	 */	if (rq->cmd == nxt->cmd && rq->rq_dev == nxt->rq_dev) {		rq->nr_sectors += nxt->nr_sectors;		rq->hard_nr_sectors += nxt->nr_sectors;		rq->bhtail->b_reqnext = nxt->bh;		rq->bhtail = nxt->bhtail;		list_del(&nxt->queue);		blkdev_release_request(nxt);		ret = 0;	}	return ret;}/* * the current request will always be the first one on the list */static void cdrom_attempt_remerge(ide_drive_t *drive, struct request *rq){	struct list_head *entry;	struct request *nxt;	unsigned long flags;	spin_lock_irqsave(&io_request_lock, flags);	while (1) {		entry = rq->queue.next;		if (entry == &drive->queue.queue_head)			break;		nxt = blkdev_entry_to_request(entry);		if (rq->sector + rq->nr_sectors != nxt->sector)			break;		else if (rq->nr_sectors + nxt->nr_sectors > SECTORS_MAX)			break;		if (cdrom_merge_requests(rq, nxt))			break;	}	spin_unlock_irqrestore(&io_request_lock, flags);}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
理论电影国产精品| 欧美成人官网二区| 亚洲午夜精品17c| 91精品中文字幕一区二区三区 | 欧美一级在线视频| 奇米色一区二区| 国产亚洲福利社区一区| av电影在线观看一区| 依依成人综合视频| 在线91免费看| 懂色av一区二区夜夜嗨| 亚洲日本免费电影| 欧美日韩高清一区二区不卡| 黄色成人免费在线| 亚洲激情第一区| 日韩欧美一卡二卡| 99久久精品国产毛片| 午夜精品123| 国产精品免费视频一区| 91精品国产综合久久福利软件| 亚洲成人综合网站| 精品国产乱码久久久久久久| 国产成人综合自拍| 亚洲另类春色国产| 久久九九国产精品| 欧美女孩性生活视频| 成人深夜福利app| 日本成人在线电影网| 欧美精选一区二区| 91视频观看免费| 狠狠狠色丁香婷婷综合激情| 中文字幕日本不卡| 久久综合精品国产一区二区三区| 色久优优欧美色久优优| 成人综合婷婷国产精品久久蜜臀| 性欧美疯狂xxxxbbbb| 亚洲欧洲日产国码二区| 国产女同互慰高潮91漫画| 欧美日韩国产系列| 欧美在线观看18| 日本韩国欧美三级| 色综合激情久久| 99热这里都是精品| 99久久99久久免费精品蜜臀| 成人av在线影院| 成人午夜视频免费看| 丁香啪啪综合成人亚洲小说 | 国产乱一区二区| 国产精品一区二区三区网站| 精品一区二区三区免费毛片爱 | 日韩精品一区第一页| 亚洲.国产.中文慕字在线| 亚洲第一在线综合网站| 天天综合色天天综合| 看国产成人h片视频| 国产精品一区二区免费不卡| 国产99久久久精品| 91免费看`日韩一区二区| 在线视频国内自拍亚洲视频| 欧美日韩在线播放| 久久久91精品国产一区二区三区| 欧美国产乱子伦| 中文字幕一区二区三区精华液| 日韩中文字幕不卡| 亚洲成人免费av| 国产真实乱偷精品视频免| 国产大陆亚洲精品国产| 色狠狠av一区二区三区| 欧美精品乱人伦久久久久久| 久久九九久久九九| 婷婷成人激情在线网| 国产乱子轮精品视频| 91同城在线观看| 欧美成人女星排名| 亚洲综合色丁香婷婷六月图片| 久久se这里有精品| 91一区二区三区在线播放| 精品理论电影在线| 午夜日韩在线电影| 国产精品一二三四区| 欧美天堂一区二区三区| 中文文精品字幕一区二区| 日本 国产 欧美色综合| 一本大道av一区二区在线播放 | 2017欧美狠狠色| 亚洲高清三级视频| 在线精品视频小说1| 久久久夜色精品亚洲| 欧美日韩国产一区二区三区地区| 国产亚洲综合性久久久影院| 裸体一区二区三区| 51精品国自产在线| 天堂久久一区二区三区| 91久久线看在观草草青青| 亚洲欧美电影一区二区| 91国在线观看| 国产精品久久久久影视| 成人爱爱电影网址| 成人免费视频在线观看| 99久久er热在这里只有精品66| 中文字幕巨乱亚洲| 91免费国产在线观看| 国产精品全国免费观看高清| 国产精品18久久久久久久久| 精品少妇一区二区三区视频免付费 | 91丨九色丨国产丨porny| 亚洲自拍偷拍麻豆| 69av一区二区三区| 国产专区欧美精品| 国产区在线观看成人精品| 国产成人免费视频精品含羞草妖精| 久久青草欧美一区二区三区| 国产福利91精品| 亚洲私人影院在线观看| 日韩一级大片在线| 国产又黄又大久久| 亚洲欧美偷拍三级| 欧美日韩视频在线一区二区| 精品亚洲国产成人av制服丝袜| 久久综合狠狠综合久久激情| 色综合久久精品| 国产尤物一区二区在线| 亚洲精品中文字幕在线观看| 欧美人xxxx| 国产另类ts人妖一区二区| 一区二区三区欧美久久| 日本一区二区三区久久久久久久久不 | 中文字幕免费在线观看视频一区| 日本韩国一区二区三区视频| 成人精品免费网站| 国模一区二区三区白浆| 亚洲欧美欧美一区二区三区| 精品福利av导航| 欧美日韩一区二区三区四区| 丁香婷婷综合色啪| 蜜臀av性久久久久蜜臀aⅴ流畅| 国产精品系列在线| 久久蜜臀精品av| 日韩欧美久久久| 91精品国产高清一区二区三区蜜臀 | 亚洲人xxxx| 国产日韩精品一区二区浪潮av| 91玉足脚交白嫩脚丫在线播放| 免费的成人av| 日产国产欧美视频一区精品| 一区二区三区精密机械公司| 亚洲欧洲成人精品av97| 亚洲国产精品成人综合| 国产精品丝袜黑色高跟| 2024国产精品| 久久精品亚洲国产奇米99| 久久久精品欧美丰满| 久久中文字幕电影| 2欧美一区二区三区在线观看视频 337p粉嫩大胆噜噜噜噜噜91av | 久久综合色综合88| 2023国产一二三区日本精品2022| 精品国产乱码久久久久久久久 | 久久精品免费在线观看| 国产欧美一区二区精品性色| 国产亚洲一本大道中文在线| 国产精品成人免费| 亚洲黄一区二区三区| 日韩高清在线不卡| 国产乱对白刺激视频不卡| 成人av免费在线播放| 欧美色图在线观看| 久久―日本道色综合久久| 亚洲激情六月丁香| 国产一区二区免费在线| 欧美精品久久99| 国产精品国产三级国产三级人妇| 亚洲制服丝袜av| 国产成人免费在线视频| 91精品国产91热久久久做人人| 欧美激情一区二区三区在线| 秋霞午夜av一区二区三区| a亚洲天堂av| 久久精品综合网| 韩国精品久久久| 日韩欧美一级精品久久| 亚洲一区成人在线| 色综合久久久久综合体| 国产精品美女www爽爽爽| 免费看欧美女人艹b| 欧美日韩美女一区二区| 亚洲精品视频一区二区| 91麻豆123| 亚洲天堂a在线| 91麻豆视频网站| 亚洲综合一区在线| 一本大道久久a久久精品综合| 国产欧美日韩亚州综合| 麻豆免费看一区二区三区| 欧美喷潮久久久xxxxx| 五月激情综合色| 欧美一区二区三区四区视频| 天堂成人国产精品一区| 91精品福利在线一区二区三区| 午夜精品123| 欧美一区二区不卡视频|