Loading...
1#ifndef __BUS_NUMA_H
2#define __BUS_NUMA_H
3/*
4 * sub bus (transparent) will use entres from 3 to store extra from
5 * root, so need to make sure we have enough slot there.
6 */
7#define RES_NUM 16
8struct pci_root_info {
9 char name[12];
10 unsigned int res_num;
11 struct resource res[RES_NUM];
12 int bus_min;
13 int bus_max;
14 int node;
15 int link;
16};
17
18/* 4 at this time, it may become to 32 */
19#define PCI_ROOT_NR 4
20extern int pci_root_num;
21extern struct pci_root_info pci_root_info[PCI_ROOT_NR];
22
23extern void update_res(struct pci_root_info *info, resource_size_t start,
24 resource_size_t end, unsigned long flags, int merge);
25#endif
1/* SPDX-License-Identifier: GPL-2.0 */
2#ifndef __BUS_NUMA_H
3#define __BUS_NUMA_H
4/*
5 * sub bus (transparent) will use entres from 3 to store extra from
6 * root, so need to make sure we have enough slot there.
7 */
8struct pci_root_res {
9 struct list_head list;
10 struct resource res;
11};
12
13struct pci_root_info {
14 struct list_head list;
15 char name[12];
16 struct list_head resources;
17 struct resource busn;
18 int node;
19 int link;
20};
21
22extern struct list_head pci_root_infos;
23struct pci_root_info *alloc_pci_root_info(int bus_min, int bus_max,
24 int node, int link);
25extern void update_res(struct pci_root_info *info, resource_size_t start,
26 resource_size_t end, unsigned long flags, int merge);
27#endif