From patchwork Fri Sep 11 06:34:14 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Brice Goglin X-Patchwork-Id: 46811 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n8B71jIw008697 for ; Fri, 11 Sep 2009 07:01:45 GMT Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id B04759E79C; Fri, 11 Sep 2009 00:01:44 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org X-Greylist: delayed 601 seconds by postgrey-1.30 at gabe; Fri, 11 Sep 2009 00:01:42 PDT Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by gabe.freedesktop.org (Postfix) with ESMTP id 1D8209E760 for ; Fri, 11 Sep 2009 00:01:42 -0700 (PDT) X-IronPort-AV: E=Sophos;i="4.44,369,1249250400"; d="scan'208";a="32570751" Received: from maison.loulous.org (HELO [192.168.44.23]) ([82.230.112.130]) by mail2-relais-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-SHA; 11 Sep 2009 08:51:40 +0200 Resent-From: Brice Goglin Resent-To: intel-gfx@lists.freedesktop.org Resent-Date: Fri, 11 Sep 2009 08:51:17 +0200 Resent-Message-Id: <4AA9F365.8020506@gmail.com> Resent-User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.22) Gecko/20090706 Thunderbird/2.0.0.22 Message-ID: <4AA9EF66.4030501@ens-lyon.org> Date: Fri, 11 Sep 2009 08:34:14 +0200 From: Brice Goglin User-Agent: Mozilla-Thunderbird 2.0.0.22 (X11/20090706) MIME-Version: 1.0 To: Eric Anholt References: <1252640753-6306-1-git-send-email-eric@anholt.net> In-Reply-To: <1252640753-6306-1-git-send-email-eric@anholt.net> X-Enigmail-Version: 0.95.0 Cc: intel-gfx@lists.freedesktop.org, stable@kernel.org Subject: Re: [Intel-gfx] [PATCH] agp/intel: Fix the pre-9xx chipset flush. X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.9 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 Eric Anholt wrote: > The chipset flush was on the right track -- hitting the right amount of > memory, and it appears to be the only way to flush on these chipsets, but the > flush page was mapped uncached. As a result, the writes trying to clear the > writeback cache ended up bypassing the cache, and not flushing anything! The > wbinvd would flush out other writeback data and often cause the data we wanted > to get flushed, but not always. By removing the setting of the page to UC > and instead just clflushing the data we write to try to flush it, we get the > desired behavior with no wbinvd. > This helps a lot, thanks Eric. I've been running various things under metacity and compiz during the last 10mn without problems while X would usually hang after 10s. But I needed the below patch to build the intel-agp driver as a module. Signed-off-by: Brice Goglin Index: linux-2.6.31/arch/x86/mm/pageattr.c =================================================================== --- linux-2.6.31.orig/arch/x86/mm/pageattr.c 2009-09-11 08:02:14.000000000 +0200 +++ linux-2.6.31/arch/x86/mm/pageattr.c 2009-09-11 08:02:48.000000000 +0200 @@ -143,6 +143,7 @@ mb(); } +EXPORT_SYMBOL_GPL(clflush_cache_range); static void __cpa_flush_all(void *arg) {