summaryrefslogtreecommitdiff
path: root/driver
diff options
context:
space:
mode:
authorTim Murray <timmurray@google.com>2014-06-10 09:46:51 -0700
committerTim Murray <timmurray@google.com>2014-06-10 10:24:42 -0700
commite3af53b643677c40d228ffd3624cf259f4dc68ed (patch)
tree87ece7302c71da8ac9cfc514fd220787033a3b1b /driver
parent5e0109a20a4c6c950c0e4938a204acb4dec82d7e (diff)
downloadrs-e3af53b643677c40d228ffd3624cf259f4dc68ed.tar.gz
Update structs and defines for 64-bit.
Also adds RS_FIND_OFFSETS, which prints address info for various types that allow us to easily update __pad. Change-Id: I4d57248e155d113c83ff69f4f8f64160aa24fb9b
Diffstat (limited to 'driver')
-rw-r--r--driver/rsdAllocation.cpp7
-rw-r--r--driver/runtime/rs_structs.h16
2 files changed, 23 insertions, 0 deletions
diff --git a/driver/rsdAllocation.cpp b/driver/rsdAllocation.cpp
index f488b55b..05951b96 100644
--- a/driver/rsdAllocation.cpp
+++ b/driver/rsdAllocation.cpp
@@ -463,6 +463,13 @@ bool rsdAllocationInit(const Context *rsc, Allocation *alloc, bool forceZero) {
rsdAllocationData2D(rsc, alloc, 0, 0, 0, RS_ALLOCATION_CUBEMAP_FACE_POSITIVE_X, alloc->getType()->getDimX(), alloc->getType()->getDimY(), alloc->mHal.state.userProvidedPtr, allocSize, 0);
}
+
+#ifdef RS_FIND_OFFSETS
+ ALOGE("pointer for allocation: %p", alloc);
+ ALOGE("pointer for allocation.drv: %p", &alloc->mHal.drv);
+#endif
+
+
return true;
}
diff --git a/driver/runtime/rs_structs.h b/driver/runtime/rs_structs.h
index 80c129cc..e35cd54f 100644
--- a/driver/runtime/rs_structs.h
+++ b/driver/runtime/rs_structs.h
@@ -25,7 +25,11 @@ typedef enum {
} rs_allocation_mipmap_control;
typedef struct Allocation {
+#ifndef __LP64__
char __pad[32];
+#else
+ char __pad[56];
+#endif
struct {
void * drv;
struct {
@@ -145,7 +149,11 @@ typedef struct ProgramRaster {
*
*****************************************************************************/
typedef struct Sampler {
+#ifndef __LP64__
char __pad[32];
+#else
+ char __pad[56];
+#endif
struct {
void *drv;
struct {
@@ -177,7 +185,11 @@ typedef struct Sampler {
*
*****************************************************************************/
typedef struct Element {
+#ifndef __LP64__
char __pad[32];
+#else
+ char __pad[56];
+#endif
struct {
void *drv;
struct {
@@ -215,7 +227,11 @@ typedef struct Element {
*
*****************************************************************************/
typedef struct Type {
+#ifndef __LP64__
char __pad[32];
+#else
+ char __pad[56];
+#endif
struct {
void *drv;
struct {