From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59714) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WzOy8-0007KS-7G for qemu-devel@nongnu.org; Tue, 24 Jun 2014 07:33:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WzOy1-0005d5-0O for qemu-devel@nongnu.org; Tue, 24 Jun 2014 07:32:56 -0400 Received: from mx1.redhat.com ([209.132.183.28]:44395) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WzOy0-0005cy-OT for qemu-devel@nongnu.org; Tue, 24 Jun 2014 07:32:48 -0400 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s5OBWknN007421 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Tue, 24 Jun 2014 07:32:47 -0400 Date: Tue, 24 Jun 2014 13:32:42 +0200 From: Kevin Wolf Message-ID: <20140624113242.GF3458@noname.redhat.com> References: <1402282583-19707-1-git-send-email-famz@redhat.com> <20140624042503.GA1865@T430.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20140624042503.GA1865@T430.redhat.com> Subject: Re: [Qemu-devel] [PATCH v2 0/4] mirror: Fix behavior for zero byte image List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Fam Zheng Cc: qemu-devel@nongnu.org, Stefan Hajnoczi Am 24.06.2014 um 06:25 hat Fam Zheng geschrieben: > On Mon, 06/09 10:56, Fam Zheng wrote: > > The current behavior of mirroring zero byte image is slightly different from > > non-zero image: the BLOCK_JOB_READY event is skipped and job is completed > > immediately. This is not a big problem for human user but only makes management > > software harder to write. Since we are focusing on an good API instead of UI, > > let's make the behavior more consistent and predictable. > > > > The first patch fixes the behavior. The following two patches add test case for > > the involved code path. > > > > Thanks for Eric Blake to report this! > > Ping. Shall we merge this before it rots? I had it already applied, but now test case 041 fails for me, so I'm going to remove it from my tree again: 041 7s ... [13:28:48] [13:29:27] [failed, exit status 1] - output mismatch (see 041.out.bad) --- 041.out 2014-06-24 13:23:13.597949977 +0200 +++ 041.out.bad 2014-06-24 13:29:27.024871226 +0200 @@ -1,5 +1,31 @@ -..................................... +qemu-img: /home/kwolf/source/qemu/tests/qemu-iotests/scratch/target.img: Cluster size must be a power of two between 512 and 2048k +qemu-img: /home/kwolf/source/qemu/tests/qemu-iotests/scratch/target.img: Cluster size must be a power of two between 512 and 2048k +..........................F...F...... +====================================================================== +FAIL: test_large_cluster (__main__.TestSingleDriveZeroLength) +---------------------------------------------------------------------- +Traceback (most recent call last): + File "./041", line 185, in test_large_cluster + self.assert_qmp(result, 'return', {}) + File "/home/kwolf/source/qemu/tests/qemu-iotests/iotests.py", line 232, in assert_qmp + result = self.dictpath(d, path) + File "/home/kwolf/source/qemu/tests/qemu-iotests/iotests.py", line 211, in dictpath + self.fail('failed path traversal for "%s" in "%s"' % (path, str(d))) +AssertionError: failed path traversal for "return" in "{u'error': {u'class': u'GenericError', u'desc': u"Could not open '/home/kwolf/source/qemu/tests/qemu-iotests/scratch/target.img': No such file or directory"}}" + +====================================================================== +FAIL: test_small_buffer2 (__main__.TestSingleDriveZeroLength) +---------------------------------------------------------------------- +Traceback (most recent call last): + File "./041", line 169, in test_small_buffer2 + self.assert_qmp(result, 'return', {}) + File "/home/kwolf/source/qemu/tests/qemu-iotests/iotests.py", line 232, in assert_qmp + result = self.dictpath(d, path) + File "/home/kwolf/source/qemu/tests/qemu-iotests/iotests.py", line 211, in dictpath + self.fail('failed path traversal for "%s" in "%s"' % (path, str(d))) +AssertionError: failed path traversal for "return" in "{u'error': {u'class': u'GenericError', u'desc': u"Could not open '/home/kwolf/source/qemu/tests/qemu-iotests/scratch/target.img': No such file or directory"}}" + ---------------------------------------------------------------------- Ran 37 tests -OK +FAILED (failures=2) Failures: 041