1 | /*
|
---|
2 | * Copyright (C) 2017 Oracle Corporation
|
---|
3 | * Copyright 2017 Canonical
|
---|
4 | *
|
---|
5 | * Permission is hereby granted, free of charge, to any person obtaining a
|
---|
6 | * copy of this software and associated documentation files (the "Software"),
|
---|
7 | * to deal in the Software without restriction, including without limitation
|
---|
8 | * the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
---|
9 | * and/or sell copies of the Software, and to permit persons to whom the
|
---|
10 | * Software is furnished to do so, subject to the following conditions:
|
---|
11 | *
|
---|
12 | * The above copyright notice and this permission notice shall be included in
|
---|
13 | * all copies or substantial portions of the Software.
|
---|
14 | *
|
---|
15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
---|
16 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
---|
17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
---|
18 | * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
|
---|
19 | * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
---|
20 | * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
---|
21 | * OTHER DEALINGS IN THE SOFTWARE.
|
---|
22 | *
|
---|
23 | * Authors: Andreas Pokorny
|
---|
24 | */
|
---|
25 |
|
---|
26 | #include "vbox_drv.h"
|
---|
27 |
|
---|
28 | /*
|
---|
29 | * Based on qxl_prime.c:
|
---|
30 | * Empty Implementations as there should not be any other driver for a virtual
|
---|
31 | * device that might share buffers with vboxvideo
|
---|
32 | */
|
---|
33 |
|
---|
34 | int vbox_gem_prime_pin(struct drm_gem_object *obj)
|
---|
35 | {
|
---|
36 | WARN_ONCE(1, "not implemented");
|
---|
37 | return -ENOSYS;
|
---|
38 | }
|
---|
39 |
|
---|
40 | void vbox_gem_prime_unpin(struct drm_gem_object *obj)
|
---|
41 | {
|
---|
42 | WARN_ONCE(1, "not implemented");
|
---|
43 | }
|
---|
44 |
|
---|
45 | struct sg_table *vbox_gem_prime_get_sg_table(struct drm_gem_object *obj)
|
---|
46 | {
|
---|
47 | WARN_ONCE(1, "not implemented");
|
---|
48 | return ERR_PTR(-ENOSYS);
|
---|
49 | }
|
---|
50 |
|
---|
51 | struct drm_gem_object *vbox_gem_prime_import_sg_table(struct drm_device *dev,
|
---|
52 | #if LINUX_VERSION_CODE < KERNEL_VERSION(3, 18, 0) && !defined(RHEL_73)
|
---|
53 | size_t size,
|
---|
54 | #else
|
---|
55 | struct dma_buf_attachment
|
---|
56 | *attach,
|
---|
57 | #endif
|
---|
58 | struct sg_table *table)
|
---|
59 | {
|
---|
60 | WARN_ONCE(1, "not implemented");
|
---|
61 | return ERR_PTR(-ENOSYS);
|
---|
62 | }
|
---|
63 |
|
---|
64 | void *vbox_gem_prime_vmap(struct drm_gem_object *obj)
|
---|
65 | {
|
---|
66 | WARN_ONCE(1, "not implemented");
|
---|
67 | return ERR_PTR(-ENOSYS);
|
---|
68 | }
|
---|
69 |
|
---|
70 | void vbox_gem_prime_vunmap(struct drm_gem_object *obj, void *vaddr)
|
---|
71 | {
|
---|
72 | WARN_ONCE(1, "not implemented");
|
---|
73 | }
|
---|
74 |
|
---|
75 | int vbox_gem_prime_mmap(struct drm_gem_object *obj, struct vm_area_struct *area)
|
---|
76 | {
|
---|
77 | WARN_ONCE(1, "not implemented");
|
---|
78 | return -ENOSYS;
|
---|
79 | }
|
---|