Linux Block IO V

Block IO 层的请求完成在整个IO完成的路径上紧接SCSI CMD完成之后,相应的回调函数在biorequest以及request_queue初始化时被注册。


blk_done_softirq()
	rq->q->softirq_done_fn(rq);     //scsi_softirq_done()
		case SUCCESS:
		scsi_finish_command()	
			scsi_end_request()
				blk_update_request()
					req_bio_endio()
						bio_endio()
							bio->bi_end_io()	//submit_bio_wait_endio etc
				blk_finish_request()
					req->end_io()   		//发自SCSI层的命令会有这个回调:blk_end_sync_rq()

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.