Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758341Ab0LCBTo (ORCPT ); Thu, 2 Dec 2010 20:19:44 -0500 Received: from smtp1.linux-foundation.org ([140.211.169.13]:49150 "EHLO smtp1.linux-foundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758120Ab0LCBTn convert rfc822-to-8bit (ORCPT ); Thu, 2 Dec 2010 20:19:43 -0500 MIME-Version: 1.0 In-Reply-To: <201011291504.40536.bjorn.helgaas@hp.com> References: <20101129183009.11256.33739.stgit@bob.kio> <201011291432.51264.bjorn.helgaas@hp.com> <4CF41C89.9060708@zytor.com> <201011291504.40536.bjorn.helgaas@hp.com> From: Linus Torvalds Date: Thu, 2 Dec 2010 17:19:20 -0800 Message-ID: Subject: Re: [PATCH] x86/PCI: never allocate PCI space from the last 1M below 4G To: Bjorn Helgaas Cc: "H. Peter Anvin" , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, Jesse Barnes , Thomas Gleixner , Ingo Molnar , Matthew Garrett Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1640 Lines: 44 On Mon, Nov 29, 2010 at 2:04 PM, Bjorn Helgaas wrote: > > I think we're talking about whether to reserve the top 1MB or top 2MB. > I freely admit I don't know the right answer. ?My point is merely that > since we're using a heuristic anyway, copying Windows is a pretty good > starting point. ?In my mind, doing something different requires a > stronger argument than "it might fix some machines where Windows is > broken." What's the status of this? The original patch is pretty nasty, and I think that hack to put things in the bios_align_resource() function is just disgusting. And why is the fix not the really _trivial_ one, which does just this: diff --git a/arch/x86/include/asm/pci.h b/arch/x86/include/asm/pci.h index ca0437c..aef9f77 100644 --- a/arch/x86/include/asm/pci.h +++ b/arch/x86/include/asm/pci.h @@ -141,7 +141,7 @@ void dma32_reserve_bootmem(void); /* generic pci stuff */ #include -#define PCIBIOS_MAX_MEM_32 0xffffffff +#define PCIBIOS_MAX_MEM_32 0xfff00000 #ifdef CONFIG_NUMA /* Returns the node based on pci bus */ Hmm? (Ok, so that doesn't protect a 64-bit resource that just happens to be inside a window that ends at 0xffffffff, but if you have those kinds of bus windows, that means that there's nothing there at the 4GB mark anyway, no?) Linus Linus -- 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/