switch-coreboot/include
Myles Watson 0fb2a8f081 This patch simplifies the resource allocator by splitting it into distinct
phases.  One benefit of this is that it makes the call chain easier to follow.

device/device.c:
	Remove references to have_resources.
	Remove read_resources from compute allocate resources.
	Split compute_allocate_resources into two
	1. compute_resource_needs
		A. Traverse the tree depth first
		B. Sum resources
		C. Adjust limits and bases
		D. Update bridge resources sizes
	2. assign_resource_values
		A. Traverse the tree breadth first
		B. Assign resource values

device/device_util.c:
	Remove references to have_resources.

device/pci_device.c:
	Remove saved values stubs (they're not needed now.)
		1. Sizing function restores values
	Fix 64-bit flag masking.
	Add an error message for an invalid value.
	Update pci_record_bridge_resource:
		1. remove compute_allocate_resource call
		2. remove pci_set_resource call
	Update pci_bus_read_resources to read children's too.
	Update pci_set_resource:
		1. change logic for setting zero-size resources
			A. Set range to [limit->limit-2^gran]
				(Could have been any range with base > limit)
		2. remove compute_allocate_resource calls
		3. Change phase4_assign_resources ->phase4_set_resources

device/pci_ops.c:
	Change an error message to be more helpful.

device/root_device.c:
	Remove code for read_resources and set resources.
	Add a .id to the ops.

include/device/device.h:
	Remove have_resources.
	Comment out assign_resources.  I think we could comment out more here.
	Add debugging function prototypes.
	Change phase4_assign_resources to phase4_set_resources.

include/device/resource.h
	Add a IORESOURCE_BRIDGE flag.

device/cardbus_device.c
	Remove compute_allocate_resource call.
	Use probe_resource (doesn't die) instead of find_resource.

Signed-off-by: Myles Watson <mylesgw@gmail.com>
Acked-by: Ronald G. Minnich <rminnich@gmail.com>



git-svn-id: svn://coreboot.org/repository/coreboot-v3@1089 f3766cd6-281f-0410-b1cd-43a5c92072e9
2008-12-31 19:43:34 +00:00
..
arch/x86 Fix breakage of k8 targets caused by r1085. Thanks to Myles Watson for 2008-12-30 07:02:52 +00:00
device This patch simplifies the resource allocator by splitting it into distinct 2008-12-31 19:43:34 +00:00
console.h Fixes to make k8 and others work. 2008-08-27 22:43:18 +00:00
elf.h Now version 3: LinuxBIOS -> coreboot rename. 2008-01-27 18:54:57 +00:00
elf_boot.h Use the same naming convention and placement for "include guards" in 2007-05-21 06:48:47 +00:00
globalvars.h We are woefully unaware about how much stack v3 really uses. 2008-11-13 01:28:32 +00:00
ip_checksum.h Now version 3: LinuxBIOS -> coreboot rename. 2008-01-27 18:54:57 +00:00
isa-dma.h Now version 3: LinuxBIOS -> coreboot rename. 2008-01-27 18:54:57 +00:00
keyboard.h Now version 3: LinuxBIOS -> coreboot rename. 2008-01-27 18:54:57 +00:00
lar.h The ABI wrapper from r775 made the SHARED definitions obsolete. They're 2008-08-17 21:51:13 +00:00
lib.h Return the count of failures from ram_check. 2008-11-13 17:04:11 +00:00
mc146818rtc.h The ABI wrapper from r775 made the SHARED definitions obsolete. They're 2008-08-17 21:51:13 +00:00
post_code.h The ABI wrapper from r775 made the SHARED definitions obsolete. They're 2008-08-17 21:51:13 +00:00
shared.h The ABI wrapper from r775 made the SHARED definitions obsolete. They're 2008-08-17 21:51:13 +00:00
spd.h Commit a few things I forgot with the vt8237 patch, and also a couple 2008-10-15 06:41:16 +00:00
spd_ddr2.h remaining fixes for log2. Simple prototype added to spd_ddr2.h 2008-08-31 20:39:48 +00:00
spinlock.h Remove superfluous checks for boolean CONFIG_* variables where we tested 2008-02-14 22:34:40 +00:00
string.h The ABI wrapper from r775 made the SHARED definitions obsolete. They're 2008-08-17 21:51:13 +00:00
tables.h the multiboot map is generated too early in 2008-10-17 22:49:43 +00:00
uart8250.h Use the same naming convention and placement for "include guards" in 2007-05-21 06:48:47 +00:00