[android-sdk/device-ti-proprietary-open.git] / jacinto6 / sgx_src / eurasia_km / services4 / include / servicesint.h
diff --git a/jacinto6/sgx_src/eurasia_km/services4/include/servicesint.h b/jacinto6/sgx_src/eurasia_km/services4/include/servicesint.h
index 7b09afbd394de709a2293a30a668bf7c8abbdb8a..2ae1a3bc033dbc603611cd7f940728a072c8cfde 100644 (file)
PVRSRV_MEMTYPE_WRAPPED = 3,
PVRSRV_MEMTYPE_MAPPED = 4,
PVRSRV_MEMTYPE_ION = 5,
+ PVRSRV_MEMTYPE_ALLOC = 6,
+ PVRSRV_MEMTYPE_FREE = 7
} PVRSRV_MEMTYPE;
+#if defined (MEM_TRACK_INFO_DEBUG)
+/* Threshold on number of latest operations to track*/
+#define MAX_MEM_TRACK_OPS 512
+typedef struct _PVRSRV_MEM_TRACK_INFO_
+{
+ IMG_DEV_VIRTADDR sDevVAddr;
+ IMG_SIZE_T uSize;
+ IMG_UINT32 ui32Pid;
+ IMG_UINT32 ui32RefCount;
+ PVRSRV_MEMTYPE eOp;
+ IMG_UINT32 ui32TimeStampUSecs;
+ IMG_CHAR asTaskName[128];
+ IMG_CHAR heapId[128];
+ struct _PVRSRV_MEM_TRACK_INFO_ *next;
+ struct _PVRSRV_MEM_TRACK_INFO_ *prev;
+
+} PVRSRV_MEM_TRACK_INFO;
+#endif
/*
Kernel Memory Information structure
*/
/* ptr to associated kernel sync info - NULL if no sync */
struct _PVRSRV_KERNEL_SYNC_INFO_ *psKernelSyncInfo;
- PVRSRV_MEMTYPE memType;
-
- IMG_VOID *bvmap_handle;
+ IMG_HANDLE hIonSyncInfo;
- /* Device Virtual Address Offsets for the YUV MM planes */
- IMG_UINT32 planeOffsets[PVRSRV_MAX_NUMBER_OF_MM_BUFFER_PLANES];
+ PVRSRV_MEMTYPE memType;
/*
To activate the "share mem workaround", add PVRSRV_MEM_XPROC to
IMG_UINT32 ui32OrigReqSize;
IMG_UINT32 ui32OrigReqAlignment;
} sShareMemWorkaround;
+#if defined (MEM_TRACK_INFO_DEBUG)
+ IMG_CHAR heapId[128];
+#endif
} PVRSRV_KERNEL_MEM_INFO;
/* Unique ID of the sync object */
IMG_UINT32 ui32UID;
+
+ /* Pointer for list manager */
+ struct _PVRSRV_KERNEL_SYNC_INFO_ *psNext;
+ struct _PVRSRV_KERNEL_SYNC_INFO_ **ppsThis;
+
+#if defined(SUPPORT_PER_SYNC_DEBUG)
+#define PER_SYNC_HISTORY 10
+ IMG_UINT32 ui32OperationMask;
+ IMG_UINT32 aui32OpInfo[PER_SYNC_HISTORY];
+ IMG_UINT32 aui32ReadOpSample[PER_SYNC_HISTORY];
+ IMG_UINT32 aui32WriteOpSample[PER_SYNC_HISTORY];
+ IMG_UINT32 aui32ReadOp2Sample[PER_SYNC_HISTORY];
+ IMG_UINT32 ui32HistoryIndex;
+#endif
+
} PVRSRV_KERNEL_SYNC_INFO;
/*!
allocated on back of this structure, i.e. is resident in Q */
PFN_QUEUE_COMMAND_COMPLETE pfnCommandComplete; /*!< Command complete callback */
IMG_HANDLE hCallbackData; /*!< Command complete callback data */
+
+#if defined(PVR_ANDROID_NATIVE_WINDOW_HAS_SYNC)
+ IMG_VOID *pvCleanupFence; /*!< Sync fence to 'put' after timeline inc() */
+ IMG_VOID *pvTimeline; /*!< Android sync timeline to inc() */
+#endif
}PVRSRV_COMMAND, *PPVRSRV_COMMAND;
IMG_VOID *pvLinQueueUM; /*!< Pointer to the command buffer in the user's
address space */
- volatile IMG_SIZE_T ui32ReadOffset; /*!< Index into the buffer at which commands are being
+ volatile IMG_SIZE_T uReadOffset; /*!< Index into the buffer at which commands are being
consumed */
- volatile IMG_SIZE_T ui32WriteOffset; /*!< Index into the buffer at which commands are being
+ volatile IMG_SIZE_T uWriteOffset; /*!< Index into the buffer at which commands are being
added */
IMG_UINT32 *pui32KickerAddrKM; /*!< kicker address in the kernel's
IMG_UINT32 *pui32KickerAddrUM; /*!< kicker address in the user's
address space */
- IMG_SIZE_T ui32QueueSize; /*!< Size in bytes of the buffer - excluding the safety allocation */
+ IMG_SIZE_T uQueueSize; /*!< Size in bytes of the buffer - excluding the safety allocation */
IMG_UINT32 ui32ProcessID; /*!< Process ID required by resource locking */
IMG_HANDLE hMemBlock[2];
+#if defined(PVR_ANDROID_NATIVE_WINDOW_HAS_SYNC)
+ IMG_UINT32 ui32FenceValue; /*!< 'Target' timeline value when fence signals */
+ IMG_VOID *pvTimeline; /*!< Android struct sync_timeline object */
+#endif
+
struct _PVRSRV_QUEUE_INFO_ *psNextKM; /*!< The next queue in the system */
}PVRSRV_QUEUE_INFO;
*/
typedef struct PVRSRV_CLIENT_DEVICECLASS_INFO_TAG
{
-#if defined (SUPPORT_SID_INTERFACE)
- IMG_SID hDeviceKM;
-#else
IMG_HANDLE hDeviceKM;
-#endif
IMG_HANDLE hServices;
} PVRSRV_CLIENT_DEVICECLASS_INFO;
IMG_IMPORT PVRSRV_ERROR IMG_CALLCONV
PVRSRVAllocSharedSysMem(const PVRSRV_CONNECTION *psConnection,
IMG_UINT32 ui32Flags,
- IMG_SIZE_T ui32Size,
+ IMG_SIZE_T uSize,
PVRSRV_CLIENT_MEM_INFO **ppsClientMemInfo);
/*!
********************************************************************************/
IMG_IMPORT PVRSRV_ERROR IMG_CALLCONV
PVRSRVMapMemInfoMem(const PVRSRV_CONNECTION *psConnection,
-#if defined (SUPPORT_SID_INTERFACE)
- IMG_SID hKernelMemInfo,
-#else
IMG_HANDLE hKernelMemInfo,
-#endif
PVRSRV_CLIENT_MEM_INFO **ppsClientMemInfo);
+#if defined(MEM_TRACK_INFO_DEBUG)
+IMG_IMPORT IMG_VOID PVRSRVPrintMemTrackInfo(IMG_UINT32 ui32FaultAddr);
+IMG_IMPORT IMG_VOID PVRSRVAddMemTrackInfo(PVRSRV_MEM_TRACK_INFO *psMemTrackInfo);
+IMG_IMPORT IMG_VOID PVRSRVFreeMemOps(IMG_VOID);
+#endif
#if defined (__cplusplus)