| /linux/drivers/pci/endpoint/ |
| H A D | pci-epf-core.c | 31 void pci_epf_unbind(struct pci_epf *epf) in pci_epf_unbind() argument 35 if (!epf->driver) { in pci_epf_unbind() 36 dev_WARN(&epf->dev, "epf device not bound to driver\n"); in pci_epf_unbind() 40 mutex_lock(&epf->lock); in pci_epf_unbind() 41 list_for_each_entry(epf_vf, &epf->pci_vepf, list) { in pci_epf_unbind() 45 if (epf->is_bound) in pci_epf_unbind() 46 epf->driver->ops->unbind(epf); in pci_epf_unbind() 47 mutex_unlock(&epf->lock); in pci_epf_unbind() 48 module_put(epf->driver->owner); in pci_epf_unbind() 59 int pci_epf_bind(struct pci_epf *epf) in pci_epf_bind() argument [all …]
|
| H A D | pci-ep-cfs.c | 26 struct pci_epf *epf; member 53 struct pci_epf *epf = epf_group->epf; in pci_secondary_epc_epf_link() local 55 ret = pci_epc_add_epf(epc, epf, SECONDARY_INTERFACE); in pci_secondary_epc_epf_link() 59 ret = pci_epf_bind(epf); in pci_secondary_epc_epf_link() 61 pci_epc_remove_epf(epc, epf, SECONDARY_INTERFACE); in pci_secondary_epc_epf_link() 66 pci_epc_notify_pending_init(epc, epf); in pci_secondary_epc_epf_link() 77 struct pci_epf *epf; in pci_secondary_epc_epf_unlink() local 82 epf = epf_group->epf; in pci_secondary_epc_epf_unlink() 83 pci_epf_unbind(epf); in pci_secondary_epc_epf_unlink() 84 pci_epc_remove_epf(epc, epf, SECONDARY_INTERFACE); in pci_secondary_epc_epf_unlink() [all …]
|
| H A D | pci-ep-msi.c | 24 struct pci_epf *epf; in pci_epf_write_msi_msg() local 30 epf = list_first_entry_or_null(&epc->pci_epf, struct pci_epf, list); in pci_epf_write_msi_msg() 32 if (epf && epf->db_msg && desc->msi_index < epf->num_db) in pci_epf_write_msi_msg() 33 memcpy(&epf->db_msg[desc->msi_index].msg, msg, sizeof(*msg)); in pci_epf_write_msi_msg() 38 int pci_epf_alloc_doorbell(struct pci_epf *epf, u16 num_db) in pci_epf_alloc_doorbell() argument 40 struct pci_epc *epc = epf->epc; in pci_epf_alloc_doorbell() 41 struct device *dev = &epf->dev; in pci_epf_alloc_doorbell() 48 if (list_first_entry_or_null(&epc->pci_epf, struct pci_epf, list) != epf) { in pci_epf_alloc_doorbell() 74 epf->num_db = num_db; in pci_epf_alloc_doorbell() 75 epf->db_msg = msg; in pci_epf_alloc_doorbell() [all …]
|
| H A D | pci-epc-core.c | 709 int pci_epc_add_epf(struct pci_epc *epc, struct pci_epf *epf, in pci_epc_add_epf() argument 716 if (IS_ERR_OR_NULL(epc) || epf->is_vf) in pci_epc_add_epf() 719 if (type == PRIMARY_INTERFACE && epf->epc) in pci_epc_add_epf() 722 if (type == SECONDARY_INTERFACE && epf->sec_epc) in pci_epc_add_epf() 741 epf->func_no = func_no; in pci_epc_add_epf() 742 epf->epc = epc; in pci_epc_add_epf() 743 list = &epf->list; in pci_epc_add_epf() 745 epf->sec_epc_func_no = func_no; in pci_epc_add_epf() 746 epf->sec_epc = epc; in pci_epc_add_epf() 747 list = &epf->sec_epc_list; in pci_epc_add_epf() [all …]
|
| H A D | Makefile | 7 obj-$(CONFIG_PCI_ENDPOINT) += pci-epc-core.o pci-epf-core.o\
|
| /linux/drivers/pci/endpoint/functions/ |
| H A D | pci-epf-test.c | 20 #include <linux/pci-epf.h> 74 struct pci_epf *epf; member 159 struct pci_epf *epf = epf_test->epf; in pci_epf_test_data_transfer() local 162 struct device *dev = &epf->dev; in pci_epf_test_data_transfer() 248 struct pci_epf *epf = epf_test->epf; in pci_epf_test_init_dma_chan() local 249 struct device *dev = &epf->dev; in pci_epf_test_init_dma_chan() 255 filter.dev = epf->epc->dev.parent; in pci_epf_test_init_dma_chan() 345 dev_info(&epf_test->epf in pci_epf_test_print_rate() 355 struct pci_epf *epf = epf_test->epf; pci_epf_test_copy() local 459 struct pci_epf *epf = epf_test->epf; pci_epf_test_read() local 556 struct pci_epf *epf = epf_test->epf; pci_epf_test_write() local 653 struct pci_epf *epf = epf_test->epf; pci_epf_test_raise_irq() local 716 struct pci_epf *epf = epf_test->epf; pci_epf_test_doorbell_cleanup() local 728 struct pci_epf *epf = epf_test->epf; pci_epf_test_enable_doorbell() local 790 struct pci_epf *epf = epf_test->epf; pci_epf_test_disable_doorbell() local 831 struct pci_epf *epf = epf_test->epf; pci_epf_test_bar_subrange_setup() local 927 struct pci_epf *epf = epf_test->epf; pci_epf_test_bar_subrange_clear() local 975 struct pci_epf *epf = epf_test->epf; pci_epf_test_cmd_handler() local 1043 pci_epf_test_set_bar(struct pci_epf * epf) pci_epf_test_set_bar() argument 1070 pci_epf_test_clear_bar(struct pci_epf * epf) pci_epf_test_clear_bar() argument 1085 pci_epf_test_set_capabilities(struct pci_epf * epf) pci_epf_test_set_capabilities() argument 1112 pci_epf_test_epc_init(struct pci_epf * epf) pci_epf_test_epc_init() argument 1169 pci_epf_test_epc_deinit(struct pci_epf * epf) pci_epf_test_epc_deinit() argument 1178 pci_epf_test_link_up(struct pci_epf * epf) pci_epf_test_link_up() argument 1188 pci_epf_test_link_down(struct pci_epf * epf) pci_epf_test_link_down() argument 1204 pci_epf_test_alloc_space(struct pci_epf * epf) pci_epf_test_alloc_space() argument 1259 pci_epf_test_free_space(struct pci_epf * epf) pci_epf_test_free_space() argument 1274 pci_epf_test_bind(struct pci_epf * epf) pci_epf_test_bind() argument 1305 pci_epf_test_unbind(struct pci_epf * epf) pci_epf_test_unbind() argument 1393 pci_epf_test_add_cfs(struct pci_epf * epf,struct config_group * group) pci_epf_test_add_cfs() argument 1413 pci_epf_test_probe(struct pci_epf * epf,const struct pci_epf_device_id * id) pci_epf_test_probe() argument [all...] |
| H A D | pci-epf-mhi.c | 147 struct pci_epf *epf; member 171 struct pci_epf *epf = epf_mhi->epf; in __pci_epf_mhi_alloc_map() local 172 struct pci_epc *epc = epf->epc; in __pci_epf_mhi_alloc_map() 179 ret = pci_epc_map_addr(epc, epf->func_no, epf->vfunc_no, *paddr, in __pci_epf_mhi_alloc_map() 209 struct pci_epf *epf = epf_mhi->epf; in __pci_epf_mhi_unmap_free() local 210 struct pci_epc *epc = epf->epc; in __pci_epf_mhi_unmap_free() 212 pci_epc_unmap_addr(epc, epf->func_no, epf->vfunc_no, paddr - offset); in __pci_epf_mhi_unmap_free() 231 struct pci_epf *epf = epf_mhi->epf; in pci_epf_mhi_raise_irq() local 232 struct pci_epc *epc = epf->epc; in pci_epf_mhi_raise_irq() 238 pci_epc_raise_irq(epc, epf->func_no, epf->vfunc_no, PCI_IRQ_MSI, in pci_epf_mhi_raise_irq() [all …]
|
| H A D | Makefile | 6 obj-$(CONFIG_PCI_EPF_TEST) += pci-epf-test.o 7 obj-$(CONFIG_PCI_EPF_NTB) += pci-epf-ntb.o 8 obj-$(CONFIG_PCI_EPF_VNTB) += pci-epf-vntb.o 9 obj-$(CONFIG_PCI_EPF_MHI) += pci-epf-mhi.o
|
| /linux/drivers/nvme/target/ |
| H A D | pci-epf.c | 199 struct pci_epf *epf; member 259 struct pci_epf *epf = nvme_epf->epf; in nvmet_pci_epf_mem_map() local 261 return pci_epc_mem_map(epf->epc, epf->func_no, epf->vfunc_no, in nvmet_pci_epf_mem_map() 268 struct pci_epf *epf = nvme_epf->epf; in nvmet_pci_epf_mem_unmap() local 270 pci_epc_mem_unmap(epf->epc, epf->func_no, epf->vfunc_no, map); in nvmet_pci_epf_mem_unmap() 292 struct pci_epf *epf = nvme_epf->epf; in nvmet_pci_epf_init_dma() local 293 struct device *dev = &epf->dev; in nvmet_pci_epf_init_dma() 304 filter.dev = epf->epc->dev.parent; in nvmet_pci_epf_init_dma() 343 dev_info(&epf->dev, "DMA not supported, falling back to MMIO\n"); in nvmet_pci_epf_init_dma() 363 struct pci_epf *epf = nvme_epf->epf; in nvmet_pci_epf_dma_transfer() local [all …]
|
| /linux/drivers/pci/controller/cadence/ |
| H A D | pcie-cadence-ep.c | 85 struct cdns_pcie_epf *epf = &ep->epf[fn]; in cdns_pcie_ep_set_bar() local 146 epf = &epf->epf[vfn - 1]; in cdns_pcie_ep_set_bar() 147 epf->epf_bar[bar] = epf_bar; in cdns_pcie_ep_set_bar() 156 struct cdns_pcie_epf *epf = &ep->epf[fn]; in cdns_pcie_ep_clear_bar() local 181 epf = &epf->epf[vfn - 1]; in cdns_pcie_ep_clear_bar() 182 epf->epf_bar[bar] = NULL; in cdns_pcie_ep_clear_bar() 494 struct cdns_pcie_epf *epf; in cdns_pcie_ep_send_msix_irq() local 501 epf = &ep->epf[fn]; in cdns_pcie_ep_send_msix_irq() 503 epf = &epf->epf[vfn - 1]; in cdns_pcie_ep_send_msix_irq() 517 msix_tbl = epf->epf_bar[bir]->addr + tbl_offset; in cdns_pcie_ep_send_msix_irq() [all …]
|
| /linux/Documentation/PCI/endpoint/ |
| H A D | pci-ntb-howto.rst | 9 This document is a guide to help users use pci-epf-ntb function driver 40 # ls /sys/bus/pci-epf/drivers 49 Creating pci-epf-ntb Device 53 pci-epf-ntb device, the following commands can be used:: 59 The "mkdir func1" above creates the pci-epf-ntb function device that will 66 baseclass_code deviceid msi_interrupts pci-epf-ntb.0 72 when the device is bound to the driver. The pci-epf-ntb driver populates 81 Configuring pci-epf-ntb Device 84 The user can configure the pci-epf-ntb device using its configfs entry. In order 108 Binding pci-epf-ntb Device to EP Controller [all …]
|
| H A D | pci-nvme-function.rst | 11 subsystem as drivers/nvme/target/pci-epf.c.
|
| /linux/include/linux/ |
| H A D | pci-ep-msi.h | 15 int pci_epf_alloc_doorbell(struct pci_epf *epf, u16 nums); 16 void pci_epf_free_doorbell(struct pci_epf *epf); 18 static inline int pci_epf_alloc_doorbell(struct pci_epf *epf, u16 nums) in pci_epf_alloc_doorbell() argument 23 static inline void pci_epf_free_doorbell(struct pci_epf *epf) in pci_epf_free_doorbell() argument
|
| /linux/drivers/ntb/hw/ |
| H A D | Makefile | 5 obj-$(CONFIG_NTB_EPF) += epf/
|
| H A D | Kconfig | 5 source "drivers/ntb/hw/epf/Kconfig"
|
| /linux/drivers/pci/controller/ |
| H A D | pcie-rockchip-ep.c | 474 struct pci_epf *epf; in rockchip_pcie_ep_start() local 478 list_for_each_entry(epf, &epc->pci_epf, list) in rockchip_pcie_ep_start() 479 cfg |= BIT(epf->func_no); in rockchip_pcie_ep_start()
|
| /linux/Documentation/nvme/ |
| H A D | nvme-pci-endpoint-target.rst | 216 # echo -n "Linux-pci-epf" > nvmepf.0.nqn/attr_model 327 mn : Linux-pci-epf
|
| /linux/ |
| H A D | MAINTAINERS | 17134 F: drivers/pci/endpoint/functions/pci-epf-mhi.c 18845 F: drivers/pci/endpoint/functions/pci-epf-*ntb.c
|