[PATCH] x86/pci: make pci_mem_start to be aligned only

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Impact: make more big space below 4g for assigning to unassigned pci devices

don't need to reserved one round after the gapstart.

Reported-and-tested-by: Yannick <yannick.roehlly@xxxxxxx>
Signed-off-by: Yinghai Lu <yinghai@xxxxxxxxxx>

diff --git a/arch/x86/kernel/e820.c b/arch/x86/kernel/e820.c
index ef2c356..a0ba9b1 100644
--- a/arch/x86/kernel/e820.c
+++ b/arch/x86/kernel/e820.c
@@ -642,7 +642,7 @@ __init void e820_setup_gap(void)
 	while ((gapsize >> 4) > round)
 		round += round;
 	/* Fun with two's complement */
-	pci_mem_start = (gapstart + round) & -round;
+	pci_mem_start = roundup(gapstart, round);
 
 	printk(KERN_INFO
 	       "Allocating PCI resources starting at %lx (gap: %lx:%lx)\n",
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux