diff options
author | Srikant Patnaik | 2015-01-11 12:28:04 +0530 |
---|---|---|
committer | Srikant Patnaik | 2015-01-11 12:28:04 +0530 |
commit | 871480933a1c28f8a9fed4c4d34d06c439a7a422 (patch) | |
tree | 8718f573808810c2a1e8cb8fb6ac469093ca2784 /ANDROID_3.4.5/arch/x86/pci/bus_numa.c | |
parent | 9d40ac5867b9aefe0722bc1f110b965ff294d30d (diff) | |
download | FOSSEE-netbook-kernel-source-871480933a1c28f8a9fed4c4d34d06c439a7a422.tar.gz FOSSEE-netbook-kernel-source-871480933a1c28f8a9fed4c4d34d06c439a7a422.tar.bz2 FOSSEE-netbook-kernel-source-871480933a1c28f8a9fed4c4d34d06c439a7a422.zip |
Moved, renamed, and deleted files
The original directory structure was scattered and unorganized.
Changes are basically to make it look like kernel structure.
Diffstat (limited to 'ANDROID_3.4.5/arch/x86/pci/bus_numa.c')
-rw-r--r-- | ANDROID_3.4.5/arch/x86/pci/bus_numa.c | 106 |
1 files changed, 0 insertions, 106 deletions
diff --git a/ANDROID_3.4.5/arch/x86/pci/bus_numa.c b/ANDROID_3.4.5/arch/x86/pci/bus_numa.c deleted file mode 100644 index fd3f6551..00000000 --- a/ANDROID_3.4.5/arch/x86/pci/bus_numa.c +++ /dev/null @@ -1,106 +0,0 @@ -#include <linux/init.h> -#include <linux/pci.h> -#include <linux/range.h> - -#include "bus_numa.h" - -int pci_root_num; -struct pci_root_info pci_root_info[PCI_ROOT_NR]; - -void x86_pci_root_bus_resources(int bus, struct list_head *resources) -{ - int i; - int j; - struct pci_root_info *info; - - if (!pci_root_num) - goto default_resources; - - for (i = 0; i < pci_root_num; i++) { - if (pci_root_info[i].bus_min == bus) - break; - } - - if (i == pci_root_num) - goto default_resources; - - printk(KERN_DEBUG "PCI: root bus %02x: hardware-probed resources\n", - bus); - - info = &pci_root_info[i]; - for (j = 0; j < info->res_num; j++) { - struct resource *res; - struct resource *root; - - res = &info->res[j]; - pci_add_resource(resources, res); - if (res->flags & IORESOURCE_IO) - root = &ioport_resource; - else - root = &iomem_resource; - insert_resource(root, res); - } - return; - -default_resources: - /* - * We don't have any host bridge aperture information from the - * "native host bridge drivers," e.g., amd_bus or broadcom_bus, - * so fall back to the defaults historically used by pci_create_bus(). - */ - printk(KERN_DEBUG "PCI: root bus %02x: using default resources\n", bus); - pci_add_resource(resources, &ioport_resource); - pci_add_resource(resources, &iomem_resource); -} - -void __devinit update_res(struct pci_root_info *info, resource_size_t start, - resource_size_t end, unsigned long flags, int merge) -{ - int i; - struct resource *res; - - if (start > end) - return; - - if (start == MAX_RESOURCE) - return; - - if (!merge) - goto addit; - - /* try to merge it with old one */ - for (i = 0; i < info->res_num; i++) { - resource_size_t final_start, final_end; - resource_size_t common_start, common_end; - - res = &info->res[i]; - if (res->flags != flags) - continue; - - common_start = max(res->start, start); - common_end = min(res->end, end); - if (common_start > common_end + 1) - continue; - - final_start = min(res->start, start); - final_end = max(res->end, end); - - res->start = final_start; - res->end = final_end; - return; - } - -addit: - - /* need to add that */ - if (info->res_num >= RES_NUM) - return; - - res = &info->res[info->res_num]; - res->name = info->name; - res->flags = flags; - res->start = start; - res->end = end; - res->child = NULL; - info->res_num++; -} |