From owner-freebsd-current@freebsd.org Tue Aug 14 13:55:39 2018 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A980A1078AC9 for ; Tue, 14 Aug 2018 13:55:39 +0000 (UTC) (envelope-from eric@vangyzen.net) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [199.48.133.146]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 590C08FA89 for ; Tue, 14 Aug 2018 13:55:39 +0000 (UTC) (envelope-from eric@vangyzen.net) Received: from hammy.vangyzen.net (unknown [147.178.0.137]) by smtp.vangyzen.net (Postfix) with ESMTPSA id 9461C5646E for ; Tue, 14 Aug 2018 08:55:37 -0500 (CDT) Subject: Re: Make drm drivers use MTRR write-combine To: freebsd-current@freebsd.org References: From: Eric van Gyzen Message-ID: <3b53edb8-e1d2-109f-6ec7-81513c513433@vangyzen.net> Date: Tue, 14 Aug 2018 08:55:36 -0500 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:60.0) Gecko/20100101 Thunderbird/60.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Aug 2018 13:55:39 -0000 On 8/14/18 4:12 AM, Johannes Lundberg wrote: > Hi > > Something that we have seen for a long time on FreeBSD is the boot message > > Failed to add WC MTRR for [0xd0000000-0xdfffffff]: -22; performance may > suffer > > Taking a closer look at this with memcontrol I can see that the 256 MB > region that DRM wants to set as WC is already covered by this entry > 0xc0000000/0x40000000 BIOS uncacheable set-by-firmware active > > Similar on both my Skylake and Broadwell systems. I see something similar on my Dell XPS 13 with a Kaby Lake R: Failed to add WC MTRR for [0x90000000-0x9fffffff]: -22; performance may suffer 0x80000000/0x80000000 BIOS uncacheable set-by-firmware active The only mappings in this range are MMIO: machdep.efi_map: Type Physical Virtual #Pages Attr [snip] MemoryMappedIO 0000e0000000 0xe0000000 00010000 RUNTIME MemoryMappedIO 0000fe000000 0xfe000000 00000011 UC RUNTIME MemoryMappedIO 0000fec00000 0xfec00000 00000001 UC RUNTIME MemoryMappedIO 0000fee00000 0xfee00000 00000001 UC WT WB WP RUNTIME MemoryMappedIO 0000ff000000 0xff000000 00001000 UC WT WB WP RUNTIME Eric