From patchwork Wed Jan 6 13:51:18 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marcelo Tosatti X-Patchwork-Id: 71291 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.2) with ESMTP id o06DreYZ002481 for ; Wed, 6 Jan 2010 13:53:40 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755647Ab0AFNxK (ORCPT ); Wed, 6 Jan 2010 08:53:10 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755629Ab0AFNxJ (ORCPT ); Wed, 6 Jan 2010 08:53:09 -0500 Received: from mx1.redhat.com ([209.132.183.28]:57472 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755516Ab0AFNxF (ORCPT ); Wed, 6 Jan 2010 08:53:05 -0500 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o06DqmMV024772 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 6 Jan 2010 08:52:48 -0500 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx05.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o06DqjQG031479; Wed, 6 Jan 2010 08:52:47 -0500 Received: from amt.cnet (vpn-8-51.rdu.redhat.com [10.11.8.51]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id o06DqhV2020769; Wed, 6 Jan 2010 08:52:44 -0500 Received: from amt.cnet (amt.cnet [127.0.0.1]) by amt.cnet (Postfix) with ESMTP id 2753E6800B3; Wed, 6 Jan 2010 11:51:41 -0200 (BRST) Received: (from marcelo@localhost) by amt.cnet (8.14.3/8.14.3/Submit) id o06DpIRt028680; Wed, 6 Jan 2010 11:51:18 -0200 Date: Wed, 6 Jan 2010 11:51:18 -0200 From: Marcelo Tosatti To: Mark Cave-Ayland , Anthony Liguori , Yaniv Kaul Cc: kvm@vger.kernel.org Subject: Re: VNC framebuffer block artefacts on qemu-kvm-0.12.1.1 Message-ID: <20100106135118.GA28640@amt.cnet> References: <4B4364AE.8080509@siriusit.co.uk> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <4B4364AE.8080509@siriusit.co.uk> User-Agent: Mutt/1.5.19 (2009-01-05) X-Scanned-By: MIMEDefang 2.67 on 10.5.11.18 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org diff --git a/vnchextile.h b/vnchextile.h index 432ed89..c96ede3 100644 --- a/vnchextile.h +++ b/vnchextile.h @@ -73,7 +73,7 @@ static void CONCAT(send_hextile_tile_, NAME)(VncState *vs, *last_bg = bg; } - if (n_colors < 3 && (!*has_fg || *last_fg != fg)) { + if (!*has_fg || *last_fg != fg) { flags |= 0x04; *has_fg = 1; *last_fg = fg; @@ -165,6 +165,8 @@ static void CONCAT(send_hextile_tile_, NAME)(VncState *vs, irow += ds_get_linesize(vs->ds) / sizeof(pixel_t); } + /* A SubrectsColoured subtile invalidates the foreground color */ + *has_fg = 0; if (n_data > (w * h * sizeof(pixel_t))) { n_colors = 4; flags = 0x01;