€•TŒsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ//translations/zh_CN/PCI/endpoint/pci-vntb-howto”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/zh_TW/PCI/endpoint/pci-vntb-howto”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/it_IT/PCI/endpoint/pci-vntb-howto”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/ja_JP/PCI/endpoint/pci-vntb-howto”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/ko_KR/PCI/endpoint/pci-vntb-howto”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ//translations/sp_SP/PCI/endpoint/pci-vntb-howto”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒcomment”“”)”}”(hŒ SPDX-License-Identifier: GPL-2.0”h]”hŒ SPDX-License-Identifier: GPL-2.0”…””}”hh£sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1h¡hhhžhhŸŒI/var/lib/git/docbuild/linux/Documentation/PCI/endpoint/pci-vntb-howto.rst”h KubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒCPCI Non-Transparent Bridge (NTB) Endpoint Function (EPF) User Guide”h]”hŒCPCI Non-Transparent Bridge (NTB) Endpoint Function (EPF) User Guide”…””}”(hh»hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hh¶hžhhŸh³h KubhŒ field_list”“”)”}”(hhh]”hŒfield”“”)”}”(hhh]”(hŒ field_name”“”)”}”(hŒAuthor”h]”hŒAuthor”…””}”(hhÕhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÓhhÐhŸh³h KubhŒ field_body”“”)”}”(hŒFrank Li ”h]”hŒ paragraph”“”)”}”(hŒFrank Li ”h]”(hŒ Frank Li <”…””}”(hhëhžhhŸNh NubhŒ reference”“”)”}”(hŒFrank.Li@nxp.com”h]”hŒFrank.Li@nxp.com”…””}”(hhõhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œmailto:Frank.Li@nxp.com”uh1hóhhëubhŒ>”…””}”(hhëhžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h Khhåubah}”(h]”h ]”h"]”h$]”h&]”uh1hãhhÐubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÎhŸh³h KhhËhžhubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhh¶hžhhŸh³h Kubhê)”}”(hXMThis document is a guide to help users use pci-epf-vntb function driver and ntb_hw_epf host driver for NTB functionality. The list of steps to be followed in the host side and EP side is given below. For the hardware configuration and internals of NTB using configurable endpoints see Documentation/PCI/endpoint/pci-vntb-function.rst”h]”hXMThis document is a guide to help users use pci-epf-vntb function driver and ntb_hw_epf host driver for NTB functionality. The list of steps to be followed in the host side and EP side is given below. For the hardware configuration and internals of NTB using configurable endpoints see Documentation/PCI/endpoint/pci-vntb-function.rst”…””}”(hj!hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h K hh¶hžhubhµ)”}”(hhh]”(hº)”}”(hŒEndpoint Device”h]”hŒEndpoint Device”…””}”(hj2hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj/hžhhŸh³h Kubhµ)”}”(hhh]”(hº)”}”(hŒEndpoint Controller Devices”h]”hŒEndpoint Controller Devices”…””}”(hjChžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj@hžhhŸh³h Kubhê)”}”(hŒ?To find the list of endpoint controller devices in the system::”h]”hŒ>To find the list of endpoint controller devices in the system:”…””}”(hjQhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h Khj@hžhubhŒ literal_block”“”)”}”(hŒ+# ls /sys/class/pci_epc/ 5f010000.pcie_ep”h]”hŒ+# ls /sys/class/pci_epc/ 5f010000.pcie_ep”…””}”hjasbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h Khj@hžhubhê)”}”(hŒ%If PCI_ENDPOINT_CONFIGFS is enabled::”h]”hŒ$If PCI_ENDPOINT_CONFIGFS is enabled:”…””}”(hjohžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h Khj@hžhubj`)”}”(hŒ=# ls /sys/kernel/config/pci_ep/controllers 5f010000.pcie_ep”h]”hŒ=# ls /sys/kernel/config/pci_ep/controllers 5f010000.pcie_ep”…””}”hj}sbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h Khj@hžhubeh}”(h]”Œendpoint-controller-devices”ah ]”h"]”Œendpoint controller devices”ah$]”h&]”uh1h´hj/hžhhŸh³h Kubhµ)”}”(hhh]”(hº)”}”(hŒEndpoint Function Drivers”h]”hŒEndpoint Function Drivers”…””}”(hj–hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj“hžhhŸh³h K ubhê)”}”(hŒ=To find the list of endpoint function drivers in the system::”h]”hŒ functions/pci_epf_vntb/func1/vendorid # echo 0x0809 > functions/pci_epf_vntb/func1/deviceid”h]”hŒk# echo 0x1957 > functions/pci_epf_vntb/func1/vendorid # echo 0x0809 > functions/pci_epf_vntb/func1/deviceid”…””}”hj~sbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h KThj_hžhubhê)”}”(hXThe PCI endpoint framework also automatically creates a sub-directory in the function attribute directory. This sub-directory has the same name as the name of the function device and is populated with the following NTB specific attributes that can be configured by the user::”h]”hXThe PCI endpoint framework also automatically creates a sub-directory in the function attribute directory. This sub-directory has the same name as the name of the function device and is populated with the following NTB specific attributes that can be configured by the user:”…””}”(hjŒhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h KWhj_hžhubj`)”}”(hŒ€# ls functions/pci_epf_vntb/func1/pci_epf_vntb.0/ db_count mw1 mw2 mw3 mw4 num_mws spad_count”h]”hŒ€# ls functions/pci_epf_vntb/func1/pci_epf_vntb.0/ db_count mw1 mw2 mw3 mw4 num_mws spad_count”…””}”hjšsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h K\hj_hžhubhê)”}”(hŒ8A sample configuration for NTB function is given below::”h]”hŒ7A sample configuration for NTB function is given below:”…””}”(hj¨hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h K`hj_hžhubj`)”}”(hX# echo 4 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/db_count # echo 128 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/spad_count # echo 1 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/num_mws # echo 0x100000 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/mw1”h]”hX# echo 4 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/db_count # echo 128 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/spad_count # echo 1 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/num_mws # echo 0x100000 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/mw1”…””}”hj¶sbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h Kbhj_hžhubhê)”}”(hŒCA sample configuration for virtual NTB driver for virtual PCI bus::”h]”hŒBA sample configuration for virtual NTB driver for virtual PCI bus:”…””}”(hjÄhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h Kghj_hžhubj`)”}”(hŒÏ# echo 0x1957 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/vntb_vid # echo 0x080A > functions/pci_epf_vntb/func1/pci_epf_vntb.0/vntb_pid # echo 0x10 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/vbus_number”h]”hŒÏ# echo 0x1957 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/vntb_vid # echo 0x080A > functions/pci_epf_vntb/func1/pci_epf_vntb.0/vntb_pid # echo 0x10 > functions/pci_epf_vntb/func1/pci_epf_vntb.0/vbus_number”…””}”hjÒsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h Kihj_hžhubeh}”(h]”Œconfiguring-pci-epf-vntb-device”ah ]”h"]”Œconfiguring pci-epf-vntb device”ah$]”h&]”uh1h´hj/hžhhŸh³h KNubhµ)”}”(hhh]”(hº)”}”(hŒ+Binding pci-epf-ntb Device to EP Controller”h]”hŒ+Binding pci-epf-ntb Device to EP Controller”…””}”(hjëhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjèhžhhŸh³h Knubhê)”}”(hŒYNTB function device should be attached to PCI endpoint controllers connected to the host.”h]”hŒYNTB function device should be attached to PCI endpoint controllers connected to the host.”…””}”(hjùhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h KphjèhžhubhŒ block_quote”“”)”}”(hŒI# ln -s controllers/5f010000.pcie_ep functions/pci-epf-ntb/func1/primary ”h]”hê)”}”(hŒH# ln -s controllers/5f010000.pcie_ep functions/pci-epf-ntb/func1/primary”h]”hŒH# ln -s controllers/5f010000.pcie_ep functions/pci-epf-ntb/func1/primary”…””}”(hj hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h Kshj ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhŸh³h Kshjèhžhubhê)”}”(hŒkOnce the above step is completed, the PCI endpoint controllers are ready to establish a link with the host.”h]”hŒkOnce the above step is completed, the PCI endpoint controllers are ready to establish a link with the host.”…””}”(hj!hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h Kuhjèhžhubeh}”(h]”Œ+binding-pci-epf-ntb-device-to-ep-controller”ah ]”h"]”Œ+binding pci-epf-ntb device to ep controller”ah$]”h&]”uh1h´hj/hžhhŸh³h Knubhµ)”}”(hhh]”(hº)”}”(hŒStart the Link”h]”hŒStart the Link”…””}”(hj:hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj7hžhhŸh³h Kzubhê)”}”(hŒáIn order for the endpoint device to establish a link with the host, the _start_ field should be populated with '1'. For NTB, both the PCI endpoint controllers should establish link with the host (imx8 don't need this steps)::”h]”hŒæIn order for the endpoint device to establish a link with the host, the _start_ field should be populated with ‘1’. For NTB, both the PCI endpoint controllers should establish link with the host (imx8 don’t need this steps):”…””}”(hjHhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h K|hj7hžhubj`)”}”(hŒ-# echo 1 > controllers/5f010000.pcie_ep/start”h]”hŒ-# echo 1 > controllers/5f010000.pcie_ep/start”…””}”hjVsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h K€hj7hžhubeh}”(h]”Œstart-the-link”ah ]”h"]”Œstart the link”ah$]”h&]”uh1h´hj/hžhhŸh³h Kzubeh}”(h]”Œendpoint-device”ah ]”h"]”Œendpoint device”ah$]”h&]”uh1h´hh¶hžhhŸh³h Kubhµ)”}”(hhh]”(hº)”}”(hŒRootComplex Device”h]”hŒRootComplex Device”…””}”(hjwhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjthžhhŸh³h Kƒubhµ)”}”(hhh]”(hº)”}”(hŒlspci Output at Host side”h]”hŒlspci Output at Host side”…””}”(hjˆhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj…hžhhŸh³h K†ubhê)”}”(hŒuNote that the devices listed here correspond to the values populated in "Creating pci-epf-ntb Device" section above::”h]”hŒxNote that the devices listed here correspond to the values populated in “Creating pci-epf-ntb Device†section above:”…””}”(hj–hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h Kˆhj…hžhubj`)”}”(hŒˆ# lspci 00:00.0 PCI bridge: Freescale Semiconductor Inc Device 0000 (rev 01) 01:00.0 RAM memory: Freescale Semiconductor Inc Device 0809”h]”hŒˆ# lspci 00:00.0 PCI bridge: Freescale Semiconductor Inc Device 0000 (rev 01) 01:00.0 RAM memory: Freescale Semiconductor Inc Device 0809”…””}”hj¤sbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h K‹hj…hžhubeh}”(h]”Œlspci-output-at-host-side”ah ]”h"]”Œlspci output at host side”ah$]”h&]”uh1h´hjthžhhŸh³h K†ubeh}”(h]”Œrootcomplex-device”ah ]”h"]”Œrootcomplex device”ah$]”h&]”uh1h´hh¶hžhhŸh³h Kƒubhµ)”}”(hhh]”(hº)”}”(hŒ!Endpoint Device / Virtual PCI bus”h]”hŒ!Endpoint Device / Virtual PCI bus”…””}”(hjÅhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjÂhžhhŸh³h Kubhµ)”}”(hhh]”(hº)”}”(hŒ)lspci Output at EP Side / Virtual PCI bus”h]”hŒ)lspci Output at EP Side / Virtual PCI bus”…””}”(hjÖhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjÓhžhhŸh³h K“ubhê)”}”(hŒuNote that the devices listed here correspond to the values populated in "Creating pci-epf-ntb Device" section above::”h]”hŒxNote that the devices listed here correspond to the values populated in “Creating pci-epf-ntb Device†section above:”…””}”(hjähžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h K•hjÓhžhubj`)”}”(hŒ^# lspci 10:00.0 Unassigned class [ffff]: Dawicontrol Computersysteme GmbH Device 1234 (rev ff)”h]”hŒ^# lspci 10:00.0 Unassigned class [ffff]: Dawicontrol Computersysteme GmbH Device 1234 (rev ff)”…””}”hjòsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1j_hŸh³h K˜hjÓhžhubeh}”(h]”Œ'lspci-output-at-ep-side-virtual-pci-bus”ah ]”h"]”Œ)lspci output at ep side / virtual pci bus”ah$]”h&]”uh1h´hjÂhžhhŸh³h K“ubhµ)”}”(hhh]”(hº)”}”(hŒUsing ntb_hw_epf Device”h]”hŒUsing ntb_hw_epf Device”…””}”(hj hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjhžhhŸh³h Kœubhê)”}”(hŒýThe host side software follows the standard NTB software architecture in Linux. All the existing client side NTB utilities like NTB Transport Client and NTB Netdev, NTB Ping Pong Test Client and NTB Tool Test Client can be used with NTB function device.”h]”hŒýThe host side software follows the standard NTB software architecture in Linux. All the existing client side NTB utilities like NTB Transport Client and NTB Netdev, NTB Ping Pong Test Client and NTB Tool Test Client can be used with NTB function device.”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h Kžhjhžhubhê)”}”(hŒTFor more information on NTB see :doc:`Non-Transparent Bridge <../../driver-api/ntb>`”h]”(hŒ For more information on NTB see ”…””}”(hj'hžhhŸNh Nubh)”}”(hŒ4:doc:`Non-Transparent Bridge <../../driver-api/ntb>`”h]”hŒinline”“”)”}”(hj1h]”hŒNon-Transparent Bridge”…””}”(hj5hžhhŸNh Nubah}”(h]”h ]”(Œxref”Œstd”Œstd-doc”eh"]”h$]”h&]”uh1j3hj/ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”ŒPCI/endpoint/pci-vntb-howto”Œ refdomain”j@Œreftype”Œdoc”Œ refexplicit”ˆŒrefwarn”ˆŒ reftarget”Œ../../driver-api/ntb”uh1hhŸh³h K£hj'ubeh}”(h]”h ]”h"]”h$]”h&]”uh1héhŸh³h K£hjhžhubeh}”(h]”Œusing-ntb-hw-epf-device”ah ]”h"]”Œusing ntb_hw_epf device”ah$]”h&]”uh1h´hjÂhžhhŸh³h Kœubeh}”(h]”Œendpoint-device-virtual-pci-bus”ah ]”h"]”Œ!endpoint device / virtual pci bus”ah$]”h&]”uh1h´hh¶hžhhŸh³h Kubeh}”(h]”Œ?pci-non-transparent-bridge-ntb-endpoint-function-epf-user-guide”ah ]”h"]”ŒCpci non-transparent bridge (ntb) endpoint function (epf) user guide”ah$]”h&]”uh1h´hhhžhhŸh³h Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”h³uh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)”}”(h¹NŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”j•Œerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”h³Œ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”(jojljqjnjjjájÞj\jYjåjâj4j1jijfj¿j¼j·j´jgjdjjj_j\uŒ nametypes”}”(jo‰jq‰j‰já‰j\‰jå‰j4‰ji‰j¿‰j·‰jg‰j‰j_‰uh}”(jlh¶jnj/jj@jÞj“jYjäjâj_j1jèjfj7j¼jtj´j…jdjÂjjÓj\juŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nhžhub.