xref: /linux/drivers/gpu/drm/i915/selftests/igt_mmap.h (revision fc2d791a43d3880496d1c729b8bd74d2c19cb4e7)
1 /*
2  * SPDX-License-Identifier: MIT
3  *
4  * Copyright © 2019 Intel Corporation
5  */
6 
7 #ifndef IGT_MMAP_H
8 #define IGT_MMAP_H
9 
10 #include <linux/types.h>
11 
12 struct drm_i915_private;
13 struct drm_vma_offset_node;
14 struct file;
15 
16 unsigned long igt_mmap_offset(struct drm_i915_private *i915,
17 			      u64 offset,
18 			      unsigned long size,
19 			      unsigned long prot,
20 			      unsigned long flags);
21 
22 unsigned long igt_mmap_offset_with_file(struct drm_i915_private *i915,
23 					u64 offset,
24 					unsigned long size,
25 					unsigned long prot,
26 					unsigned long flags,
27 					struct file *file);
28 
29 #endif /* IGT_MMAP_H */
30