Lines Matching +full:endpoint +full:- +full:config

1 .. SPDX-License-Identifier: GPL-2.0
9 PCI Non-Transparent Bridges (NTB) allow two host systems to communicate
17 with each other by configuring the endpoint instances in such a way that
21 PCI Endpoint (EP) instances in such a way that transactions from one EP
26 .. code-block:: text
28 +-------------+ +-------------+
32 +------^------+ +------^------+
35 +---------|-------------------------------------------------|---------+
36 | +------v------+ +------v------+ |
40 | | <-----------------------------------> | |
45 | +-------------+ +-------------+ |
46 +---------------------------------------------------------------------+
51 1) Config Region
58 Config Region:
59 --------------
61 Config Region is a construct that is specific to NTB implemented using NTB
62 Endpoint Function Driver. The host and endpoint side NTB function driver will
63 exchange information with each other using this region. Config Region has
64 Control/Status Registers for configuring the Endpoint Controller. Host can
66 (ATU) and to indicate the link status. Endpoint can indicate the status of
67 commands issued by host in this region. Endpoint can also indicate the
70 The format of Config Region is given below. All the fields here are 32 bits.
72 .. code-block:: text
74 +------------------------+
76 +------------------------+
78 +------------------------+
80 +------------------------+
82 +------------------------+
84 +------------------------+
86 +------------------------+
88 +------------------------+
90 +------------------------+
92 +------------------------+
94 +------------------------+
96 +------------------------+
98 +------------------------+
100 +------------------------+
102 +------------------------+
104 +------------------------+
106 +------------------------+
115 MSI/MSI-X vectors (i.e., initialize the MSI/MSI-X Capability in the
116 Endpoint). The endpoint on receiving this command will configure
118 to the MSI/MSI-X address programmed by the host. The ARGUMENT
120 lower 16 bits) and if MSI or MSI-X should be configured (BIT 16).
127 in the ARGUMENT register. The endpoint on receiving this command
132 bound to the EP device on the host side. Once the endpoint
133 receives this command from both the hosts, the endpoint will
165 Self scratchpad region and config region are packed together in the
166 same BAR. The initial portion of the region will have config region
178 in order to raise doorbell. EPF NTB can use either MSI or MSI-X to
179 ring doorbell (MSI-X support will be added later). MSI uses same
180 address for all the interrupts and MSI-X can provide different
181 addresses for different interrupts. The MSI/MSI-X address is provided
182 by the host and the address it gives is based on the MSI/MSI-X
184 using GIC ITS will have the same MSI-X address for all the interrupts.
186 for both MSI and MSI-X, EPF NTB allocates a separate region in the
188 be mapped to the MSI/MSI-X address provided by the host. If a host
197 This holds the MSI/MSI-X data that has to be written to MSI address
202 ---------------------
204 Each host has its own register space allocated in the memory of NTB endpoint
214 -------------------
219 --------------
227 There are 5 or more distinct regions (config, self scratchpad, peer
233 If one 32-bit BAR is allocated for each of these regions, the scheme would
239 BAR0 Config Region
248 be enough BARs for all the regions in a platform that supports only 64-bit
261 BAR0 Config Region + Self Scratchpad
271 Modeling Config/Scratchpad Region:
272 ----------------------------------
274 .. code-block:: text
276 +-----------------+------->+------------------+ +-----------------+
277 | BAR0 | | CONFIG REGION | | BAR0 |
278 +-----------------+----+ +------------------+<-------+-----------------+
280 +-----------------+ +-->+------------------+<-------+-----------------+
282 +-----------------+ +-----------------+
284 +-----------------+ +-----------------+
286 +-----------------+ +-----------------+
288 +-----------------+ +-----------------+
291 Above diagram shows Config region + Scratchpad region for HOST1 (connected to
292 EP controller 1) allocated in local memory. The HOST1 can access the config
296 diagram shows the case where Config region and Scratchpad regions are allocated
300 ----------------------------------
302 .. code-block:: text
304 +-----------------+ +----->+----------------+-----------+-----------------+
305 | BAR0 | | | Doorbell 1 +-----------> MSI-X ADDRESS 1 |
306 +-----------------+ | +----------------+ +-----------------+
307 | BAR1 | | | Doorbell 2 +---------+ | |
308 +-----------------+----+ +----------------+ | | |
309 | BAR2 | | Doorbell 3 +-------+ | +-----------------+
310 +-----------------+----+ +----------------+ | +-> MSI-X ADDRESS 2 |
311 | BAR3 | | | Doorbell 4 +-----+ | +-----------------+
312 +-----------------+ | |----------------+ | | | |
313 | BAR4 | | | | | | +-----------------+
314 +-----------------+ | | MW1 +---+ | +-->+ MSI-X ADDRESS 3||
315 | BAR5 | | | | | | +-----------------+
316 +-----------------+ +----->-----------------+ | | | |
317 EP CONTROLLER 1 | | | | +-----------------+
318 | | | +---->+ MSI-X ADDRESS 4 |
319 +----------------+ | +-----------------+
322 +-------> MW1 |
325 +-----------------+
331 +-----------------+
340 is done during the initialization phase of NTB endpoint function driver.
345 ---------------------------------