From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56002) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UmJAK-0003p8-DH for qemu-devel@nongnu.org; Tue, 11 Jun 2013 03:38:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UmJAJ-0003fw-Fg for qemu-devel@nongnu.org; Tue, 11 Jun 2013 03:38:52 -0400 Received: from mx1.redhat.com ([209.132.183.28]:37812) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UmJAJ-0003fr-8g for qemu-devel@nongnu.org; Tue, 11 Jun 2013 03:38:51 -0400 Date: Tue, 11 Jun 2013 09:38:47 +0200 From: Kevin Wolf Message-ID: <20130611073847.GA2379@dhcp-200-207.str.redhat.com> References: <1370888600-25388-1-git-send-email-mdroth@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1370888600-25388-1-git-send-email-mdroth@linux.vnet.ibm.com> Subject: Re: [Qemu-devel] [PATCH] ide-test: fix failure for test_flush List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Michael Roth Cc: qemu-devel@nongnu.org, stefanha@redhat.com, afaerber@suse.de Am 10.06.2013 um 20:23 hat Michael Roth geschrieben: > bd07684aacfb61668ae2c25b7dd00b64f3d7c7f3 added a test to ensure BSY > flag is set when a flush request is in flight. It does this by setting > a blkdebug breakpoint on flush_to_os before issuing a CMD_FLUSH_CACHE. > It then resumes CMD_FLUSH_CACHE operation and checks that BSY is unset. > > The actual unsetting of BSY does not occur until ide_flush_cb gets > called in a bh, however, so in some cases this check will race with > the actual completion. > > Fix this by polling the ide status register until BSY flag gets unset > before we do our final sanity checks. According to > f68ec8379e88502b4841a110c070e9b118d3151c this is in line with how a guest > would determine whether or not the device is still busy. > > Signed-off-by: Michael Roth Thanks, applied to the block branch. Kevin