From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:54299) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SF2JL-0005zN-Az for qemu-devel@nongnu.org; Tue, 03 Apr 2012 07:54:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SF2JC-0005B3-8U for qemu-devel@nongnu.org; Tue, 03 Apr 2012 07:54:06 -0400 Received: from e28smtp01.in.ibm.com ([122.248.162.1]:56210) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SF2J4-00057L-7m for qemu-devel@nongnu.org; Tue, 03 Apr 2012 07:53:58 -0400 Received: from /spool/local by e28smtp01.in.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 3 Apr 2012 17:23:26 +0530 Received: from d28av02.in.ibm.com (d28av02.in.ibm.com [9.184.220.64]) by d28relay05.in.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q33BrN6k4190274 for ; Tue, 3 Apr 2012 17:23:24 +0530 Received: from d28av02.in.ibm.com (loopback [127.0.0.1]) by d28av02.in.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q33HO0vv000525 for ; Wed, 4 Apr 2012 03:24:00 +1000 Message-ID: <4F7AE4B3.2090309@linux.vnet.ibm.com> Date: Tue, 03 Apr 2012 19:53:23 +0800 From: Zhi Hui Li MIME-Version: 1.0 References: <1333199982-10364-1-git-send-email-zhihuili@linux.vnet.ibm.com> <20120402123053.GB23753@stefanha-thinkpad.localdomain> In-Reply-To: <20120402123053.GB23753@stefanha-thinkpad.localdomain> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v3] Replace bdrv_* to bdrv_aio_* functions in DMA mode in fdc.c. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: zhihuili@cn.ibm.com, QEMU-devel I think what you say up is right, I will correct them, thank you very much! >> + bdrv_aio_readv(cur_drv->bs, fd_sector(cur_drv), >> +&fdctrl->qiov, fdc_sector_num, fdctrl_read_DMA_cb, opaque_cb); >> + return dma_len; > > Should be return 0 since we haven't completed I/O yet. > > Stefan > > I think the return value is not used not, so no matter what is returned it not necessary. if set the dma_len = 0, when call void DMA_set_return(int nret) function will return the real value; :)