1 /* SPDX-License-Identifier: GPL-2.0+ */
2 /*
3  * Copyright (C) 2015, Bin Meng <bmeng.cn@gmail.com>
4  */
5 
6 #ifndef _QUEENSBAY_DEVICE_H_
7 #define _QUEENSBAY_DEVICE_H_
8 
9 #include <pci.h>
10 
11 /* TunnelCreek PCI Devices */
12 #define TNC_HOST_BRIDGE_DEV	0
13 #define TNC_HOST_BRIDGE_FUNC	0
14 #define TNC_IGD_DEV		2
15 #define TNC_IGD_FUNC		0
16 #define TNC_SDVO_DEV		3
17 #define TNC_SDVO_FUNC		0
18 #define TNC_PCIE0_DEV		23
19 #define TNC_PCIE0_FUNC		0
20 #define TNC_PCIE1_DEV		24
21 #define TNC_PCIE1_FUNC		0
22 #define TNC_PCIE2_DEV		25
23 #define TNC_PCIE2_FUNC		0
24 #define TNC_PCIE3_DEV		26
25 #define TNC_PCIE3_FUNC		0
26 #define TNC_HDA_DEV		27
27 #define TNC_HDA_FUNC		0
28 #define TNC_LPC_DEV		31
29 #define TNC_LPC_FUNC		0
30 
31 #define TNC_HOST_BRIDGE		\
32 	PCI_BDF(0, TNC_HOST_BRIDGE_DEV, TNC_HOST_BRIDGE_FUNC)
33 #define TNC_IGD			\
34 	PCI_BDF(0, TNC_IGD_DEV, TNC_IGD_FUNC)
35 #define TNC_SDVO		\
36 	PCI_BDF(0, TNC_SDVO_DEV, TNC_SDVO_FUNC)
37 #define TNC_PCIE0		\
38 	PCI_BDF(0, TNC_PCIE0_DEV, TNC_PCIE0_FUNC)
39 #define TNC_PCIE1		\
40 	PCI_BDF(0, TNC_PCIE1_DEV, TNC_PCIE1_FUNC)
41 #define TNC_PCIE2		\
42 	PCI_BDF(0, TNC_PCIE2_DEV, TNC_PCIE2_FUNC)
43 #define TNC_PCIE3		\
44 	PCI_BDF(0, TNC_PCIE3_DEV, TNC_PCIE3_FUNC)
45 #define TNC_HDA			\
46 	PCI_BDF(0, TNC_HDA_DEV, TNC_HDA_FUNC)
47 #define TNC_LPC			\
48 	PCI_BDF(0, TNC_LPC_DEV, TNC_LPC_FUNC)
49 
50 /* Topcliff IOH PCI Devices */
51 #define TCF_PCIE_PORT_DEV	0
52 #define TCF_PCIE_PORT_FUNC	0
53 
54 #define TCF_DEV_0		0
55 #define TCF_PKT_HUB_FUNC	0
56 #define TCF_GBE_FUNC		1
57 #define TCF_GPIO_FUNC		2
58 
59 #define TCF_DEV_2		2
60 #define TCF_USB1_OHCI0_FUNC	0
61 #define TCF_USB1_OHCI1_FUNC	1
62 #define TCF_USB1_OHCI2_FUNC	2
63 #define TCF_USB1_EHCI_FUNC	3
64 #define TCF_USB_DEVICE_FUNC	4
65 
66 #define TCF_DEV_4		4
67 #define TCF_SDIO0_FUNC		0
68 #define TCF_SDIO1_FUNC		1
69 
70 #define TCF_DEV_6		6
71 #define TCF_SATA_FUNC		0
72 
73 #define TCF_DEV_8		8
74 #define TCF_USB2_OHCI0_FUNC	0
75 #define TCF_USB2_OHCI1_FUNC	1
76 #define TCF_USB2_OHCI2_FUNC	2
77 #define TCF_USB2_EHCI_FUNC	3
78 
79 #define TCF_DEV_10		10
80 #define TCF_DMA1_FUNC		0
81 #define TCF_UART0_FUNC		1
82 #define TCF_UART1_FUNC		2
83 #define TCF_UART2_FUNC		3
84 #define TCF_UART3_FUNC		4
85 
86 #define TCF_DEV_12		12
87 #define TCF_DMA2_FUNC		0
88 #define TCF_SPI_FUNC		1
89 #define TCF_I2C_FUNC		2
90 #define TCF_CAN_FUNC		3
91 #define TCF_1588_FUNC		4
92 
93 #endif /* _QUEENSBAY_DEVICE_H_ */
94