Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
Yinghai Lu | 284f933 | 2010-02-10 01:20:12 -0800 | [diff] [blame] | 2 | #ifndef __BUS_NUMA_H |
| 3 | #define __BUS_NUMA_H |
Yinghai Lu | 99935a7 | 2009-10-04 21:54:24 -0700 | [diff] [blame] | 4 | /* |
| 5 | * sub bus (transparent) will use entres from 3 to store extra from |
Bjorn Helgaas | 2fe2abf | 2010-02-23 10:24:36 -0700 | [diff] [blame] | 6 | * root, so need to make sure we have enough slot there. |
Yinghai Lu | 99935a7 | 2009-10-04 21:54:24 -0700 | [diff] [blame] | 7 | */ |
Yinghai Lu | d28e5ac | 2012-04-02 18:31:54 -0700 | [diff] [blame] | 8 | struct pci_root_res { |
| 9 | struct list_head list; |
| 10 | struct resource res; |
| 11 | }; |
| 12 | |
Yinghai Lu | 99935a7 | 2009-10-04 21:54:24 -0700 | [diff] [blame] | 13 | struct pci_root_info { |
Yinghai Lu | d28e5ac | 2012-04-02 18:31:54 -0700 | [diff] [blame] | 14 | struct list_head list; |
Yinghai Lu | 99935a7 | 2009-10-04 21:54:24 -0700 | [diff] [blame] | 15 | char name[12]; |
Yinghai Lu | d28e5ac | 2012-04-02 18:31:54 -0700 | [diff] [blame] | 16 | struct list_head resources; |
Yinghai Lu | a10bb12 | 2012-05-17 18:51:12 -0700 | [diff] [blame] | 17 | struct resource busn; |
Yinghai Lu | 99935a7 | 2009-10-04 21:54:24 -0700 | [diff] [blame] | 18 | int node; |
| 19 | int link; |
| 20 | }; |
| 21 | |
Yinghai Lu | d28e5ac | 2012-04-02 18:31:54 -0700 | [diff] [blame] | 22 | extern struct list_head pci_root_infos; |
| 23 | struct pci_root_info *alloc_pci_root_info(int bus_min, int bus_max, |
| 24 | int node, int link); |
Yinghai Lu | b74fd23 | 2010-02-10 01:20:08 -0800 | [diff] [blame] | 25 | extern void update_res(struct pci_root_info *info, resource_size_t start, |
| 26 | resource_size_t end, unsigned long flags, int merge); |
Yinghai Lu | 99935a7 | 2009-10-04 21:54:24 -0700 | [diff] [blame] | 27 | #endif |