From patchwork Thu Feb 27 10:15:22 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Lieven X-Patchwork-Id: 324750 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 50B362C009C for ; Thu, 27 Feb 2014 21:16:15 +1100 (EST) Received: from localhost ([::1]:45193 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WIy0j-0000Pd-0p for incoming@patchwork.ozlabs.org; Thu, 27 Feb 2014 05:16:13 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:32852) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WIy0C-0000EW-9e for qemu-devel@nongnu.org; Thu, 27 Feb 2014 05:15:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WIy06-0005YE-NE for qemu-devel@nongnu.org; Thu, 27 Feb 2014 05:15:40 -0500 Received: from mx.ipv6.kamp.de ([2a02:248:0:51::16]:51332 helo=mx01.kamp.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WIy06-0005Y3-2o for qemu-devel@nongnu.org; Thu, 27 Feb 2014 05:15:34 -0500 Received: (qmail 9462 invoked by uid 89); 27 Feb 2014 10:15:33 -0000 Received: from [195.62.97.28] by client-16-kamp (envelope-from , uid 89) with qmail-scanner-2010/03/19-MF (clamdscan: 0.98.1/18521. hbedv: 8.2.14.12/7.11.133.212. spamassassin: 3.3.1. Clear:RC:1(195.62.97.28):SA:0(-2.0/5.0):. Processed in 10.261882 secs); 27 Feb 2014 10:15:33 -0000 Received: from smtp.kamp.de (HELO submission.kamp.de) ([195.62.97.28]) by mx01.kamp.de with SMTP; 27 Feb 2014 10:15:22 -0000 X-GL_Whitelist: yes Received: (qmail 24820 invoked from network); 27 Feb 2014 10:15:20 -0000 Received: from ac54.vpn.kamp-intra.net (HELO ?172.20.250.54?) (pl@kamp.de@172.20.250.54) by submission.kamp.de with ESMTPS (DHE-RSA-CAMELLIA256-SHA encrypted) ESMTPA; 27 Feb 2014 10:15:20 -0000 Message-ID: <530F103A.7090705@kamp.de> Date: Thu, 27 Feb 2014 11:15:22 +0100 From: Peter Lieven User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: qemu-devel@nongnu.org X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a02:248:0:51::16 Cc: kwolf@redhat.com, Peter Lieven , Fam Zheng , stefanha@redhat.com Subject: [Qemu-devel] [PATCH] block/vmdk: do not report file offset for compressed extents X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Signed-off-by: Peter Lieven --- block/vmdk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/vmdk.c b/block/vmdk.c index ff6f5ee..5fa29b0 100644 --- a/block/vmdk.c +++ b/block/vmdk.c @@ -1146,7 +1146,7 @@ static int64_t coroutine_fn vmdk_co_get_block_status(BlockDriverState *bs, break; case VMDK_OK: ret = BDRV_BLOCK_DATA; - if (extent->file == bs->file) { + if (extent->file == bs->file && !extent->compressed) { ret |= BDRV_BLOCK_OFFSET_VALID | offset; }