summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/soc/amd/common/block/include/amdblocks/pci_devs.h15
-rw-r--r--src/soc/amd/picasso/include/soc/pci_devs.h8
-rw-r--r--src/soc/amd/stoneyridge/include/soc/pci_devs.h8
3 files changed, 17 insertions, 14 deletions
diff --git a/src/soc/amd/common/block/include/amdblocks/pci_devs.h b/src/soc/amd/common/block/include/amdblocks/pci_devs.h
new file mode 100644
index 0000000000..8a38ac15d7
--- /dev/null
+++ b/src/soc/amd/common/block/include/amdblocks/pci_devs.h
@@ -0,0 +1,15 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+
+#ifndef __AMD_BLOCK_PCI_DEVS_H__
+#define __AMD_BLOCK_PCI_DEVS_H__
+
+#include <device/pci_def.h>
+
+#if !defined(__SIMPLE_DEVICE__)
+#include <device/device.h>
+#define _SOC_DEV(slot, func) pcidev_on_root(slot, func)
+#else
+#define _SOC_DEV(slot, func) PCI_DEV(0, slot, func)
+#endif
+
+#endif /* __AMD_BLOCK_PCI_DEVS_H__ */
diff --git a/src/soc/amd/picasso/include/soc/pci_devs.h b/src/soc/amd/picasso/include/soc/pci_devs.h
index 27334f1462..83c0bcc7e3 100644
--- a/src/soc/amd/picasso/include/soc/pci_devs.h
+++ b/src/soc/amd/picasso/include/soc/pci_devs.h
@@ -4,13 +4,7 @@
#define __PI_PICASSO_PCI_DEVS_H__
#include <device/pci_def.h>
-
-#if !defined(__SIMPLE_DEVICE__)
-#include <device/device.h>
-#define _SOC_DEV(slot, func) pcidev_on_root(slot, func)
-#else
-#define _SOC_DEV(slot, func) PCI_DEV(0, slot, func)
-#endif
+#include <amdblocks/pci_devs.h>
/* GNB Root Complex */
#define GNB_DEV 0x0
diff --git a/src/soc/amd/stoneyridge/include/soc/pci_devs.h b/src/soc/amd/stoneyridge/include/soc/pci_devs.h
index 316f532d0e..03a12336f7 100644
--- a/src/soc/amd/stoneyridge/include/soc/pci_devs.h
+++ b/src/soc/amd/stoneyridge/include/soc/pci_devs.h
@@ -4,13 +4,7 @@
#define __PI_STONEYRIDGE_PCI_DEVS_H__
#include <device/pci_def.h>
-
-#if !defined(__SIMPLE_DEVICE__)
-#include <device/device.h>
-#define _SOC_DEV(slot, func) pcidev_on_root(slot, func)
-#else
-#define _SOC_DEV(slot, func) PCI_DEV(0, slot, func)
-#endif
+#include <amdblocks/pci_devs.h>
/* GNB Root Complex */
#define GNB_DEV 0x0