summaryrefslogtreecommitdiffstats
path: root/opengl/system
diff options
context:
space:
mode:
authorDavid Turner <digit@android.com>2014-07-17 09:26:04 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-07-17 00:25:55 +0000
commit9b1e6c5a3ccd943b7158dce83387fbfcc1162d69 (patch)
tree28acaed347f6b254cbc29cf6b39ac6a156cccfc9 /opengl/system
parent7ea757df0311bfb7310a7a765dcec1b79f39f25d (diff)
parent3f62b50d45441ae077c958423e9e301acd5dcc11 (diff)
downloadandroid_device_generic_goldfish-9b1e6c5a3ccd943b7158dce83387fbfcc1162d69.tar.gz
android_device_generic_goldfish-9b1e6c5a3ccd943b7158dce83387fbfcc1162d69.tar.bz2
android_device_generic_goldfish-9b1e6c5a3ccd943b7158dce83387fbfcc1162d69.zip
Merge "Make the size of "cb_handle_t" same for 32/64-bit"
Diffstat (limited to 'opengl/system')
-rw-r--r--opengl/system/OpenglSystemCommon/gralloc_cb.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/opengl/system/OpenglSystemCommon/gralloc_cb.h b/opengl/system/OpenglSystemCommon/gralloc_cb.h
index c138964..a0f6ed8 100644
--- a/opengl/system/OpenglSystemCommon/gralloc_cb.h
+++ b/opengl/system/OpenglSystemCommon/gralloc_cb.h
@@ -96,7 +96,11 @@ struct cb_handle_t : public native_handle {
int glType; // OpenGL type enum used when uploading to host
int ashmemSize; // ashmem region size for the buffer (0 unless is HW_FB buffer or
// s/w access is needed)
- intptr_t ashmemBase; // CPU address of the mapped ashmem region
+ union {
+ intptr_t ashmemBase; // CPU address of the mapped ashmem region
+ uint64_t padding; // enforce same size on 32-bit/64-bit
+ } __attribute__((aligned(8)));
+
int ashmemBasePid; // process id which mapped the ashmem region
int mappedPid; // process id which succeeded gralloc_register call
int lockedLeft; // region of buffer locked for s/w write