hc
2024-10-12 a5969cabbb4660eab42b6ef0412cbbd1200cf14d
kernel/arch/powerpc/include/asm/pci.h
....@@ -1,18 +1,15 @@
1
+/* SPDX-License-Identifier: GPL-2.0-or-later */
12 #ifndef __ASM_POWERPC_PCI_H
23 #define __ASM_POWERPC_PCI_H
34 #ifdef __KERNEL__
45
56 /*
6
- * This program is free software; you can redistribute it and/or
7
- * modify it under the terms of the GNU General Public License
8
- * as published by the Free Software Foundation; either version
9
- * 2 of the License, or (at your option) any later version.
107 */
118
129 #include <linux/types.h>
1310 #include <linux/slab.h>
1411 #include <linux/string.h>
15
-#include <linux/dma-mapping.h>
12
+#include <linux/dma-map-ops.h>
1613 #include <linux/scatterlist.h>
1714
1815 #include <asm/machdep.h>
....@@ -52,10 +49,8 @@
5249
5350 #ifdef CONFIG_PCI
5451 extern void set_pci_dma_ops(const struct dma_map_ops *dma_ops);
55
-extern const struct dma_map_ops *get_pci_dma_ops(void);
5652 #else /* CONFIG_PCI */
5753 #define set_pci_dma_ops(d)
58
-#define get_pci_dma_ops() NULL
5954 #endif
6055
6156 #ifdef CONFIG_PPC64
....@@ -117,10 +112,7 @@
117112 unsigned long size,
118113 pgprot_t prot);
119114
120
-#define HAVE_ARCH_PCI_RESOURCE_TO_USER
121
-
122115 extern resource_size_t pcibios_io_space_offset(struct pci_controller *hose);
123
-extern void pcibios_setup_bus_devices(struct pci_bus *bus);
124116 extern void pcibios_setup_bus_self(struct pci_bus *bus);
125117 extern void pcibios_setup_phb_io_space(struct pci_controller *hose);
126118 extern void pcibios_scan_phb(struct pci_controller *hose);
....@@ -129,5 +121,9 @@
129121
130122 extern struct pci_dev *pnv_pci_get_gpu_dev(struct pci_dev *npdev);
131123 extern struct pci_dev *pnv_pci_get_npu_dev(struct pci_dev *gpdev, int index);
124
+extern int pnv_npu2_init(struct pci_controller *hose);
125
+extern int pnv_npu2_map_lpar_dev(struct pci_dev *gpdev, unsigned int lparid,
126
+ unsigned long msr);
127
+extern int pnv_npu2_unmap_lpar_dev(struct pci_dev *gpdev);
132128
133129 #endif /* __ASM_POWERPC_PCI_H */