Framework Components Application Programming Interface (API)  fc-v07
ires_vicp.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2012, Texas Instruments Incorporated
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions
7  * are met:
8  *
9  * * Redistributions of source code must retain the above copyright
10  * notice, this list of conditions and the following disclaimer.
11  *
12  * * Redistributions in binary form must reproduce the above copyright
13  * notice, this list of conditions and the following disclaimer in the
14  * documentation and/or other materials provided with the distribution.
15  *
16  * * Neither the name of Texas Instruments Incorporated nor the names of
17  * its contributors may be used to endorse or promote products derived
18  * from this software without specific prior written permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
22  * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23  * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
24  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
25  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
26  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
27  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
29  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
30  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  *
32  */
48 #ifndef ti_sdo_fc_ires_vicp_IRES_VICP_
49 #define ti_sdo_fc_ires_vicp_IRES_VICP_
50 
53 
54 
55 #ifdef __cplusplus
56 extern "C" {
57 #endif
58 
59 #include <ti/xdais/ires_common.h>
60 
61 /*
62  * @brief Maximum number of VICP resources(components) to be managed
63  */
64 #define IRES_VICP_MAXRESOURCES 1
65 
69 #define IRES_VICP_PROTOCOLNAME "ti.sdo.fc.ires.vicp"
70 
79 #define VICP_MODNAME "ti.sdo.fc.ires.vicp"
80 
81 /*
82  * Note, we wrap the PROTOCOLVERSION in an ifdef so the
83  * resource managers and algs get this version data placed in their object
84  * files. Apps, which include rman.h, will have this 'NOPROTOCOLREV' defined.
85  */
86 #ifndef ti_sdo_fc_ires_NOPROTOCOLREV
87 
91 static IRES_ProtocolRevision IRES_VICP_PROTOCOLREVISION = {1, 0, 0};
92 
93 #endif
94 
99 
103 typedef struct IRES_VICP_ProtocolArgs {
104 
105  int size;
106  IRES_RequestMode mode; /* persistent or scratch resource requested */
107  short requestIMX; /* value of 1 to indicate resource requested,
108  0 otherwise */
109  short requestVLCD;
110  short requestSEQ;
111 
113 
119 typedef struct IRES_VICP_Obj {
120 
122  short assignedIMX;
124  short assignedSEQ;
125 
126 } IRES_VICP_Obj;
127 
128 
129 /*
130  * @brief VICP Register Layout
131  */
132 typedef struct IRES_VICP_Registers {
133 
134  int size;
136  unsigned char *vicp_umap1_base;
137  unsigned char *vicp_cfg_base;
138 
139  unsigned char *imgBuf_base;
140  unsigned char *imgBufA_base;
141  unsigned char *imgBufB_base;
142  unsigned char *imxCoeffBuff_base;
143  unsigned char *imxCmdBuf_base;
144  unsigned char *vlcdDataBuf_base;
145  unsigned char *qiqBuf_base;
146  unsigned char *vlcdBuf_base;
147  unsigned char *seqProgMem_base;
148  unsigned char *seqDataMem_base;
149 
150  unsigned int imgBuf_length;
151  unsigned int imgBufA_length;
152  unsigned int imgBufB_length;
153  unsigned int imxCoeffBuff_length;
154  unsigned int imxCmdBuf_length;
155  unsigned int vlcdDataBuf_length;
156  unsigned int qiqBuf_length;
157  unsigned int vlcdBuf_length;
158  unsigned int seqProgMem_length;
159  unsigned int seqDataMem_length;
160 
161  /* . . . */
162 
164 
165 
166 /*
167  * @brief Static Resource Properties
168  */
169 typedef struct IRES_VICP_Properties {
170 
171  int size;
172 
174 
176 
177 
178 #ifdef __cplusplus
179 }
180 #endif /* extern "C" */
181 
182 
185 #endif
struct IRES_VICP_ProtocolArgs IRES_VICP_ProtocolArgs
VICP Protocol Arguments definition.
short assignedIMX
Definition: ires_vicp.h:122
IRES_VICP_Obj extends the generic IRES_Obj structure that is returned back to the algorithm requestin...
Definition: ires_vicp.h:119
Definition: ires_vicp.h:169
short assignedVLCD
Definition: ires_vicp.h:123
Protocol revision type. Used to ensure the given 'protocol' revision can be validated.
Definition: ires_common.h:73
unsigned int imgBuf_length
Definition: ires_vicp.h:150
unsigned char * qiqBuf_base
Definition: ires_vicp.h:145
IRES Resource Protocol Definitions - IRES Resource.
unsigned int seqProgMem_length
Definition: ires_vicp.h:158
struct IRES_VICP_Registers IRES_VICP_Registers
short assignedSEQ
Definition: ires_vicp.h:124
unsigned char * vicp_cfg_base
Definition: ires_vicp.h:137
IRES_RequestMode mode
Definition: ires_vicp.h:106
unsigned int vlcdBuf_length
Definition: ires_vicp.h:157
IRES_Obj holds the private state associated with each logical resource.
Definition: ires_common.h:176
unsigned char * imxCmdBuf_base
Definition: ires_vicp.h:143
unsigned char * imxCoeffBuff_base
Definition: ires_vicp.h:142
unsigned char * vlcdDataBuf_base
Definition: ires_vicp.h:144
unsigned int imgBufA_length
Definition: ires_vicp.h:151
short requestIMX
Definition: ires_vicp.h:107
unsigned int imxCoeffBuff_length
Definition: ires_vicp.h:153
unsigned int seqDataMem_length
Definition: ires_vicp.h:159
int size
Definition: ires_vicp.h:105
Definition: ires_vicp.h:132
unsigned char * imgBufB_base
Definition: ires_vicp.h:141
short requestVLCD
Definition: ires_vicp.h:109
unsigned int imxCmdBuf_length
Definition: ires_vicp.h:154
unsigned char * seqProgMem_base
Definition: ires_vicp.h:147
unsigned int qiqBuf_length
Definition: ires_vicp.h:156
struct IRES_VICP_Obj * IRES_VICP_Handle
Handle to "logical" resource.
Definition: ires_vicp.h:98
unsigned char * vicp_umap1_base
Definition: ires_vicp.h:136
IRES_RequestMode
Mode in which resources can be requested.
Definition: ires_common.h:85
IRES_Obj ires
Definition: ires_vicp.h:121
int size
Definition: ires_vicp.h:134
struct IRES_VICP_Obj IRES_VICP_Obj
IRES_VICP_Obj extends the generic IRES_Obj structure that is returned back to the algorithm requestin...
struct IRES_VICP_Properties IRES_VICP_Properties
unsigned char * imgBufA_base
Definition: ires_vicp.h:140
unsigned char * imgBuf_base
Definition: ires_vicp.h:139
int size
Definition: ires_vicp.h:171
unsigned char * vlcdBuf_base
Definition: ires_vicp.h:146
short requestSEQ
Definition: ires_vicp.h:110
IRES_VICP_Registers * globalRegs
Definition: ires_vicp.h:173
unsigned int imgBufB_length
Definition: ires_vicp.h:152
unsigned char * seqDataMem_base
Definition: ires_vicp.h:148
VICP Protocol Arguments definition.
Definition: ires_vicp.h:103
unsigned int vlcdDataBuf_length
Definition: ires_vicp.h:155
Copyright 2016, Texas Instruments Incorporated