[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-5d423ccd7ba4285f1084e91b26805e1d0ae978ed@git.kernel.org>
Date: Mon, 11 May 2009 09:51:57 GMT
From: tip-bot for Yinghai Lu <yinghai@...nel.org>
To: linux-tip-commits@...r.kernel.org
Cc: linux-kernel@...r.kernel.org, hpa@...or.com, mingo@...hat.com,
yinghai@...nel.org, torvalds@...ux-foundation.org,
jesse.barnes@...el.com, yannick.roehlly@...e.fr,
akpm@...ux-foundation.org, ink@...assic.park.msu.ru,
tglx@...utronix.de, mingo@...e.hu
Subject: [tip:x86/mm] x86/pci: remove rounding quirk from e820_setup_gap()
Commit-ID: 5d423ccd7ba4285f1084e91b26805e1d0ae978ed
Gitweb: http://git.kernel.org/tip/5d423ccd7ba4285f1084e91b26805e1d0ae978ed
Author: Yinghai Lu <yinghai@...nel.org>
AuthorDate: Wed, 6 May 2009 08:07:52 -0700
Committer: Ingo Molnar <mingo@...e.hu>
CommitDate: Mon, 11 May 2009 09:45:14 +0200
x86/pci: remove rounding quirk from e820_setup_gap()
Now that the e820 code explicitly reserves 'potentially dangerous'
free physical memory address space to protect ACPI stolen RAM,
there's no need for the rounding quirk in the PCI allocator anymore.
Also, this quirk was open-ended iteration that could end up reserving
a lot of free space and potentially breaking drivers - such as the one
reported by Yannick Roehlly <yannick.roehlly@...e.fr> where there's
a PCI device with a large memory resource.
So remove it.
[ Impact: make more of the PCI hole available for assigning pci devices ]
Reported-by: Yannick Roehlly <yannick.roehlly@...e.fr>
Signed-off-by: Yinghai Lu <yinghai@...nel.org>
Acked-by: Jesse Barnes <jesse.barnes@...el.com>
Cc: Ivan Kokshaysky <ink@...assic.park.msu.ru>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>
LKML-Reference: <4A01A7C8.5090701@...nel.org>
Signed-off-by: Ingo Molnar <mingo@...e.hu>
---
arch/x86/kernel/e820.c | 11 +++--------
1 files changed, 3 insertions(+), 8 deletions(-)
diff --git a/arch/x86/kernel/e820.c b/arch/x86/kernel/e820.c
index a2335d9..7271fa3 100644
--- a/arch/x86/kernel/e820.c
+++ b/arch/x86/kernel/e820.c
@@ -617,7 +617,7 @@ __init int e820_search_gap(unsigned long *gapstart, unsigned long *gapsize,
*/
__init void e820_setup_gap(void)
{
- unsigned long gapstart, gapsize, round;
+ unsigned long gapstart, gapsize;
int found;
gapstart = 0x10000000;
@@ -635,14 +635,9 @@ __init void e820_setup_gap(void)
#endif
/*
- * See how much we want to round up: start off with
- * rounding to the next 1MB area.
+ * e820_reserve_resources_late protect stolen RAM already
*/
- round = 0x100000;
- while ((gapsize >> 4) > round)
- round += round;
- /* Fun with two's complement */
- pci_mem_start = (gapstart + round) & -round;
+ pci_mem_start = gapstart;
printk(KERN_INFO
"Allocating PCI resources starting at %lx (gap: %lx:%lx)\n",
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists