From patchwork Thu Apr 22 18:19:01 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Clifton X-Patchwork-Id: 94184 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o3MIJ5r5031849 for ; Thu, 22 Apr 2010 18:19:41 GMT Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id D78F49F4D1; Thu, 22 Apr 2010 11:19:04 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from ppsw-32.csi.cam.ac.uk (ppsw-32.csi.cam.ac.uk [131.111.8.132]) by gabe.freedesktop.org (Postfix) with ESMTP id EA5579E7EF for ; Thu, 22 Apr 2010 11:19:02 -0700 (PDT) X-Cam-AntiVirus: no malware found X-Cam-SpamDetails: not scanned X-Cam-ScannerInfo: http://www.cam.ac.uk/cs/email/scanner/ Received: from eed22214.eng.cam.ac.uk ([129.169.174.214]:59833) by ppsw-32.csi.cam.ac.uk (smtp.hermes.cam.ac.uk [131.111.8.158]:465) with esmtpsa (LOGIN:pcjc2) (SSLv3:DHE-RSA-AES256-SHA:256) id 1O50zN-00076B-C0 (Exim 4.70) (return-path ); Thu, 22 Apr 2010 19:19:01 +0100 From: Peter Clifton To: "intel-gfx@lists.freedesktop.org" Date: Thu, 22 Apr 2010 19:19:01 +0100 Message-ID: <1271960341.13316.2.camel@pcjc2lap> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 Subject: [Intel-gfx] [PATCH] Graphics corruption issues X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces@lists.freedesktop.org Errors-To: intel-gfx-bounces@lists.freedesktop.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Thu, 22 Apr 2010 18:19:41 +0000 (UTC) From aadc0723ac9d36317a3f62ec08ad2fce78970090 Mon Sep 17 00:00:00 2001 From: Peter Clifton Date: Thu, 22 Apr 2010 19:01:13 +0100 Subject: [PATCH 2/2] i830: Use the i830_pixmap_pitch() helper function for clarity Signed-off-by: Peter Clifton --- src/i830_uxa.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/src/i830_uxa.c b/src/i830_uxa.c index 4f0c250..38c98fe 100644 --- a/src/i830_uxa.c +++ b/src/i830_uxa.c @@ -774,6 +774,7 @@ static Bool i830_uxa_put_image(PixmapPtr pixmap, struct intel_pixmap *priv; GCPtr gc; Bool ret; + int dst_pitch; if (x == 0 && y == 0 && w == pixmap->drawable.width && @@ -832,9 +833,11 @@ static Bool i830_uxa_put_image(PixmapPtr pixmap, return FALSE; } + dst_pitch = i830_pixmap_pitch(pixmap); + ret = pixman_blt((uint32_t *)src, priv->bo->virtual, src_pitch / sizeof(uint32_t), - pixmap->devKind / sizeof(uint32_t), + dst_pitch / sizeof(uint32_t), pixmap->drawable.bitsPerPixel, pixmap->drawable.bitsPerPixel, 0, 0, -- 1.7.0.4