On Thu, Jun 17, 2010 at 08:03:12PM +0900, Isaku Yamahata wrote:
Make pci bar assigner preferchable memory aware. This is needed for PCI bridge support because memory space and prefetchable memory space is filtered independently based on memory base/limit and prefetchable memory base/limit of pci bridge. On bus 0, such a distinction isn't necessary so keep existing behavior by checking bus=0.
[...]
pci_bios_io_addr = 0xc000; pci_bios_mem_addr = BUILD_PCIMEM_START;
- /* pci_bios_mem_addr + <some value> */
- pci_bios_prefmem_addr = pci_bios_mem_addr + 0x08000000;
How can we be sure that the "mem" space doesn't overlap with the "prefmem" space?
-Kevin
On Mon, Jun 21, 2010 at 10:20:14PM -0400, Kevin O'Connor wrote:
On Thu, Jun 17, 2010 at 08:03:12PM +0900, Isaku Yamahata wrote:
Make pci bar assigner preferchable memory aware. This is needed for PCI bridge support because memory space and prefetchable memory space is filtered independently based on memory base/limit and prefetchable memory base/limit of pci bridge. On bus 0, such a distinction isn't necessary so keep existing behavior by checking bus=0.
[...]
pci_bios_io_addr = 0xc000; pci_bios_mem_addr = BUILD_PCIMEM_START;
- /* pci_bios_mem_addr + <some value> */
- pci_bios_prefmem_addr = pci_bios_mem_addr + 0x08000000;
How can we be sure that the "mem" space doesn't overlap with the "prefmem" space?
No check at the moment. Which way do you prefer?
- do nothing and pray that user wouldn't add so many devices. (current implementation) I chose this implementation because the existing code doesn't check whether mem area overlaps with around 4GB area which is used for other purpose.
- add overlap check. If mem area reaches to perfmem area, abandon further mapping with warning.
- Add one more path to scan pci bus to sum up size of mem and prefmem and calculate pci_bios_prefmem_addr more smartly. If mapping area is lacking, warn it and map them as possible as much.
- any better idea?
-Kevin
SeaBIOS mailing list SeaBIOS@seabios.org http://www.seabios.org/mailman/listinfo/seabios
On Tue, Jun 22, 2010 at 12:22:50PM +0900, Isaku Yamahata wrote:
On Mon, Jun 21, 2010 at 10:20:14PM -0400, Kevin O'Connor wrote:
How can we be sure that the "mem" space doesn't overlap with the "prefmem" space?
No check at the moment. Which way do you prefer?
do nothing and pray that user wouldn't add so many devices. (current implementation) I chose this implementation because the existing code doesn't check whether mem area overlaps with around 4GB area which is used for other purpose.
add overlap check. If mem area reaches to perfmem area, abandon further mapping with warning.
I'd probably go with "add overlap check". I could be convinced otherwise though.
-Kevin