]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - android-sdk/kernel-video.git/blobdiff - include/linux/ion.h
gpu: ion: add support for more cache operations
[android-sdk/kernel-video.git] / include / linux / ion.h
index 610665d2be718761d7deec2e81815fd51d473915..31045a150dc5c8ab22a6898dc3f8043838c66be6 100644 (file)
@@ -41,6 +41,21 @@ enum ion_heap_type {
        ION_NUM_HEAPS = 16,
 };
 
+/**
+ * enum ion_data_direction - sync operation arguments
+ * @ION_BIDIRECTIONAL:  memory written to & read from device
+ * @ION_TO_DEVICE: memory going to be transferred to device
+ * @ION_FROM_DEVICE:    memory populated by device
+ * @ION_NONE:           None of the above
+ */
+enum ion_data_direction {
+       ION_BIDIRECTIONAL = 0,
+       ION_TO_DEVICE = 1,
+       ION_FROM_DEVICE = 2,
+       ION_NONE = 3,
+};
+
+
 #define ION_HEAP_SYSTEM_MASK           (1 << ION_HEAP_TYPE_SYSTEM)
 #define ION_HEAP_SYSTEM_CONTIG_MASK    (1 << ION_HEAP_TYPE_SYSTEM_CONTIG)
 #define ION_HEAP_CARVEOUT_MASK         (1 << ION_HEAP_TYPE_CARVEOUT)
@@ -126,7 +141,6 @@ void ion_reserve(struct ion_platform_data *data);
  * @name:              used for debugging
  */
 struct ion_client *ion_client_create(struct ion_device *dev,
-                                    unsigned int heap_type_mask,
                                     const char *name);
 
 /**
@@ -274,6 +288,7 @@ struct ion_allocation_data {
 struct ion_fd_data {
        struct ion_handle *handle;
        int fd;
+       enum ion_data_direction dir;
 };
 
 /**