From patchwork Wed Apr 13 20:48:48 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yinghai Lu X-Patchwork-Id: 705751 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p3DKpBxf019184 for ; Wed, 13 Apr 2011 20:51:31 GMT Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 26F5F9F398 for ; Wed, 13 Apr 2011 13:51:11 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from rcsinet10.oracle.com (rcsinet10.oracle.com [148.87.113.121]) by gabe.freedesktop.org (Postfix) with ESMTP id 0C6689F380 for ; Wed, 13 Apr 2011 13:50:23 -0700 (PDT) Received: from acsinet15.oracle.com (acsinet15.oracle.com [141.146.126.227]) by rcsinet10.oracle.com (Switch-3.4.2/Switch-3.4.2) with ESMTP id p3DKnwS0024921 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 13 Apr 2011 20:50:00 GMT Received: from acsmt357.oracle.com (acsmt357.oracle.com [141.146.40.157]) by acsinet15.oracle.com (Switch-3.4.2/Switch-3.4.1) with ESMTP id p3DKnu1r012362 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 13 Apr 2011 20:49:56 GMT Received: from abhmt009.oracle.com (abhmt009.oracle.com [141.146.116.18]) by acsmt357.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id p3DKmu8d015916; Wed, 13 Apr 2011 15:48:56 -0500 Received: from linux-siqj.site (/10.6.76.16) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 13 Apr 2011 13:48:55 -0700 Message-ID: <4DA60C30.4060606@kernel.org> Date: Wed, 13 Apr 2011 13:48:48 -0700 From: Yinghai Lu User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.14) Gecko/20110221 SUSE/3.1.8 Thunderbird/3.1.8 MIME-Version: 1.0 To: Joerg Roedel Subject: Re: Linux 2.6.39-rc3 References: <20110412090207.GE19819@8bytes.org> <20110412184433.GF19819@8bytes.org> <20110413064609.GA18777@elte.hu> <20110413172147.GI19819@8bytes.org> <4DA5F62F.3030504@kernel.org> <20110413193459.GL19819@8bytes.org> In-Reply-To: <20110413193459.GL19819@8bytes.org> X-Source-IP: acsmt357.oracle.com [141.146.40.157] X-Auth-Type: Internal IP X-CT-RefId: str=0001.0A090207.4DA60C75.0065,ss=1,fgs=0 Cc: Linux Kernel Mailing List , dri-devel@lists.freedesktop.org, Tejun Heo , "H. Peter Anvin" , Linus Torvalds , Thomas Gleixner X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Wed, 13 Apr 2011 20:51:31 +0000 (UTC) On 04/13/2011 12:34 PM, Joerg Roedel wrote: > On Wed, Apr 13, 2011 at 12:14:55PM -0700, Yinghai Lu wrote: >> thanks for the bisecting... >> >> so those two patches uncover some problems. >> >> [ 0.000000] Checking aperture... >> [ 0.000000] No AGP bridge found >> [ 0.000000] Node 0: aperture @ a0000000 size 32 MB >> [ 0.000000] Aperture pointing to e820 RAM. Ignoring. >> [ 0.000000] Your BIOS doesn't leave a aperture memory hole >> [ 0.000000] Please enable the IOMMU option in the BIOS setup >> [ 0.000000] This costs you 64 MB of RAM >> [ 0.000000] memblock_x86_reserve_range: [0xa0000000-0xa3ffffff] aperture64 >> [ 0.000000] Mapping aperture over 65536 KB of RAM @ a0000000 >> >> so kernel try to reallocate apperture. because BIOS allocated is pointed to RAM or size is too small. > > It is actually beyond 4GB on that machine, this value read here is from > the previous kernel-boot. The BIOS does not reset these values on a > reboot. > >> but your radeon does use [0xa0000000, 0xbfffffff) > > Yes, I suspected that too (and spent a few hours reading radeon code), > but then I talked the Alex Deucher and he explained that these addresses > which the driver prints for GTT and VRAM are in the GPU address space > and do not refer to system ram. So this shouldn't be the problem. can you try following change ? it will push gart to 0x80000000 diff --git a/arch/x86/kernel/aperture_64.c b/arch/x86/kernel/aperture_64.c index 86d1ad4..3b6a9d5 100644 --- a/arch/x86/kernel/aperture_64.c +++ b/arch/x86/kernel/aperture_64.c @@ -83,7 +83,7 @@ static u32 __init allocate_aperture(void) * so don't use 512M below as gart iommu, leave the space for kernel * code for safe */ - addr = memblock_find_in_range(0, 1ULL<<32, aper_size, 512ULL<<20); + addr = memblock_find_in_range(0, 1ULL<<32, aper_size, 512ULL<<21); if (addr == MEMBLOCK_ERROR || addr + aper_size > 0xffffffff) { printk(KERN_ERR "Cannot allocate aperture memory hole (%lx,%uK)\n",