summaryrefslogtreecommitdiff
path: root/drivers/gpu/mali/umplock/umplock_ioctl.h
diff options
context:
space:
mode:
authorSrikant Patnaik2015-01-11 19:41:45 +0530
committerSrikant Patnaik2015-01-11 19:41:45 +0530
commitabc18728f7736823a28540346129bbeafb3b5866 (patch)
tree036140abf92bd5ebc4bfa605cb686e1f1638ca1d /drivers/gpu/mali/umplock/umplock_ioctl.h
parentb9ae4882794bcdc8d26671dfdbc406173d76c739 (diff)
downloadFOSSEE-netbook-kernel-source-abc18728f7736823a28540346129bbeafb3b5866.tar.gz
FOSSEE-netbook-kernel-source-abc18728f7736823a28540346129bbeafb3b5866.tar.bz2
FOSSEE-netbook-kernel-source-abc18728f7736823a28540346129bbeafb3b5866.zip
This commit is dedicacted to MALI, UMP and MALI_DRM. This includes MALI-r3p2 from other source
Diffstat (limited to 'drivers/gpu/mali/umplock/umplock_ioctl.h')
-rw-r--r--drivers/gpu/mali/umplock/umplock_ioctl.h66
1 files changed, 66 insertions, 0 deletions
diff --git a/drivers/gpu/mali/umplock/umplock_ioctl.h b/drivers/gpu/mali/umplock/umplock_ioctl.h
new file mode 100644
index 00000000..9ac5b7f2
--- /dev/null
+++ b/drivers/gpu/mali/umplock/umplock_ioctl.h
@@ -0,0 +1,66 @@
+/*
+ * Copyright (C) 2012-2014 ARM Limited. All rights reserved.
+ *
+ * This program is free software and is provided to you under the terms of the GNU General Public License version 2
+ * as published by the Free Software Foundation, and any use by you of this program is subject to the terms of such GNU licence.
+ *
+ * A copy of the licence is included with the program, and can also be obtained from Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#ifndef __UMPLOCK_IOCTL_H__
+#define __UMPLOCK_IOCTL_H__
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include <linux/types.h>
+#include <linux/ioctl.h>
+
+#ifndef __user
+#define __user
+#endif
+
+
+/**
+ * @file umplock_ioctl.h
+ * This file describes the interface needed to use the Linux device driver.
+ * The interface is used by the userpace Mali DDK.
+ */
+
+typedef enum {
+ _LOCK_ACCESS_RENDERABLE = 1,
+ _LOCK_ACCESS_TEXTURE,
+ _LOCK_ACCESS_CPU_WRITE,
+ _LOCK_ACCESS_CPU_READ,
+} _lock_access_usage;
+
+typedef struct _lock_item_s {
+ unsigned int secure_id;
+ _lock_access_usage usage;
+} _lock_item_s;
+
+
+#define LOCK_IOCTL_GROUP 0x91
+
+#define _LOCK_IOCTL_CREATE_CMD 0 /* create kernel lock item */
+#define _LOCK_IOCTL_PROCESS_CMD 1 /* process kernel lock item */
+#define _LOCK_IOCTL_RELEASE_CMD 2 /* release kernel lock item */
+#define _LOCK_IOCTL_ZAP_CMD 3 /* clean up all kernel lock items */
+#define _LOCK_IOCTL_DUMP_CMD 4 /* dump all the items */
+
+#define LOCK_IOCTL_MAX_CMDS 5
+
+#define LOCK_IOCTL_CREATE _IOW( LOCK_IOCTL_GROUP, _LOCK_IOCTL_CREATE_CMD, _lock_item_s )
+#define LOCK_IOCTL_PROCESS _IOW( LOCK_IOCTL_GROUP, _LOCK_IOCTL_PROCESS_CMD, _lock_item_s )
+#define LOCK_IOCTL_RELEASE _IOW( LOCK_IOCTL_GROUP, _LOCK_IOCTL_RELEASE_CMD, _lock_item_s )
+#define LOCK_IOCTL_ZAP _IO ( LOCK_IOCTL_GROUP, _LOCK_IOCTL_ZAP_CMD )
+#define LOCK_IOCTL_DUMP _IO ( LOCK_IOCTL_GROUP, _LOCK_IOCTL_DUMP_CMD )
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __UMPLOCK_IOCTL_H__ */
+