summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/pci.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/pci.h b/include/pci.h
index 785d7d28b7..041f8e3747 100644
--- a/include/pci.h
+++ b/include/pci.h
@@ -1560,6 +1560,16 @@ struct dm_pci_emul_ops {
int sandbox_pci_get_emul(struct udevice *bus, pci_dev_t find_devfn,
struct udevice **containerp, struct udevice **emulp);
+/**
+ * pci_get_devfn() - Extract the devfn from fdt_pci_addr of the device
+ *
+ * Get devfn from fdt_pci_addr of the specifified device
+ *
+ * @dev: PCI device
+ * @return devfn in bits 15...8 if found, -ENODEV if not found
+ */
+int pci_get_devfn(struct udevice *dev);
+
#endif /* CONFIG_DM_PCI */
/**