aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'omap/omap_drmif.h')
-rw-r--r--omap/omap_drmif.h61
1 files changed, 61 insertions, 0 deletions
diff --git a/omap/omap_drmif.h b/omap/omap_drmif.h
new file mode 100644
index 00000000..eb75a80a
--- /dev/null
+++ b/omap/omap_drmif.h
@@ -0,0 +1,61 @@
1/*
2 * Copyright (C) 2011 Texas Instruments, Inc
3 *
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
10 *
11 * The above copyright notice and this permission notice (including the next
12 * paragraph) shall be included in all copies or substantial portions of the
13 * 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 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 * SOFTWARE.
22 *
23 * Authors:
24 * Rob Clark <rob@ti.com>
25 */
26
27#ifndef OMAP_DRMIF_H_
28#define OMAP_DRMIF_H_
29
30#include <xf86drm.h>
31#include <stdint.h>
32#include <omap_drm.h>
33
34struct omap_bo;
35struct omap_device;
36
37/* device related functions:
38 */
39
40struct omap_device * omap_device_new(int fd);
41void omap_device_del(struct omap_device *dev);
42int omap_get_param(struct omap_device *dev, uint64_t param, uint64_t *value);
43int omap_set_param(struct omap_device *dev, uint64_t param, uint64_t value);
44
45/* buffer-object related functions:
46 */
47
48struct omap_bo * omap_bo_new(struct omap_device *dev,
49 uint32_t size, uint32_t flags);
50struct omap_bo * omap_bo_new_tiled(struct omap_device *dev,
51 uint32_t width, uint32_t height, uint32_t flags);
52struct omap_bo * omap_bo_from_name(struct omap_device *dev, uint32_t name);
53void omap_bo_del(struct omap_bo *bo);
54int omap_bo_get_name(struct omap_bo *bo, uint32_t *name);
55uint32_t omap_bo_handle(struct omap_bo *bo);
56uint32_t omap_bo_size(struct omap_bo *bo);
57void * omap_bo_map(struct omap_bo *bo);
58int omap_bo_cpu_prep(struct omap_bo *bo, enum omap_gem_op op);
59int omap_bo_cpu_fini(struct omap_bo *bo, enum omap_gem_op op);
60
61#endif /* OMAP_DRMIF_H_ */