.. | .. |
---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0-or-later */ |
---|
1 | 2 | /* |
---|
2 | 3 | * Copyright 2017 IBM Corp. |
---|
3 | | - * |
---|
4 | | - * This program is free software; you can redistribute it and/or |
---|
5 | | - * modify it under the terms of the GNU General Public License |
---|
6 | | - * as published by the Free Software Foundation; either version |
---|
7 | | - * 2 of the License, or (at your option) any later version. |
---|
8 | 4 | */ |
---|
9 | 5 | |
---|
10 | 6 | #ifndef _ASM_POWERNV_H |
---|
11 | 7 | #define _ASM_POWERNV_H |
---|
12 | 8 | |
---|
13 | 9 | #ifdef CONFIG_PPC_POWERNV |
---|
14 | | -#define NPU2_WRITE 1 |
---|
15 | 10 | extern void powernv_set_nmmu_ptcr(unsigned long ptcr); |
---|
16 | | -extern struct npu_context *pnv_npu2_init_context(struct pci_dev *gpdev, |
---|
17 | | - unsigned long flags, |
---|
18 | | - void (*cb)(struct npu_context *, void *), |
---|
19 | | - void *priv); |
---|
20 | | -extern void pnv_npu2_destroy_context(struct npu_context *context, |
---|
21 | | - struct pci_dev *gpdev); |
---|
22 | | -extern int pnv_npu2_handle_fault(struct npu_context *context, uintptr_t *ea, |
---|
23 | | - unsigned long *flags, unsigned long *status, |
---|
24 | | - int count); |
---|
25 | 11 | |
---|
26 | 12 | void pnv_program_cpu_hotplug_lpcr(unsigned int cpu, u64 lpcr_val); |
---|
27 | 13 | |
---|
28 | 14 | void pnv_tm_init(void); |
---|
29 | 15 | #else |
---|
30 | 16 | static inline void powernv_set_nmmu_ptcr(unsigned long ptcr) { } |
---|
31 | | -static inline struct npu_context *pnv_npu2_init_context(struct pci_dev *gpdev, |
---|
32 | | - unsigned long flags, |
---|
33 | | - struct npu_context *(*cb)(struct npu_context *, void *), |
---|
34 | | - void *priv) { return ERR_PTR(-ENODEV); } |
---|
35 | | -static inline void pnv_npu2_destroy_context(struct npu_context *context, |
---|
36 | | - struct pci_dev *gpdev) { } |
---|
37 | | - |
---|
38 | | -static inline int pnv_npu2_handle_fault(struct npu_context *context, |
---|
39 | | - uintptr_t *ea, unsigned long *flags, |
---|
40 | | - unsigned long *status, int count) { |
---|
41 | | - return -ENODEV; |
---|
42 | | -} |
---|
43 | 17 | |
---|
44 | 18 | static inline void pnv_tm_init(void) { } |
---|
45 | | -static inline void pnv_power9_force_smt4(void) { } |
---|
46 | 19 | #endif |
---|
47 | 20 | |
---|
48 | 21 | #endif /* _ASM_POWERNV_H */ |
---|