OSDN Git Service

Merge branch 'upstream-master'
[android-x86/external-minigbm.git] / cros_gralloc / cros_gralloc_handle.h
index 1920df3..cd3edfe 100644 (file)
@@ -7,8 +7,8 @@
 #ifndef CROS_GRALLOC_HANDLE_H
 #define CROS_GRALLOC_HANDLE_H
 
-#include <cutils/native_handle.h>
 #include <cstdint>
+#include <cutils/native_handle.h>
 
 #define DRV_MAX_PLANES 4
 
@@ -22,20 +22,17 @@ struct cros_gralloc_handle {
        int32_t fds[DRV_MAX_PLANES];
        uint32_t strides[DRV_MAX_PLANES];
        uint32_t offsets[DRV_MAX_PLANES];
-       uint32_t sizes[DRV_MAX_PLANES];
        uint32_t format_modifiers[2 * DRV_MAX_PLANES];
        uint32_t width;
        uint32_t height;
-       uint32_t format;            /* DRM format */
+       uint32_t format;       /* DRM format */
+       uint32_t use_flags[2]; /* Buffer creation flags */
        uint32_t magic;
        uint32_t pixel_stride;
        int32_t droid_format;
-       int32_t usage;              /* Android usage. */
-       uint64_t bo;                /* Pointer to cros_gralloc_bo. */
-       int32_t registrations;      /*
-                                    * Number of times (*register)() has been
-                                    * called on this handle.
-                                    */
+       int32_t usage; /* Android usage. */
 };
 
+typedef const struct cros_gralloc_handle *cros_gralloc_handle_t;
+
 #endif