Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752546Ab3EJBVz (ORCPT ); Thu, 9 May 2013 21:21:55 -0400 Received: from mail-ve0-f174.google.com ([209.85.128.174]:40536 "EHLO mail-ve0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751314Ab3EJBVy (ORCPT ); Thu, 9 May 2013 21:21:54 -0400 MIME-Version: 1.0 In-Reply-To: References: From: Andy Lutomirski Date: Thu, 9 May 2013 18:21:33 -0700 Message-ID: Subject: Re: [RFC/PATCH v2 0/8] Clean up write-combining MTRR addition To: Jerome Glisse Cc: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, Daniel Vetter , Alex Deucher , Dave Airlie Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1315 Lines: 32 On Thu, May 9, 2013 at 4:44 PM, Jerome Glisse wrote: > On Thu, May 9, 2013 at 3:46 PM, Andy Lutomirski wrote: >> A fair number of drivers (mostly graphics) add write-combining MTRRs. >> Most ignore errors and most add the MTRR even on PAT systems which don't >> need to use MTRRs. > > This comment is wrong, as i said we need MTRR on PAT system for VRAM. I didn't follow it last time. - If userspace is setting an MTRR directly, then it will work exactly as before -- this patch has no effect on the userspace MTRR APIs. - If userspace uses the drm map interface with DRM_FRAME_BUFFER or DRM_WRITE_COMBINING, there won't be an MTRR but the range will still be WC. - If userspace uses GEM or TTM, then everything should still use WC (TTM has explicit handling for this, which I presume is correct, and i915, the major GEM user, already doesn't set an MTRR). - If userspace does not map the range, then either the kernel driver is buggy or it doesn't matter because there's no map. Is there a case I've missed? --Andy -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/