xref: /linux/drivers/gpu/drm/xe/xe_gt_sriov_pf.h (revision 205a7309cccd34ad49c2b6b1b59b907c12395d6c)
1 /* SPDX-License-Identifier: MIT */
2 /*
3  * Copyright © 2023-2024 Intel Corporation
4  */
5 
6 #ifndef _XE_GT_SRIOV_PF_H_
7 #define _XE_GT_SRIOV_PF_H_
8 
9 struct xe_gt;
10 
11 #ifdef CONFIG_PCI_IOV
12 int xe_gt_sriov_pf_init_early(struct xe_gt *gt);
13 int xe_gt_sriov_pf_init(struct xe_gt *gt);
14 void xe_gt_sriov_pf_init_hw(struct xe_gt *gt);
15 void xe_gt_sriov_pf_sanitize_hw(struct xe_gt *gt, unsigned int vfid);
16 void xe_gt_sriov_pf_stop_prepare(struct xe_gt *gt);
17 void xe_gt_sriov_pf_restart(struct xe_gt *gt);
18 #else
19 static inline int xe_gt_sriov_pf_init_early(struct xe_gt *gt)
20 {
21 	return 0;
22 }
23 
24 static inline int xe_gt_sriov_pf_init(struct xe_gt *gt)
25 {
26 	return 0;
27 }
28 
29 static inline void xe_gt_sriov_pf_init_hw(struct xe_gt *gt)
30 {
31 }
32 
33 static inline void xe_gt_sriov_pf_stop_prepare(struct xe_gt *gt)
34 {
35 }
36 
37 static inline void xe_gt_sriov_pf_restart(struct xe_gt *gt)
38 {
39 }
40 #endif
41 
42 #endif
43