summaryrefslogtreecommitdiff
path: root/omx/base/omx_base_dio_plugin/src
diff options
context:
space:
mode:
authorSunita Nadampalli <sunitan@ti.com>2014-11-19 09:57:06 -0600
committerSunita Nadampalli <sunitan@ti.com>2014-11-19 09:57:06 -0600
commit99f8ab2e0805313fafd472c45c3c7750c1dbfb48 (patch)
treed7fb70b009c12fad43eedab4200ed8fbefaf0b72 /omx/base/omx_base_dio_plugin/src
parent185e4a24d7b1342c83dae76c2c86c582a1f08646 (diff)
downloaddra7xx-99f8ab2e0805313fafd472c45c3c7750c1dbfb48.tar.gz
OMX Base: Added OMX CORE and BASE class components
Change-Id: I0252480d66e5d1afcbf1d448674a2095c91fe77f Signed-off-by: Sunita Nadampalli <sunitan@ti.com>
Diffstat (limited to 'omx/base/omx_base_dio_plugin/src')
-rw-r--r--omx/base/omx_base_dio_plugin/src/omx_base_dio.c311
-rw-r--r--omx/base/omx_base_dio_plugin/src/omx_base_dio_non_tunnel.c652
-rw-r--r--omx/base/omx_base_dio_plugin/src/omx_base_dio_table.c31
3 files changed, 994 insertions, 0 deletions
diff --git a/omx/base/omx_base_dio_plugin/src/omx_base_dio.c b/omx/base/omx_base_dio_plugin/src/omx_base_dio.c
new file mode 100644
index 0000000..a97351e
--- /dev/null
+++ b/omx/base/omx_base_dio_plugin/src/omx_base_dio.c
@@ -0,0 +1,311 @@
+/*
+ * Copyright (C) Texas Instruments - http://www.ti.com/
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+#define LOG_TAG "OMX_BASE_DIO"
+
+#include <string.h>
+#include <omx_base.h>
+
+static OMX_PTR OMXBase_DIO_GetPort(OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex);
+/*
+* OMXBase DIO Init
+*/
+OMX_ERRORTYPE OMXBase_DIO_Init (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex,
+ OMX_STRING cChannelType,
+ OMX_PTR pCreateParams)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+ OMX_BOOL bFound = OMX_FALSE;
+ OMX_U32 i = 0;
+
+ OMX_COMPONENTTYPE *pComp = (OMX_COMPONENTTYPE *)hComponent;
+ OMXBaseComp *pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+
+ OMX_CHECK(NULL != cChannelType, OMX_ErrorBadParameter);
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ while( NULL != OMX_DIO_Registered[i].cChannelType ) {
+ if( strcmp(cChannelType, OMX_DIO_Registered[i].cChannelType) == 0 ) {
+ bFound = OMX_TRUE;
+ break;
+ }
+ i++;
+ }
+
+ if( bFound ) {
+ hDIO = (OMX_DIO_Object *) OSAL_Malloc(sizeof(OMX_DIO_Object));
+ OMX_CHECK(NULL != hDIO, OMX_ErrorInsufficientResources);
+ OSAL_Memset(hDIO, 0x0, sizeof(OMX_DIO_Object));
+
+ /* Initialize the DIO object depending on the ChannelType */
+ eError = OMX_DIO_Registered[i].pInitialize(hDIO, pCreateParams);
+ OMX_CHECK(OMX_ErrorNone == eError, eError);
+
+ /* Assign DIO handle to port */
+ pPort->hDIO = hDIO;
+ } else {
+ OMX_CHECK(OMX_FALSE, OMX_ErrorUndefined);
+ }
+
+EXIT:
+ return (eError);
+}
+
+/*
+* OMXBase DIO DeInit
+*/
+OMX_ERRORTYPE OMXBase_DIO_Deinit (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ eError = hDIO->deinit(hDIO);
+
+ OSAL_Free(pPort->hDIO);
+ pPort->hDIO = NULL;
+
+EXIT:
+ return (eError);
+}
+
+/*
+* OMXBase DIO Open
+*/
+OMX_ERRORTYPE OMXBase_DIO_Open (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex,
+ OMX_PTR pOpenParams)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ eError = hDIO->open(hDIO, (OMX_DIO_OpenParams *)pOpenParams);
+
+EXIT:
+ if( eError == OMX_ErrorNone ) {
+ hDIO->bOpened = OMX_TRUE;
+ }
+ return (eError);
+}
+
+/*
+* OMX Base DIO close
+*/
+OMX_ERRORTYPE OMXBase_DIO_Close (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ hDIO->bOpened = OMX_FALSE;
+ eError = hDIO->close(hDIO);
+
+EXIT:
+ return (eError);
+}
+
+/*
+* OMX Base DIO Queue
+*/
+OMX_ERRORTYPE OMXBase_DIO_Queue (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex,
+ OMX_PTR pBuffHeader)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ eError = hDIO->queue(hDIO, pBuffHeader);
+
+EXIT:
+ return (eError);
+}
+
+/*
+* OMXBase DIO Dequeue
+*/
+OMX_ERRORTYPE OMXBase_DIO_Dequeue (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex,
+ OMX_PTR *pBuffHeader)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ eError = hDIO->dequeue(hDIO, pBuffHeader);
+
+EXIT:
+ return (eError);
+}
+
+/*
+* OMXBase DIO Send
+*/
+OMX_ERRORTYPE OMXBase_DIO_Send (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex,
+ OMX_PTR pBuffHeader)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ eError = hDIO->send(hDIO, pBuffHeader);
+
+EXIT:
+ return (eError);
+}
+
+/*
+* OMXBase DIO Cancel
+*/
+OMX_ERRORTYPE OMXBase_DIO_Cancel (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex,
+ OMX_PTR pBuffHeader)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ eError = hDIO->cancel(hDIO, pBuffHeader);
+
+EXIT:
+ return (eError);
+}
+
+/*
+* OMXBase DIO Control
+*/
+OMX_ERRORTYPE OMXBase_DIO_Control (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex,
+ OMX_DIO_CtrlCmdType nCmdType,
+ OMX_PTR pParams)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ eError = hDIO->control(hDIO, nCmdType, pParams);
+
+EXIT:
+ return (eError);
+}
+
+/*
+* OMX Base DIO GetCount
+*/
+OMX_ERRORTYPE OMXBase_DIO_GetCount (OMX_HANDLETYPE hComponent,
+ OMX_U32 nPortIndex,
+ OMX_U32 *pCount)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ /*Resetting count to 0 initially*/
+ *pCount = 0;
+ pPort = OMXBase_DIO_GetPort(hComponent, nPortIndex);
+ OMX_CHECK(pPort != NULL, OMX_ErrorBadParameter);
+
+ hDIO = (OMX_DIO_Object *)pPort->hDIO;
+ OMX_CHECK(hDIO != NULL, OMX_ErrorBadParameter);
+
+ eError = hDIO->getcount(hDIO, pCount);
+
+EXIT:
+ return (eError);
+}
+
+
+/*
+* OMX Base DIO GetPort from the PortIndex
+*/
+static OMX_PTR OMXBase_DIO_GetPort(OMX_HANDLETYPE hComponent, OMX_U32 nPortIndex)
+{
+ OMX_COMPONENTTYPE *pComp = (OMX_COMPONENTTYPE *)hComponent;
+ OMXBaseComp *pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+ OMXBase_Port *pPort = NULL;
+ OMX_U32 nStartPortNumber = 0;
+
+ nStartPortNumber = pBaseComp->nMinStartPortIndex;
+ if( pBaseComp->pPorts == NULL ) {
+ pPort = NULL;
+ goto EXIT;
+ }
+ pPort = (OMXBase_Port *)pBaseComp->pPorts[nPortIndex - nStartPortNumber];
+
+EXIT:
+ return (pPort);
+}
+
+
+
+
diff --git a/omx/base/omx_base_dio_plugin/src/omx_base_dio_non_tunnel.c b/omx/base/omx_base_dio_plugin/src/omx_base_dio_non_tunnel.c
new file mode 100644
index 0000000..97ab8b6
--- /dev/null
+++ b/omx/base/omx_base_dio_plugin/src/omx_base_dio_non_tunnel.c
@@ -0,0 +1,652 @@
+/*
+ * Copyright (C) Texas Instruments - http://www.ti.com/
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#define LOG_TAG "OMX_BASE_DIO_NONTUNNEL"
+
+#include <omx_base.h>
+#include <memplugin.h>
+#include <OMX_TI_Custom.h>
+
+typedef struct DIO_NonTunnel_Attrs {
+ OMX_DIO_CreateParams sCreateParams;
+ OMX_U32 nFlags;
+ OMX_PTR pPipeHandle;
+ OMX_PTR pHdrPool;
+ OMX_PTR pPlatformPrivatePool;
+}DIO_NonTunnel_Attrs;
+
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Open (OMX_HANDLETYPE handle,
+ OMX_DIO_OpenParams *pParams);
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Close (OMX_HANDLETYPE handle);
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Queue (OMX_HANDLETYPE handle,
+ OMX_PTR pBuffHeader);
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Dequeue (OMX_HANDLETYPE handle,
+ OMX_PTR *pBuffHeader);
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Send (OMX_HANDLETYPE handle,
+ OMX_PTR pBuffHeader);
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Cancel (OMX_HANDLETYPE handle,
+ OMX_PTR pBuffHeader);
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Control (OMX_HANDLETYPE handle,
+ OMX_DIO_CtrlCmdType nCmdType,
+ OMX_PTR pParams);
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Getcount (OMX_HANDLETYPE handle,
+ OMX_U32 *pCount);
+
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Deinit (OMX_HANDLETYPE handle);
+
+/*
+* _DIO_GetPort from Port Index
+*/
+static OMX_PTR _DIO_GetPort(OMX_HANDLETYPE handle, OMX_U32 nPortIndex)
+{
+ OMX_COMPONENTTYPE *pComp;
+ OMXBaseComp *pBaseComp;
+ OMXBase_Port *pPort = NULL;
+ OMX_U32 nStartPortNumber = 0;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+
+ pComp = (OMX_COMPONENTTYPE *)(pContext->sCreateParams.hComponent);
+ pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+
+ nStartPortNumber = pBaseComp->nMinStartPortIndex;
+ if( pBaseComp->pPorts == NULL ) {
+ pPort = NULL;
+ goto EXIT;
+ }
+
+ pPort = (OMXBase_Port *)pBaseComp->pPorts[nPortIndex - nStartPortNumber];
+
+EXIT:
+ return (pPort);
+}
+
+/*
+* DIO NoneTunnel Init
+*/
+OMX_ERRORTYPE OMX_DIO_NonTunnel_Init(OMX_HANDLETYPE handle,
+ OMX_PTR pCreateParams)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+
+ OMX_COMPONENTTYPE *pComp = (OMX_COMPONENTTYPE *)(((OMX_DIO_CreateParams *)(pCreateParams))->hComponent);
+ OMXBaseComp *pBaseComPvt = (OMXBaseComp *)pComp->pComponentPrivate;
+
+ /* creating memory for DIO object private area */
+ hDIO->pContext = OSAL_Malloc(sizeof(DIO_NonTunnel_Attrs));
+ OMX_CHECK(NULL != hDIO->pContext, OMX_ErrorInsufficientResources);
+
+ OSAL_Memset(hDIO->pContext, 0x0, sizeof(DIO_NonTunnel_Attrs));
+
+ hDIO->open = OMX_DIO_NonTunnel_Open;
+ hDIO->close = OMX_DIO_NonTunnel_Close;
+ hDIO->queue = OMX_DIO_NonTunnel_Queue;
+ hDIO->dequeue = OMX_DIO_NonTunnel_Dequeue;
+ hDIO->send = OMX_DIO_NonTunnel_Send;
+ hDIO->cancel = OMX_DIO_NonTunnel_Cancel;
+ hDIO->control = OMX_DIO_NonTunnel_Control;
+ hDIO->getcount = OMX_DIO_NonTunnel_Getcount;
+ hDIO->deinit = OMX_DIO_NonTunnel_Deinit;
+
+ pContext = hDIO->pContext;
+ /* Initialize private data */
+ pContext->sCreateParams = *(OMX_DIO_CreateParams *)pCreateParams;
+
+EXIT:
+ return (eError);
+}
+
+/*
+* DIO NonTunnel DeInit
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Deinit (OMX_HANDLETYPE handle)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+ if( NULL != pContext ) {
+ OSAL_Free(pContext);
+ pContext = NULL;
+ }
+
+ return (eError);
+}
+
+/*
+* DIO NonTunnel Open
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Open (OMX_HANDLETYPE handle,
+ OMX_DIO_OpenParams *pParams)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OSAL_ERROR tStatus = OSAL_ErrNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ OMXBase_Port *pPort = NULL;
+ OMX_U32 i = 0;
+ OMX_U32 nPortIndex = 0;
+ OMX_U32 nStartPortNumber = 0;
+ OMX_U8 *pTmpBuffer = NULL;
+ OMX_U32 nLocalComBuffers = 0;
+ OMX_PTR *pBufArr = NULL;
+
+ OMX_COMPONENTTYPE *pComp = NULL;
+ OMXBaseComp *pBaseComp = NULL;
+
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+ pPort = (OMXBase_Port *)_DIO_GetPort(handle, pContext->sCreateParams.nPortIndex);
+ pComp = (OMX_COMPONENTTYPE *)(pContext->sCreateParams.hComponent);
+ pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+ nStartPortNumber = pBaseComp->nMinStartPortIndex;
+ nPortIndex = pContext->sCreateParams.nPortIndex;
+
+ /* supplier should allocate both the buffer and buffer headers
+ non supplier should allocate only the buffer headers */
+ pPort->pBufferlist = (OMX_BUFFERHEADERTYPE * *)OSAL_Malloc(
+ (pPort->sPortDef.nBufferCountActual * sizeof(OMX_BUFFERHEADERTYPE *)));
+
+ OMX_CHECK(NULL != pPort->pBufferlist, OMX_ErrorInsufficientResources);
+ OSAL_Memset(pPort->pBufferlist, 0, (pPort->sPortDef.nBufferCountActual
+ * sizeof(OMX_BUFFERHEADERTYPE *)));
+ /* create a buffer header pool */
+ pContext->pHdrPool = (OMX_PTR)OSAL_Malloc(sizeof(OMX_BUFFERHEADERTYPE)
+ * (pPort->sPortDef.nBufferCountActual));
+ OMX_CHECK(NULL != pContext->pHdrPool, OMX_ErrorInsufficientResources);
+ OSAL_Memset(pContext->pHdrPool, 0, sizeof(OMX_BUFFERHEADERTYPE) *
+ (pPort->sPortDef.nBufferCountActual));
+
+ pContext->pPlatformPrivatePool = (OMX_PTR)OSAL_Malloc(pPort->sPortDef.nBufferCountActual
+ * sizeof(OMXBase_BufHdrPvtData));
+ OMX_CHECK(NULL != pContext->pPlatformPrivatePool, OMX_ErrorInsufficientResources);
+
+ /*Setting platform port pvt pool to 0*/
+ OSAL_Memset(pContext->pPlatformPrivatePool, 0,
+ pPort->sPortDef.nBufferCountActual *
+ sizeof(OMXBase_BufHdrPvtData));
+
+ if( pPort->bIsBufferAllocator) {
+ //Setting up fields for calling configure
+ nLocalComBuffers = pBaseComp->pPorts[nPortIndex - nStartPortNumber]->sProps.
+ nNumComponentBuffers;
+ if( nLocalComBuffers != 1 && pBaseComp->
+ pPorts[nPortIndex - nStartPortNumber]->sProps.eBufMemoryType !=
+ MEM_TILER8_2D ) {
+ //For non 2D buffers multiple component buffers not supported
+ OMX_CHECK(OMX_FALSE, OMX_ErrorBadParameter);
+ }
+
+ pBufArr = OSAL_Malloc(sizeof(OMX_PTR) * nLocalComBuffers);
+ OMX_CHECK(NULL != pBufArr, OMX_ErrorInsufficientResources);
+ }
+
+ /* update buffer list with buffer and buffer headers */
+ for( i = 0; i < pPort->sPortDef.nBufferCountActual; i++ ) {
+ pPort->pBufferlist[i] = (OMX_BUFFERHEADERTYPE *)(pContext->pHdrPool) + i;
+ OMX_BASE_INIT_STRUCT_PTR(pPort->pBufferlist[i], OMX_BUFFERHEADERTYPE);
+ pPort->pBufferlist[i]->pPlatformPrivate =
+ (OMXBase_BufHdrPvtData *)(pContext->pPlatformPrivatePool) + i;
+
+ ((OMXBase_BufHdrPvtData *)(pPort->pBufferlist[i]->pPlatformPrivate))->bufSt = OWNED_BY_CLIENT;
+
+ if( pPort->bIsBufferAllocator) {
+ MemHeader *h = &(((OMXBase_BufHdrPvtData *)(pPort->pBufferlist[i]->pPlatformPrivate))->sMemHdr[0]);
+ pPort->pBufferlist[i]->pBuffer = memplugin_alloc_noheader(h, pParams->nBufSize, 1, MEM_CARVEOUT, 0, 0);
+ if( nLocalComBuffers == 2 ) {
+ OMX_CHECK(OMX_FALSE, OMX_ErrorNotImplemented);
+ }
+ }
+ }
+
+ /* create a fixed size OS pipe */
+ tStatus = OSAL_CreatePipe(&pContext->pPipeHandle,
+ (sizeof(OMX_BUFFERHEADERTYPE *) *
+ pPort->sPortDef.nBufferCountActual),
+ sizeof(OMX_BUFFERHEADERTYPE *), 1);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorInsufficientResources);
+ pPort->nCachedBufferCnt = pPort->sPortDef.nBufferCountActual;
+
+
+EXIT:
+ if( pBufArr != NULL ) {
+ OSAL_Free(pBufArr);
+ pBufArr = NULL;
+ }
+ if( OMX_ErrorNone != eError ) {
+ OMX_DIO_NonTunnel_Close(handle);
+ }
+ return (eError);
+}
+
+/*
+* DIO NonTunnel Close
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Close(OMX_HANDLETYPE handle)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OSAL_ERROR tStatus = OSAL_ErrNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ OMXBase_Port *pPort = NULL;
+ OMX_U32 i = 0, j =0, nPortIndex = 0, nStartPortNumber = 0, nCompBufs = 0;
+ OMX_PTR pTmpBuffer = NULL;
+ OMX_COMPONENTTYPE *pComp = NULL;
+ OMXBaseComp *pBaseComp = NULL;
+
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+ OMX_CHECK(pContext != NULL, OMX_ErrorNone);
+
+ pPort = (OMXBase_Port *)_DIO_GetPort(handle, pContext->sCreateParams.nPortIndex);
+ if( pPort ) {
+ pComp = (OMX_COMPONENTTYPE *)(pContext->sCreateParams.hComponent);
+ if( pComp ) {
+ pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+ }
+ if( pBaseComp ) {
+ nStartPortNumber = pBaseComp->nMinStartPortIndex;
+ nPortIndex = pPort->sPortDef.nPortIndex;
+ nCompBufs = pBaseComp->pPorts[nPortIndex - nStartPortNumber]->sProps.nNumComponentBuffers;
+ }
+ if( pPort->pBufferlist ) {
+ for( i = 0; i < pPort->nCachedBufferCnt; i++ ) {
+ if( pPort->pBufferlist[i] ) {
+ if( pPort->bIsBufferAllocator) {
+ MemHeader *h = &(((OMXBase_BufHdrPvtData *)(pPort->pBufferlist[i]->pPlatformPrivate))->sMemHdr[0]);
+ memplugin_free_noheader(h);
+ if( nCompBufs == 2 ) {
+ OMX_CHECK(OMX_FALSE, OMX_ErrorNotImplemented);
+ }
+ } else {
+ for ( j = 0; j < MAX_PLANES_PER_BUFFER; j++ ) {
+ if (((OMXBase_BufHdrPvtData *)(pPort->pBufferlist[i]->pPlatformPrivate))->sMemHdr[j].dma_buf_fd > 0) {
+ close(((OMXBase_BufHdrPvtData *)(pPort->pBufferlist[i]->pPlatformPrivate))->sMemHdr[j].dma_buf_fd);
+ }
+ }
+ }
+ }
+ }
+ /* freeup the buffer list */
+ OSAL_Free(pPort->pBufferlist);
+ pPort->pBufferlist = NULL;
+ pPort->nCachedBufferCnt = 0;
+ }
+ }
+
+ if( pContext->pPlatformPrivatePool ) {
+ OSAL_Free(pContext->pPlatformPrivatePool);
+ }
+ pContext->pPlatformPrivatePool = NULL;
+ if( pContext->pHdrPool ) {
+ OSAL_Free(pContext->pHdrPool);
+ }
+ pContext->pHdrPool = NULL;
+ /* delete a OS pipe */
+ if( pContext->pPipeHandle != NULL ) {
+ tStatus = OSAL_DeletePipe(pContext->pPipeHandle);
+ if( tStatus != OSAL_ErrNone ) {
+ eError = OMX_ErrorUndefined;
+ }
+ pContext->pPipeHandle = NULL;
+ }
+
+EXIT:
+ return (eError);
+}
+
+/*
+* DIO NonTunnel Queue
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Queue (OMX_HANDLETYPE handle,
+ OMX_PTR pBuffHeader)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OSAL_ERROR tStatus = OSAL_ErrNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ OMX_BUFFERHEADERTYPE *pOMXBufHeader;
+ OMXBase_Port *pPort;
+
+ pOMXBufHeader = (OMX_BUFFERHEADERTYPE *) pBuffHeader;
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+
+ pPort = (OMXBase_Port *)_DIO_GetPort(handle, pContext->sCreateParams.nPortIndex);
+ tStatus = OSAL_WriteToPipe(pContext->pPipeHandle, &pOMXBufHeader,
+ sizeof(pOMXBufHeader), OSAL_SUSPEND);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorUndefined);
+
+EXIT:
+ return (eError);
+}
+
+/*
+* DIO NonTunnel Dequeue
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Dequeue (OMX_HANDLETYPE handle,
+ OMX_PTR *pBuffHeader)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OSAL_ERROR tStatus = OSAL_ErrNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ OMXBase_Port *pPort;
+ uint32_t actualSize = 0;
+ OMX_BUFFERHEADERTYPE *pOrigOMXBufHeader = NULL;
+ OMX_COMPONENTTYPE *pComp = NULL;
+ OMXBaseComp *pBaseComp = NULL;
+ OMX_U32 nPortIndex, nTimeout;
+
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+ pPort = (OMXBase_Port *)_DIO_GetPort(handle, pContext->sCreateParams.nPortIndex);
+ pComp = (OMX_COMPONENTTYPE *)pContext->sCreateParams.hComponent;
+ pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+ nPortIndex = pPort->sPortDef.nPortIndex;
+ nTimeout = pBaseComp->pPorts[nPortIndex]->sProps.nTimeoutForDequeue;
+ /* dequeue the buffer from the data pipe */
+ tStatus = OSAL_ReadFromPipe(pContext->pPipeHandle, &pOrigOMXBufHeader,
+ sizeof(pOrigOMXBufHeader), &actualSize, nTimeout);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorUndefined);
+
+ /*Cancel the buffer and return warning so that derived component may call
+ GetAttribute*/
+ if( pOrigOMXBufHeader->nFlags & OMX_BUFFERFLAG_CODECCONFIG ) {
+ /*Reset codec config flag on o/p port*/
+ if( OMX_DirOutput == pPort->sPortDef.eDir ) {
+ pOrigOMXBufHeader->nFlags &= (~OMX_BUFFERFLAG_CODECCONFIG);
+ } else {
+ tStatus = OSAL_WriteToFrontOfPipe(pContext->pPipeHandle, &pOrigOMXBufHeader,
+ sizeof(pOrigOMXBufHeader), OSAL_NO_SUSPEND);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorUndefined);
+ eError = (OMX_ERRORTYPE)OMX_TI_WarningAttributePending;
+ goto EXIT;
+ }
+ }
+ *pBuffHeader = (OMX_PTR)pOrigOMXBufHeader;
+
+EXIT:
+ return (eError);
+}
+
+/*
+* DIO NonTunnel Send
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Send (OMX_HANDLETYPE handle,
+ OMX_PTR pBuffHeader)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ OMXBase_Port *pPort = NULL;
+ OMX_COMPONENTTYPE *pComp = NULL;
+ OMXBaseComp *pBaseComp = NULL;
+ OMX_CALLBACKTYPE *pAppCallbacks = NULL;
+ OMX_BUFFERHEADERTYPE *pOMXBufHeader;
+
+ pOMXBufHeader = (OMX_BUFFERHEADERTYPE *) pBuffHeader;
+
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+ pPort = (OMXBase_Port *)_DIO_GetPort(handle, pContext->sCreateParams.nPortIndex);
+ pComp = (OMX_COMPONENTTYPE *)pContext->sCreateParams.hComponent;
+ pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+ pAppCallbacks = (OMX_CALLBACKTYPE *)pContext->sCreateParams.pAppCallbacks;
+
+ /* return the buffer back to the Application using EBD or FBD
+ * depending on the direction of the port (input or output) */
+ if (((OMXBase_BufHdrPvtData *)(pOMXBufHeader->pPlatformPrivate))->bufSt != OWNED_BY_CLIENT) {
+ ((OMXBase_BufHdrPvtData *)(pOMXBufHeader->pPlatformPrivate))->bufSt = OWNED_BY_CLIENT;
+ if( OMX_DirInput == pPort->sPortDef.eDir ) {
+ eError = pAppCallbacks->EmptyBufferDone(pComp,
+ pComp->pApplicationPrivate, pOMXBufHeader);
+ } else if( OMX_DirOutput == pPort->sPortDef.eDir ) {
+ eError = pAppCallbacks->FillBufferDone(pComp,
+ pComp->pApplicationPrivate, pOMXBufHeader);
+ }
+ }
+EXIT:
+ return (eError);
+}
+
+/*
+* DIO NonTunnel Cancel
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Cancel (OMX_HANDLETYPE handle,
+ OMX_PTR pBuffHeader)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OSAL_ERROR tStatus = OSAL_ErrNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ OMXBase_Port *pPort = NULL;
+ OMX_BUFFERHEADERTYPE *pOMXBufHeader;
+ OMX_COMPONENTTYPE *pComp;
+ OMXBaseComp *pBaseComp;
+ OMXBaseComp_Pvt *pBaseCompPvt;
+ OMX_BOOL bCallProcess = OMX_FALSE;
+
+ pOMXBufHeader = (OMX_BUFFERHEADERTYPE *) pBuffHeader;
+
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+ pPort = (OMXBase_Port*)_DIO_GetPort(handle, pContext->sCreateParams.nPortIndex);
+
+ pComp = (OMX_COMPONENTTYPE *)pContext->sCreateParams.hComponent;
+ pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+ pBaseCompPvt = (OMXBaseComp_Pvt *)pBaseComp->pPvtData;
+
+ tStatus = OSAL_WriteToFrontOfPipe(pContext->pPipeHandle, &pOMXBufHeader,
+ sizeof(pOMXBufHeader), OSAL_NO_SUSPEND);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorUndefined);
+
+ if( bCallProcess ) {
+ /*Calling process fn so that event to process the buffer can be generated*/
+ pBaseCompPvt->fpInvokeProcessFunction(pComp, DATAEVENT);
+ }
+
+EXIT:
+ return (eError);
+}
+
+
+/*
+* DIO NonTunnel Control
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Control (OMX_HANDLETYPE handle,
+ OMX_DIO_CtrlCmdType nCmdType,
+ OMX_PTR pParams)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OSAL_ERROR tStatus = OSAL_ErrNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ OMXBase_Port *pPort = NULL;
+ OMX_COMPONENTTYPE *pComp = NULL;
+ OMXBaseComp *pBaseComp = NULL;
+ OMXBaseComp_Pvt *pBaseCompPvt = NULL;
+ OMX_CALLBACKTYPE *pAppCallbacks = NULL;
+ OMX_BUFFERHEADERTYPE *pBuffHeader = NULL;
+ MemHeader *pAttrDesc = NULL;
+ uint32_t elementsInpipe = 0;
+ uint32_t actualSize = 0;
+
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+ pComp = (OMX_COMPONENTTYPE *)pContext->sCreateParams.hComponent;
+ pBaseComp = (OMXBaseComp *)pComp->pComponentPrivate;
+ pBaseCompPvt = (OMXBaseComp_Pvt *)pBaseComp->pPvtData;
+ pPort = (OMXBase_Port *)_DIO_GetPort(handle, pContext->sCreateParams.nPortIndex);
+ pAppCallbacks = (OMX_CALLBACKTYPE *)pContext->sCreateParams.pAppCallbacks;
+
+ switch( nCmdType ) {
+ /* Flush the queues or buffers on a port. Both Flush and Stop perform
+ the same operation i.e. send all the buffers back to the client */
+ case OMX_DIO_CtrlCmd_Stop :
+ case OMX_DIO_CtrlCmd_Flush :
+ /* return all buffers to the IL client using EBD/FBD depending
+ * on the direction(input or output) of port */
+
+ OSAL_GetPipeReadyMessageCount(pContext->pPipeHandle, &elementsInpipe);
+
+ while( elementsInpipe ) {
+ OSAL_ReadFromPipe(pContext->pPipeHandle, &pBuffHeader,
+ sizeof(pBuffHeader), &actualSize, OSAL_NO_SUSPEND);
+ elementsInpipe--;
+ if (((OMXBase_BufHdrPvtData *)(pBuffHeader->pPlatformPrivate))->bufSt != OWNED_BY_CLIENT) {
+ ((OMXBase_BufHdrPvtData *)(pBuffHeader->pPlatformPrivate))->bufSt = OWNED_BY_CLIENT;
+ if( OMX_DirInput == pPort->sPortDef.eDir ) {
+ eError = pAppCallbacks->EmptyBufferDone(pComp,
+ pComp->pApplicationPrivate, pBuffHeader);
+ } else if( OMX_DirOutput == pPort->sPortDef.eDir ) {
+ pBuffHeader->nFilledLen = 0;
+ eError = pAppCallbacks->FillBufferDone(pComp,
+ pComp->pApplicationPrivate, pBuffHeader);
+ }
+ }
+ }
+ break;
+
+ case OMX_DIO_CtrlCmd_Start :
+ /*If there are buffers in the pipe in case of pause to executing
+ then start processing them*/
+ OSAL_GetPipeReadyMessageCount(pContext->pPipeHandle, &elementsInpipe);
+ if( elementsInpipe ) {
+ pBaseCompPvt->fpInvokeProcessFunction(pComp, DATAEVENT);
+ } else {
+ OSAL_ErrorTrace(" Nothing to do ");
+ }
+ break;
+
+ case OMX_DIO_CtrlCmd_GetCtrlAttribute :
+ /*Buffer should be available when calling GetAttribute*/
+ tStatus = OSAL_IsPipeReady(pContext->pPipeHandle);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorUndefined);
+
+ tStatus = OSAL_ReadFromPipe(pContext->pPipeHandle, &pBuffHeader,
+ sizeof(pBuffHeader), &actualSize, OSAL_NO_SUSPEND);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorUndefined);
+ if( !(pBuffHeader->nFlags & OMX_BUFFERFLAG_CODECCONFIG)) {
+ /*This buffer does not contain codec config*/
+ eError = OMX_ErrorUndefined;
+ /*Write the buffer back to front of pipe*/
+ OSAL_WriteToFrontOfPipe(pContext->pPipeHandle, &pBuffHeader,
+ sizeof(pBuffHeader), OSAL_SUSPEND);
+ goto EXIT;
+ }
+ pAttrDesc = ((OMXBase_CodecConfigBuf*)pParams)->sBuffer;
+ if( pAttrDesc->size < pBuffHeader->nFilledLen ) {
+ tStatus = OSAL_WriteToFrontOfPipe(pContext->pPipeHandle,
+ &pBuffHeader, sizeof(pBuffHeader), OSAL_SUSPEND);
+ pAttrDesc->size = pBuffHeader->nFilledLen;
+
+ eError = (OMX_ERRORTYPE)OMX_TI_WarningInsufficientAttributeSize;
+ goto EXIT;
+ }
+ pAttrDesc->size = pBuffHeader->nFilledLen;
+ OSAL_Memcpy(H2P(pAttrDesc), pBuffHeader->pBuffer + pBuffHeader->nOffset,
+ pAttrDesc->size);
+
+ /*Send the buffer back*/
+ pBuffHeader->nFlags &= (~OMX_BUFFERFLAG_CODECCONFIG);
+ if (((OMXBase_BufHdrPvtData *)(pBuffHeader->pPlatformPrivate))->bufSt != OWNED_BY_CLIENT) {
+ ((OMXBase_BufHdrPvtData *)(pBuffHeader->pPlatformPrivate))->bufSt = OWNED_BY_CLIENT;
+ if( OMX_DirInput == pPort->sPortDef.eDir ) {
+ eError = pAppCallbacks->EmptyBufferDone(pComp,
+ pComp->pApplicationPrivate, pBuffHeader);
+ } else if( OMX_DirOutput == pPort->sPortDef.eDir ) {
+ /*So that the other port does not try to interpret any garbage
+ data that may be present*/
+ pBuffHeader->nFilledLen = 0;
+ eError = pAppCallbacks->FillBufferDone(pComp,
+ pComp->pApplicationPrivate, pBuffHeader);
+ }
+ }
+ break;
+
+ case OMX_DIO_CtrlCmd_SetCtrlAttribute :
+ /*Buffer should be available when calling SetAttribute*/
+ tStatus = OSAL_IsPipeReady(pContext->pPipeHandle);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorUndefined);
+
+ tStatus = OSAL_ReadFromPipe(pContext->pPipeHandle, &pBuffHeader,
+ sizeof(pBuffHeader), &actualSize, OSAL_NO_SUSPEND);
+ OMX_CHECK(OSAL_ErrNone == tStatus, OMX_ErrorUndefined);
+
+ pBuffHeader->nFlags |= OMX_BUFFERFLAG_CODECCONFIG;
+ pAttrDesc = ((OMXBase_CodecConfigBuf *)pParams)->sBuffer;
+ if( pBuffHeader->nAllocLen < pAttrDesc->size ) {
+ OSAL_ErrorTrace("Cannot send attribute data, size is too large");
+ tStatus = OSAL_WriteToFrontOfPipe(pContext->pPipeHandle,
+ &pBuffHeader, sizeof(pBuffHeader), OSAL_SUSPEND);
+ eError = OMX_ErrorInsufficientResources;
+ goto EXIT;
+ }
+ pBuffHeader->nFilledLen = pAttrDesc->size;
+ OSAL_Memcpy(pBuffHeader->pBuffer, pAttrDesc->ptr, pAttrDesc->size);
+ if (((OMXBase_BufHdrPvtData *)(pBuffHeader->pPlatformPrivate))->bufSt != OWNED_BY_CLIENT) {
+ ((OMXBase_BufHdrPvtData *)(pBuffHeader->pPlatformPrivate))->bufSt = OWNED_BY_CLIENT;
+ /*Send the buffer*/
+ if( OMX_DirInput == pPort->sPortDef.eDir ) {
+ eError = pAppCallbacks->EmptyBufferDone(pComp,
+ pComp->pApplicationPrivate, pBuffHeader);
+ } else if( OMX_DirOutput == pPort->sPortDef.eDir ) {
+ eError = pAppCallbacks->FillBufferDone(pComp,
+ pComp->pApplicationPrivate, pBuffHeader);
+ }
+ }
+ break;
+
+ default :
+ OSAL_ErrorTrace(" Invalid Command received \n");
+ eError = OMX_ErrorUnsupportedIndex;
+ break;
+ }
+
+EXIT:
+ return (eError);
+}
+
+
+/*
+* DIO Non Tunnel GEtCount
+*/
+static OMX_ERRORTYPE OMX_DIO_NonTunnel_Getcount (OMX_HANDLETYPE handle,
+ OMX_U32 *pCount)
+{
+ OMX_ERRORTYPE eError = OMX_ErrorNone;
+ OMX_DIO_Object *hDIO = (OMX_DIO_Object *)handle;
+ DIO_NonTunnel_Attrs *pContext = NULL;
+ OMXBase_Port *pPort = NULL;
+
+ pContext = (DIO_NonTunnel_Attrs *)hDIO->pContext;
+ pPort = (OMXBase_Port *)_DIO_GetPort(handle, pContext->sCreateParams.nPortIndex);
+ if( pPort->bEosRecd && pPort->sPortDef.eDir == OMX_DirInput ) {
+ eError = (OMX_ERRORTYPE)OMX_TI_WarningEosReceived;
+ }
+
+ OSAL_GetPipeReadyMessageCount(pContext->pPipeHandle, (uint32_t*)pCount);
+
+ return (eError);
+}
+
+
diff --git a/omx/base/omx_base_dio_plugin/src/omx_base_dio_table.c b/omx/base/omx_base_dio_plugin/src/omx_base_dio_table.c
new file mode 100644
index 0000000..e6ec96b
--- /dev/null
+++ b/omx/base/omx_base_dio_plugin/src/omx_base_dio_table.c
@@ -0,0 +1,31 @@
+/*
+ * Copyright (C) Texas Instruments - http://www.ti.com/
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <string.h>
+#include "omx_base_internal.h"
+#include "omx_base_dio_plugin.h"
+
+
+extern OMX_ERRORTYPE OMX_DIO_NonTunnel_Init(OMX_HANDLETYPE handle,
+ OMX_PTR pCreateParams);
+
+OMX_DIO_Register OMX_DIO_Registered[] =
+{
+ { "OMX.DIO.NONTUNNEL", &OMX_DIO_NonTunnel_Init },
+ { NULL, NULL }
+
+};
+