From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51088) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VPUON-0005wh-Rg for qemu-devel@nongnu.org; Fri, 27 Sep 2013 05:31:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VPUOG-0000lv-Jg for qemu-devel@nongnu.org; Fri, 27 Sep 2013 05:31:19 -0400 Received: from mx1.redhat.com ([209.132.183.28]:38447) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VPUOG-0000lr-CD for qemu-devel@nongnu.org; Fri, 27 Sep 2013 05:31:12 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r8R9VB2o017025 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 27 Sep 2013 05:31:11 -0400 Date: Fri, 27 Sep 2013 11:31:10 +0200 From: Kevin Wolf Message-ID: <20130927093110.GD2440@dhcp-200-207.str.redhat.com> References: <1380124032-20803-1-git-send-email-mreitz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1380124032-20803-1-git-send-email-mreitz@redhat.com> Subject: Re: [Qemu-devel] [PATCH] qcow2: count_contiguous_clusters and compression List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz Cc: qemu-devel@nongnu.org, Stefan Hajnoczi Am 25.09.2013 um 17:47 hat Max Reitz geschrieben: > The function is not intended to be used on compressed clusters and will > not work correctly, if used anyway, since L2E_OFFSET_MASK is not the > right mask for determining the offset of compressed clusters. Therefore, > assert that the first cluster is not compressed and always include the > compression flag in the mask of significant flags, i.e., stop the search > as soon as a compressed cluster occurs. > > Signed-off-by: Max Reitz This is supposed to be a cleanup patch with no functional change, right? How about removing explicit QCOW_OFLAG_COMPRESSED arguments from callers? Kevin