| 1 | /*************************************************************************** |
|---|
| 2 | * Copyright (c) 2003-2012, Broadcom Corporation |
|---|
| 3 | * All Rights Reserved |
|---|
| 4 | * Confidential Property of Broadcom Corporation |
|---|
| 5 | * |
|---|
| 6 | * THIS SOFTWARE MAY ONLY BE USED SUBJECT TO AN EXECUTED SOFTWARE LICENSE |
|---|
| 7 | * AGREEMENT BETWEEN THE USER AND BROADCOM. YOU HAVE NO RIGHT TO USE OR |
|---|
| 8 | * EXPLOIT THIS MATERIAL EXCEPT SUBJECT TO THE TERMS OF SUCH AN AGREEMENT. |
|---|
| 9 | * |
|---|
| 10 | * $brcm_Workfile: bxpt.h $ |
|---|
| 11 | * $brcm_Revision: Hydra_Software_Devel/56 $ |
|---|
| 12 | * $brcm_Date: 3/8/12 3:41p $ |
|---|
| 13 | * |
|---|
| 14 | * Porting interface code for the data transport core. |
|---|
| 15 | * |
|---|
| 16 | * Revision History: |
|---|
| 17 | * |
|---|
| 18 | * $brcm_Log: /magnum/portinginterface/xpt/base2/bxpt.h $ |
|---|
| 19 | * |
|---|
| 20 | * Hydra_Software_Devel/56 3/8/12 3:41p gmullen |
|---|
| 21 | * SW7425-2497: Merged to Hydra |
|---|
| 22 | * |
|---|
| 23 | * Hydra_Software_Devel/55 3/8/12 1:42p gmullen |
|---|
| 24 | * SW7435-53: Merged to Hydra |
|---|
| 25 | * |
|---|
| 26 | * Hydra_Software_Devel/SW7435-53/1 3/8/12 11:17a gmullen |
|---|
| 27 | * SW7435-53: Fixed hole in timebase mapping |
|---|
| 28 | * |
|---|
| 29 | * Hydra_Software_Devel/54 3/7/12 2:41p gmullen |
|---|
| 30 | * SW7325-879: Added BXPT_HAS_PACKETSUB_FORCED_INSERTION around code |
|---|
| 31 | * |
|---|
| 32 | * Hydra_Software_Devel/SW7425-2497/2 3/8/12 3:19p gmullen |
|---|
| 33 | * SW7425-2497: Added BXPT_HAS_PIPELINE_ERROR_REPORTING around code |
|---|
| 34 | * |
|---|
| 35 | * Hydra_Software_Devel/SW7425-2497/1 3/5/12 4:30p gmullen |
|---|
| 36 | * SW7425-2497: Checks for errors in data pipeline |
|---|
| 37 | * |
|---|
| 38 | * Hydra_Software_Devel/53 2/29/12 10:22a gmullen |
|---|
| 39 | * SW7346-718: Increased BXPT_NUM_PCRS |
|---|
| 40 | * |
|---|
| 41 | * Hydra_Software_Devel/52 2/3/12 12:02p jtna |
|---|
| 42 | * SW7425-2248: add BXPT_P_ParserClients.ToMpodRs |
|---|
| 43 | * |
|---|
| 44 | * Hydra_Software_Devel/51 1/12/12 2:40p gmullen |
|---|
| 45 | * SW7425-2138: Fixed incorrect parser band index |
|---|
| 46 | * |
|---|
| 47 | * Hydra_Software_Devel/50 1/11/12 10:32a gmullen |
|---|
| 48 | * SW7425-2138: Added BXPT_HAS_PB_PACKETSUB |
|---|
| 49 | * |
|---|
| 50 | * Hydra_Software_Devel/49 1/2/12 3:12p gmullen |
|---|
| 51 | * SW7360-1: Added support |
|---|
| 52 | * |
|---|
| 53 | * Hydra_Software_Devel/48 1/2/12 1:47p gmullen |
|---|
| 54 | * SW7435-10: Merge to Hydra |
|---|
| 55 | * |
|---|
| 56 | * Hydra_Software_Devel/SW7435-10/3 12/20/11 5:04p mward |
|---|
| 57 | * SW7435-10: Merge from main. |
|---|
| 58 | * |
|---|
| 59 | * Hydra_Software_Devel/47 12/20/11 4:27p gmullen |
|---|
| 60 | * SW7425-1868: Merged to Hydra |
|---|
| 61 | * |
|---|
| 62 | * Hydra_Software_Devel/SW7425-1868/1 12/20/11 4:24p gmullen |
|---|
| 63 | * SW7425-1868: Added filter offset support |
|---|
| 64 | * |
|---|
| 65 | * Hydra_Software_Devel/46 12/20/11 1:29p gmullen |
|---|
| 66 | * SW7358-176: Merged to Hydra |
|---|
| 67 | * |
|---|
| 68 | * Hydra_Software_Devel/SW7358-176/1 12/20/11 1:05p gmullen |
|---|
| 69 | * SW7358-175: Added per-client control of XC and RS buffer alloc |
|---|
| 70 | * |
|---|
| 71 | * Hydra_Software_Devel/SW7435-10/2 12/2/11 3:37p mward |
|---|
| 72 | * SW7435-10: Merge from main. |
|---|
| 73 | * |
|---|
| 74 | * Hydra_Software_Devel/45 12/2/11 12:13p jtna |
|---|
| 75 | * SW7425-1863: refactor xpt standby power management |
|---|
| 76 | * |
|---|
| 77 | * Hydra_Software_Devel/44 11/30/11 2:59p gmullen |
|---|
| 78 | * SW7425-1871: Merged to Hydra |
|---|
| 79 | * |
|---|
| 80 | * Hydra_Software_Devel/SW7425-1871/1 11/30/11 2:52p gmullen |
|---|
| 81 | * SW7425-1871: Added BXPT_NUM_MESSAGE_CAPABLE_PID_CHANNELS |
|---|
| 82 | * |
|---|
| 83 | * Hydra_Software_Devel/43 11/29/11 4:47p gmullen |
|---|
| 84 | * SW7429-3: Fixed incorrect number of TPIT blocks |
|---|
| 85 | * |
|---|
| 86 | * Hydra_Software_Devel/SW7435-10/1 10/31/11 4:01p mward |
|---|
| 87 | * SW7435-10: Initial 7435 support. Adapted from 7425 to allow |
|---|
| 88 | * appframework to compile. |
|---|
| 89 | * |
|---|
| 90 | * Hydra_Software_Devel/42 10/28/11 4:15p jtna |
|---|
| 91 | * SW7425-1486: remove BXPT_GetMesgBufferErrorStatus() in favor of |
|---|
| 92 | * BXPT_Mesg_GetErrorStatus() |
|---|
| 93 | * |
|---|
| 94 | * Hydra_Software_Devel/41 10/28/11 4:03p jtna |
|---|
| 95 | * SW7425-1486: added BXPT_Mesg_GetErrorStatus() |
|---|
| 96 | * |
|---|
| 97 | * Hydra_Software_Devel/40 10/19/11 8:06p gmullen |
|---|
| 98 | * SW7425-1491: Removed API. |
|---|
| 99 | * |
|---|
| 100 | * Hydra_Software_Devel/39 10/19/11 5:27p gmullen |
|---|
| 101 | * SW7425-1491: Added BXPT_P_RxMode() |
|---|
| 102 | * |
|---|
| 103 | * Hydra_Software_Devel/38 10/12/11 5:26p gmullen |
|---|
| 104 | * SW7425-1487: Inverted RxClockPol for certain parts |
|---|
| 105 | * |
|---|
| 106 | * Hydra_Software_Devel/37 10/11/11 3:41p gmullen |
|---|
| 107 | * SW7425-1383: Changed allPass macros |
|---|
| 108 | * |
|---|
| 109 | * Hydra_Software_Devel/36 10/10/11 10:49a gmullen |
|---|
| 110 | * SW7429-3: Merged to Hydra |
|---|
| 111 | * |
|---|
| 112 | * Hydra_Software_Devel/SW7429-3/1 10/10/11 10:43a gmullen |
|---|
| 113 | * SW7429-3: Added support |
|---|
| 114 | * |
|---|
| 115 | * Hydra_Software_Devel/35 10/6/11 4:47p gmullen |
|---|
| 116 | * SW7425-1384: Merged change to Hydra |
|---|
| 117 | * |
|---|
| 118 | * Hydra_Software_Devel/SW7425-1384/1 10/6/11 2:19p gmullen |
|---|
| 119 | * SW7425-1384: Added define for playback all-pass starting PID channel. |
|---|
| 120 | * |
|---|
| 121 | * Hydra_Software_Devel/34 10/5/11 5:43p gmullen |
|---|
| 122 | * SW7425-1183: Added BXPT_HAS_WAKEUP_PKT_SUPPORT to flag parts with this |
|---|
| 123 | * feature |
|---|
| 124 | * |
|---|
| 125 | * Hydra_Software_Devel/33 10/5/11 4:25p gmullen |
|---|
| 126 | * SW7346-502: Merged to Hydra |
|---|
| 127 | * |
|---|
| 128 | * Hydra_Software_Devel/SW7346-502/1 10/5/11 4:03p gmullen |
|---|
| 129 | * SW7346-502: Added AcceptAdapt00 support |
|---|
| 130 | * |
|---|
| 131 | * Hydra_Software_Devel/32 9/30/11 3:10p gmullen |
|---|
| 132 | * SW7425-1183: Merged to Hydra |
|---|
| 133 | * |
|---|
| 134 | * Hydra_Software_Devel/SW7425-1183/1 8/30/11 9:05a gmullen |
|---|
| 135 | * SW7425-1183: Acquire the CLK216 resource when entering standby |
|---|
| 136 | * |
|---|
| 137 | * Hydra_Software_Devel/31 9/28/11 11:47a gmullen |
|---|
| 138 | * SW7425-1323: Cached RAVE settings in DRAM to reduce overhead |
|---|
| 139 | * |
|---|
| 140 | * Hydra_Software_Devel/30 9/21/11 10:17a gmullen |
|---|
| 141 | * SW7425-1323: Merged to Hydra |
|---|
| 142 | * |
|---|
| 143 | * Hydra_Software_Devel/SW7425-1323/1 9/21/11 10:02a gmullen |
|---|
| 144 | * SW7425-1323: Potential workaround. |
|---|
| 145 | * |
|---|
| 146 | * Hydra_Software_Devel/29 9/8/11 1:18p gmullen |
|---|
| 147 | * SW7552-99: Merged support to Hydra |
|---|
| 148 | * |
|---|
| 149 | * Hydra_Software_Devel/SW7552-99/1 9/8/11 12:51p gmullen |
|---|
| 150 | * SW7552-99: Added B0 support |
|---|
| 151 | * |
|---|
| 152 | * Hydra_Software_Devel/28 9/2/11 1:41p gmullen |
|---|
| 153 | * SW7425-690: Merged support to Hydra |
|---|
| 154 | * |
|---|
| 155 | * Hydra_Software_Devel/SW7425-690/1 9/2/11 1:38p gmullen |
|---|
| 156 | * SW7425-690: Added B0 defines |
|---|
| 157 | * |
|---|
| 158 | * Hydra_Software_Devel/27 8/29/11 5:09p gmullen |
|---|
| 159 | * SW7344-147: Merged support to Hydra |
|---|
| 160 | * |
|---|
| 161 | * Hydra_Software_Devel/SW7344-147/1 8/29/11 5:08p gmullen |
|---|
| 162 | * SW7344-147: Added B0 support |
|---|
| 163 | * |
|---|
| 164 | * Hydra_Software_Devel/26 8/29/11 3:34p gmullen |
|---|
| 165 | * SW7346-419: Merged changes to Hydra |
|---|
| 166 | * |
|---|
| 167 | * Hydra_Software_Devel/SW7346-419/1 8/29/11 3:20p gmullen |
|---|
| 168 | * SW7346-419: Added B0 support |
|---|
| 169 | * |
|---|
| 170 | * Hydra_Software_Devel/25 8/22/11 5:45p gmullen |
|---|
| 171 | * SW7231-319: Merged to Hydra branch |
|---|
| 172 | * |
|---|
| 173 | * Hydra_Software_Devel/SW7231-319/1 8/16/11 2:15p gmullen |
|---|
| 174 | * SW7231-319: Initial support for B0 |
|---|
| 175 | * |
|---|
| 176 | * Hydra_Software_Devel/24 8/10/11 4:32p gmullen |
|---|
| 177 | * SW7346-414: Merged to Hydra |
|---|
| 178 | * |
|---|
| 179 | * Hydra_Software_Devel/SW7346-414/1 8/9/11 11:00a gmullen |
|---|
| 180 | * SW7346-414: Mark all 40nm chips as having AVS. |
|---|
| 181 | * |
|---|
| 182 | * Hydra_Software_Devel/23 7/15/11 9:05a gmullen |
|---|
| 183 | * SW7346-308: Merged fix to Hydra |
|---|
| 184 | * |
|---|
| 185 | * Hydra_Software_Devel/SW7346-308/1 7/14/11 4:58p gmullen |
|---|
| 186 | * SW7346-308: Added BXPT_RemoveFilterFromGroupAndBuffer() and |
|---|
| 187 | * BXPT_Mesg_GetPidChannelFromBufferNum(), editted comments in bxpt.h |
|---|
| 188 | * |
|---|
| 189 | * Hydra_Software_Devel/22 5/12/11 4:59p gmullen |
|---|
| 190 | * SW7231-128: Merged to mainline |
|---|
| 191 | * |
|---|
| 192 | * Hydra_Software_Devel/SW7231-128/1 5/10/11 1:40p gmohile |
|---|
| 193 | * SW7231-128 : Add power management support |
|---|
| 194 | * Hydra_Software_Devel/21 5/3/11 3:38p gmullen |
|---|
| 195 | * SW7425-494: Default MTSIF RX clock polarity to negative edge |
|---|
| 196 | * |
|---|
| 197 | * Hydra_Software_Devel/20 4/18/11 1:31p gmullen |
|---|
| 198 | * SW7425-313: Added PID parser mapping to other 40nm chips |
|---|
| 199 | * |
|---|
| 200 | * Hydra_Software_Devel/19 4/15/11 4:49p gmullen |
|---|
| 201 | * SW7425-313: Merged to mainline |
|---|
| 202 | * |
|---|
| 203 | * Hydra_Software_Devel/SW7425-313/1 4/13/11 2:05p gmullen |
|---|
| 204 | * SW7425-313: Added parser remapping support |
|---|
| 205 | * |
|---|
| 206 | * Hydra_Software_Devel/18 3/30/11 11:14a gmullen |
|---|
| 207 | * SWDTV-6265: Free-running timebase select was incorrect |
|---|
| 208 | * |
|---|
| 209 | * Hydra_Software_Devel/17 3/23/11 5:12p gmullen |
|---|
| 210 | * SW7346-124: Do not allocate XC buffers for unused remux blocks |
|---|
| 211 | * |
|---|
| 212 | * Hydra_Software_Devel/16 3/22/11 4:03p gmullen |
|---|
| 213 | * SW7425-223: BXPT_NUM_STCS incorrect for 7422 |
|---|
| 214 | * |
|---|
| 215 | * Hydra_Software_Devel/15 3/8/11 9:58a gmullen |
|---|
| 216 | * SW7425-156: Fixed incorrect blockout calculations |
|---|
| 217 | * |
|---|
| 218 | * Hydra_Software_Devel/14 2/14/11 4:44p gmullen |
|---|
| 219 | * SW7420-750: Changed BXPT_P_IS_PB macro to avoid issue with CodeWarrior |
|---|
| 220 | * |
|---|
| 221 | * Hydra_Software_Devel/13 1/7/11 3:19p gmullen |
|---|
| 222 | * SWBLURAY-23703: Added PI support |
|---|
| 223 | * |
|---|
| 224 | * Hydra_Software_Devel/12 12/3/10 5:22p gmullen |
|---|
| 225 | * SW7422-87: Added per-PID channel R-pipe support for mesg filters |
|---|
| 226 | * |
|---|
| 227 | * Hydra_Software_Devel/11 12/3/10 3:20p gmullen |
|---|
| 228 | * SW7425-15: Allow setting the initial CC for generation |
|---|
| 229 | * |
|---|
| 230 | * Hydra_Software_Devel/10 11/30/10 6:09p gmullen |
|---|
| 231 | * SW7425-15: Added TS muxing support |
|---|
| 232 | * |
|---|
| 233 | * Hydra_Software_Devel/9 11/18/10 5:21p gmullen |
|---|
| 234 | * SW7344-2: Initial checkin |
|---|
| 235 | * |
|---|
| 236 | * Hydra_Software_Devel/8 11/18/10 5:13p gmullen |
|---|
| 237 | * SW7346-3: Initial checkin |
|---|
| 238 | * |
|---|
| 239 | * Hydra_Software_Devel/7 11/18/10 4:58p gmullen |
|---|
| 240 | * SW7231-6: Initial checkin |
|---|
| 241 | * |
|---|
| 242 | * Hydra_Software_Devel/6 11/1/10 10:47a gmullen |
|---|
| 243 | * SW7552-3: Added support for the 7552 |
|---|
| 244 | * |
|---|
| 245 | * Hydra_Software_Devel/5 10/28/10 3:30p gmullen |
|---|
| 246 | * SW7358-12: Updated PI for the 7358 |
|---|
| 247 | * |
|---|
| 248 | * Hydra_Software_Devel/4 10/28/10 2:08p gmullen |
|---|
| 249 | * SW7422-20: Checkin ported files |
|---|
| 250 | * |
|---|
| 251 | * Hydra_Software_Devel/3 10/27/10 5:24p gmullen |
|---|
| 252 | * SW7422-20: Added macros to generate Int IDs for CC, TEI, and Parser |
|---|
| 253 | * Length errors |
|---|
| 254 | * |
|---|
| 255 | * Hydra_Software_Devel/2 10/25/10 5:32p gmullen |
|---|
| 256 | * SW7422-20: Changed _P_MAX defines to _NUM |
|---|
| 257 | * |
|---|
| 258 | * Hydra_Software_Devel/1 10/25/10 2:09p gmullen |
|---|
| 259 | * SW7425-15: Moved srcs to base2 folder |
|---|
| 260 | * |
|---|
| 261 | * Hydra_Software_Devel/2 10/25/10 9:11a gmullen |
|---|
| 262 | * SW7425-15: Updated headers and added stub versions of C files |
|---|
| 263 | * |
|---|
| 264 | * Hydra_Software_Devel/1 10/8/10 2:57p gmullen |
|---|
| 265 | * SW7425-15: Added header files |
|---|
| 266 | * |
|---|
| 267 | * Hydra_Software_Devel/95 9/13/10 3:05p gmullen |
|---|
| 268 | * SW7125-632: Added BXPT_HAS_AVS to identify which chips where RAVE does |
|---|
| 269 | * not automatically index startcode 0x00 |
|---|
| 270 | * |
|---|
| 271 | * Hydra_Software_Devel/94 8/27/10 3:46p gmullen |
|---|
| 272 | * SW35230-1172: Merged to mainline |
|---|
| 273 | * |
|---|
| 274 | * Hydra_Software_Devel/SW35230-1172/1 8/27/10 2:16p gmullen |
|---|
| 275 | * SW35230-1172: Added BXPT_CheckBufferWithWrap() |
|---|
| 276 | * |
|---|
| 277 | * Hydra_Software_Devel/93 7/29/10 1:59p gmullen |
|---|
| 278 | * SW7420-904: Added RMX_NULL_PKT_THRESHOLD |
|---|
| 279 | * |
|---|
| 280 | * Hydra_Software_Devel/92 7/28/10 6:21p gmullen |
|---|
| 281 | * SWBLURAY-21763: Fixed compilation bug for 7630B0 |
|---|
| 282 | * |
|---|
| 283 | * Hydra_Software_Devel/91 7/19/10 4:21p piyushg |
|---|
| 284 | * SW7400-2859: Change the MAX TPIT to 6 for 7400B0 and later. |
|---|
| 285 | * |
|---|
| 286 | * Hydra_Software_Devel/90 7/6/10 11:40a gmullen |
|---|
| 287 | * SW7630-81: Fixed compilation bug for 7125 |
|---|
| 288 | * |
|---|
| 289 | * Hydra_Software_Devel/89 7/4/10 5:33p gmullen |
|---|
| 290 | * SW7630-81: Added support for QUICK |
|---|
| 291 | * |
|---|
| 292 | * Hydra_Software_Devel/88 4/30/10 5:23p gmullen |
|---|
| 293 | * SW7630-81: Created branch |
|---|
| 294 | * |
|---|
| 295 | * Hydra_Software_Devel/87 4/2/10 5:11p gmullen |
|---|
| 296 | * SW7405-4165: Fixed inconsistent API descriptions |
|---|
| 297 | * |
|---|
| 298 | * Hydra_Software_Devel/86 3/25/10 3:53p gmullen |
|---|
| 299 | * SW35230-127: Updated code for requirements in this JIRA |
|---|
| 300 | * |
|---|
| 301 | * Hydra_Software_Devel/85 3/1/10 3:05p gmullen |
|---|
| 302 | * SW7550-16: Fixed incorrect defines for number of PCR offsets and STCs |
|---|
| 303 | * |
|---|
| 304 | * Hydra_Software_Devel/84 1/25/10 11:54a gmullen |
|---|
| 305 | * SW7408-64: Added DirecTV support |
|---|
| 306 | * |
|---|
| 307 | * Hydra_Software_Devel/83 1/8/10 5:45p gmullen |
|---|
| 308 | * SW7550-179: Define for number of TPIT indexers was incorrect |
|---|
| 309 | * |
|---|
| 310 | * Hydra_Software_Devel/82 12/17/09 9:34a gmullen |
|---|
| 311 | * SW7630-62: Merged fix to mainline |
|---|
| 312 | * |
|---|
| 313 | * Hydra_Software_Devel/SW7630-62/1 12/17/09 9:13a gmullen |
|---|
| 314 | * SW7630-62: Buffer enums were incorrect |
|---|
| 315 | * |
|---|
| 316 | * Hydra_Software_Devel/81 12/16/09 3:26p gmullen |
|---|
| 317 | * SW7325-665: Added support for 32-bit timestamp mode |
|---|
| 318 | * |
|---|
| 319 | * Hydra_Software_Devel/80 12/9/09 2:46p gmullen |
|---|
| 320 | * SW7405-3331: Merged to mainline |
|---|
| 321 | * |
|---|
| 322 | * Hydra_Software_Devel/79 11/23/09 5:14p gmullen |
|---|
| 323 | * SW7468-13: Updated PI and unit test |
|---|
| 324 | * |
|---|
| 325 | * Hydra_Software_Devel/78 11/17/09 3:07p gmullen |
|---|
| 326 | * SW7408-9: Finished adding 7408 support to XPT |
|---|
| 327 | * |
|---|
| 328 | * Hydra_Software_Devel/77 10/26/09 3:09p gmullen |
|---|
| 329 | * SW7468-13: Added XPT support |
|---|
| 330 | * |
|---|
| 331 | * Hydra_Software_Devel/76 10/22/09 9:30a gmullen |
|---|
| 332 | * SW7630-46: Added DVD change for BXPT_Playback_CheckHeadDescriptor |
|---|
| 333 | * |
|---|
| 334 | * Hydra_Software_Devel/75 9/24/09 5:27p gmullen |
|---|
| 335 | * SWDEPRECATED-3717: Added BXPT_GetDefaultPsiSettings() and |
|---|
| 336 | * BXPT_GetDefaultPidChannelRecordSettings() |
|---|
| 337 | * |
|---|
| 338 | * Hydra_Software_Devel/74 9/16/09 2:57p piyushg |
|---|
| 339 | * SW3548-2479: Added new API BXPT_GetBuffer_isr which directly calls |
|---|
| 340 | * BXPT_UpdateReadOffset_isr() to avoid entering into critical section. |
|---|
| 341 | * |
|---|
| 342 | * Hydra_Software_Devel/73 9/14/09 10:15a gmullen |
|---|
| 343 | * SW35230-2: Added case for 35230 |
|---|
| 344 | * |
|---|
| 345 | * Hydra_Software_Devel/72 9/9/09 8:05a piyushg |
|---|
| 346 | * SW7630-30: Add 7630 XPT PI support. |
|---|
| 347 | * Added directory element "7630". |
|---|
| 348 | * |
|---|
| 349 | * Hydra_Software_Devel/71 9/2/09 2:06p piyushg |
|---|
| 350 | * SW7325-582: Added API in bxpt_mesg.c to disable the pid channel |
|---|
| 351 | * to message buffer association that is created after calling the |
|---|
| 352 | * ConfigPid2BufferMap. |
|---|
| 353 | * |
|---|
| 354 | * Hydra_Software_Devel/70 8/31/09 3:23p gmullen |
|---|
| 355 | * SW7342-32:Added BXPT_SetPidChannelSwitchedISR() |
|---|
| 356 | * |
|---|
| 357 | * Hydra_Software_Devel/69 8/31/09 2:39p gmullen |
|---|
| 358 | * SW7342-34: Reduced number of playbacks to 2 for A0. |
|---|
| 359 | * |
|---|
| 360 | * Hydra_Software_Devel/68 8/19/09 12:14p piyushg |
|---|
| 361 | * PR56771: Add support for 7342. Hence the previous usage |
|---|
| 362 | * of constant PARSER_REG_STEPSIZE does not work for this chip. |
|---|
| 363 | * Added new function to calculate offset. |
|---|
| 364 | * |
|---|
| 365 | * Hydra_Software_Devel/67 8/11/09 11:13a piyushg |
|---|
| 366 | * PR55216: Fix compilation error. |
|---|
| 367 | * |
|---|
| 368 | * Hydra_Software_Devel/66 8/11/09 10:38a piyushg |
|---|
| 369 | * PR55216: Added initial 7340 XPT support. |
|---|
| 370 | * |
|---|
| 371 | * Hydra_Software_Devel/65 8/7/09 2:03p gmullen |
|---|
| 372 | * PR57524: Enabled scrambling control support in RAVE, to match new RDB |
|---|
| 373 | * header. |
|---|
| 374 | * |
|---|
| 375 | * Hydra_Software_Devel/64 8/5/09 4:51p piyushg |
|---|
| 376 | * PR55545: Add 7125 XPT PI support |
|---|
| 377 | * Added file element "bxpt_rave_ihex.c". |
|---|
| 378 | * Added file element "bxpt_rave_ihex.h". |
|---|
| 379 | * |
|---|
| 380 | * Hydra_Software_Devel/63 7/31/09 5:39p gmullen |
|---|
| 381 | * PR54331: Fixed compilation errors in 7118. |
|---|
| 382 | * |
|---|
| 383 | * Hydra_Software_Devel/62 7/31/09 3:20p piyushg |
|---|
| 384 | * PR56771: Add support for 7342. |
|---|
| 385 | * |
|---|
| 386 | * Hydra_Software_Devel/61 7/31/09 2:44p gmullen |
|---|
| 387 | * PR54331: Added 35130 to XPT support. |
|---|
| 388 | * |
|---|
| 389 | * Hydra_Software_Devel/60 7/29/09 11:38a gmullen |
|---|
| 390 | * PR57174: Added 7420B0 support. |
|---|
| 391 | * |
|---|
| 392 | * Hydra_Software_Devel/59 7/17/09 1:49p gmullen |
|---|
| 393 | * PR52986: Message buffer support wasn't enabled. |
|---|
| 394 | * |
|---|
| 395 | * Hydra_Software_Devel/58 7/14/09 10:20a piyushg |
|---|
| 396 | * PR56771: Add XPT PI code for 7342. |
|---|
| 397 | * |
|---|
| 398 | * Hydra_Software_Devel/57 6/18/09 8:51a gmullen |
|---|
| 399 | * PR56110: Removed PID remapping feature from remux code. Not supported |
|---|
| 400 | * on this part. |
|---|
| 401 | * |
|---|
| 402 | * Hydra_Software_Devel/56 6/17/09 6:46p gmullen |
|---|
| 403 | * PR56110: Added support.xpt/7550/uif_image/a0 |
|---|
| 404 | * |
|---|
| 405 | * Hydra_Software_Devel/55 6/8/09 6:04p gmullen |
|---|
| 406 | * PR55700: Added BXPT_IsDataPresent(). |
|---|
| 407 | * |
|---|
| 408 | * Hydra_Software_Devel/54 6/8/09 3:12p gmullen |
|---|
| 409 | * PR55814: Updated comments and removed redundant definitions in |
|---|
| 410 | * bxpt_mesg.h . |
|---|
| 411 | * |
|---|
| 412 | * Hydra_Software_Devel/53 5/28/09 2:11p gmullen |
|---|
| 413 | * PR55549: Added support for PCR-based pacing. |
|---|
| 414 | * |
|---|
| 415 | * Hydra_Software_Devel/52 4/29/09 1:40p gmullen |
|---|
| 416 | * PR54619: Fixed compilation bug for 7335. |
|---|
| 417 | * |
|---|
| 418 | * Hydra_Software_Devel/51 4/28/09 6:41p gmullen |
|---|
| 419 | * PR54619: Changed conditional compile checks for GetScramblingCtrl API. |
|---|
| 420 | * |
|---|
| 421 | * Hydra_Software_Devel/50 4/19/09 9:35a gmullen |
|---|
| 422 | * PR53662: Added hook to determine if XPT can be powered down. |
|---|
| 423 | * |
|---|
| 424 | * Hydra_Software_Devel/49 4/7/09 5:25p piyushg |
|---|
| 425 | * PR52986: Add support for 7635 |
|---|
| 426 | * Added directory element "7635". |
|---|
| 427 | * |
|---|
| 428 | * Hydra_Software_Devel/48 3/26/09 7:22p piyushg |
|---|
| 429 | * PR53632: Changed the MAX_PID_PARSER for 7420 to 6 from 7. |
|---|
| 430 | * This was causing GISB timout error on initialization. |
|---|
| 431 | * |
|---|
| 432 | * Hydra_Software_Devel/47 1/27/09 1:09p gmullen |
|---|
| 433 | * PR51625: Added 7336 support |
|---|
| 434 | * |
|---|
| 435 | * Hydra_Software_Devel/46 1/5/09 10:03a gmullen |
|---|
| 436 | * PR50811: Added _isr version of BXPT_UpdateReadOffset(). |
|---|
| 437 | * |
|---|
| 438 | * Hydra_Software_Devel/45 12/15/08 2:36p gmullen |
|---|
| 439 | * PR48908: Removed power management code from XPT PI. |
|---|
| 440 | * |
|---|
| 441 | * Hydra_Software_Devel/44 11/26/08 4:14p gmullen |
|---|
| 442 | * PR47755: Added support for 7420. |
|---|
| 443 | * |
|---|
| 444 | * Hydra_Software_Devel/43 11/6/08 11:24a gmullen |
|---|
| 445 | * PR46544: Added public PI call to incr/decr power reference count. |
|---|
| 446 | * |
|---|
| 447 | * Hydra_Software_Devel/42 10/30/08 1:14p gmullen |
|---|
| 448 | * PR46544: Fixed spelling error in define. |
|---|
| 449 | * |
|---|
| 450 | * Hydra_Software_Devel/41 10/29/08 9:20a gmullen |
|---|
| 451 | * PR46544: Fixed compile error: code was built for unsupported chips. |
|---|
| 452 | * |
|---|
| 453 | * Hydra_Software_Devel/40 10/28/08 6:18p gmullen |
|---|
| 454 | * PR46544: Default power management to ON. Added compile-time support to |
|---|
| 455 | * disable power management. |
|---|
| 456 | * |
|---|
| 457 | * Hydra_Software_Devel/39 10/28/08 4:58p gmullen |
|---|
| 458 | * PR46544: Added power management support, default to disabled for now. |
|---|
| 459 | * |
|---|
| 460 | * Hydra_Software_Devel/38 8/18/08 3:58p gmullen |
|---|
| 461 | * PR45362: Number of playback channels that support muxing should be |
|---|
| 462 | * programmable. |
|---|
| 463 | * |
|---|
| 464 | * Hydra_Software_Devel/37 8/8/08 5:47p gmullen |
|---|
| 465 | * PR45362: Merged SanJose_CDI_Devel changes to Hydra_Software_Devel |
|---|
| 466 | * |
|---|
| 467 | * Hydra_Software_Devel/SanJose_CDI_Devel/4 8/4/08 11:10a bhsu |
|---|
| 468 | * PR45362 : Fixed Kernel oops for AM21. |
|---|
| 469 | * |
|---|
| 470 | * Hydra_Software_Devel/36 7/16/08 3:43p gmullen |
|---|
| 471 | * PR37867: Merged playback mux code to Hydra_Software_Devel |
|---|
| 472 | * |
|---|
| 473 | * Hydra_Software_Devel/35 6/26/08 6:30p gmullen |
|---|
| 474 | * PR43907: Added comments to description of BXPT_ParserAllPassMode |
|---|
| 475 | * |
|---|
| 476 | * Hydra_Software_Devel/34 6/18/08 4:52p piyushg |
|---|
| 477 | * PR39234:Fix compilation error. |
|---|
| 478 | * |
|---|
| 479 | * Hydra_Software_Devel/33 6/18/08 4:11p piyushg |
|---|
| 480 | * PR39234: Change some comments and API names for setting up |
|---|
| 481 | * multiple message buffers for same PID channel. |
|---|
| 482 | * |
|---|
| 483 | * Hydra_Software_Devel/32 6/16/08 11:55a piyushg |
|---|
| 484 | * PR39234: Change some comments and API names for setting up |
|---|
| 485 | * multiple message buffers for same PID channel. |
|---|
| 486 | * |
|---|
| 487 | * Hydra_Software_Devel/31 4/10/08 3:36p gmullen |
|---|
| 488 | * PR38954: Updated number of playbacks, added HDDVI support to PCR API, |
|---|
| 489 | * and added packetizer support. |
|---|
| 490 | * |
|---|
| 491 | * Hydra_Software_Devel/30 3/26/08 11:23a gmullen |
|---|
| 492 | * PR38954: Added 3548 support to XPT PI. |
|---|
| 493 | * |
|---|
| 494 | * Hydra_Software_Devel/29 3/17/08 1:03p gmullen |
|---|
| 495 | * PR40675: Added support to route all mesg filter data on R-pipe. |
|---|
| 496 | * |
|---|
| 497 | * Hydra_Software_Devel/28 2/28/08 3:56p piyushg |
|---|
| 498 | * PR38891: Change the BXPT_P_MAX_PID_CHANNELS from 255 to 256. |
|---|
| 499 | * |
|---|
| 500 | * Hydra_Software_Devel/27 11/28/07 10:42a gmullen |
|---|
| 501 | * PR36900: Added 7335 support |
|---|
| 502 | * |
|---|
| 503 | * Hydra_Software_Devel/26 10/19/07 4:52p gmullen |
|---|
| 504 | * PR35018: Updated for 7325/ |
|---|
| 505 | * |
|---|
| 506 | * Hydra_Software_Devel/25 9/28/07 11:16a gmullen |
|---|
| 507 | * PR35427: Added BXPT_GetDefaultParserConfig() and |
|---|
| 508 | * BXPT_GetDefaultInputBandConfig() |
|---|
| 509 | * |
|---|
| 510 | * Hydra_Software_Devel/24 9/13/07 1:36p gmullen |
|---|
| 511 | * PR32868: Changes to support bmsglib |
|---|
| 512 | * |
|---|
| 513 | * Hydra_Software_Devel/23 7/18/07 3:35p gmullen |
|---|
| 514 | * PR29691: Incorporated workaround. See PR for details. |
|---|
| 515 | * |
|---|
| 516 | * Hydra_Software_Devel/22 5/17/07 2:48p katrep |
|---|
| 517 | * PR29057: Added BXPT_GetMesgBufferErrorStatus api |
|---|
| 518 | * |
|---|
| 519 | * Hydra_Software_Devel/21 5/17/07 2:17p gmullen |
|---|
| 520 | * PR30877: Added support for dedicated playback heap handle. |
|---|
| 521 | * |
|---|
| 522 | * Hydra_Software_Devel/20 2/14/07 1:09p gmullen |
|---|
| 523 | * PR27642: Added support for 7405. |
|---|
| 524 | * |
|---|
| 525 | * Hydra_Software_Devel/19 2/6/07 7:05p gmullen |
|---|
| 526 | * PR26217: Added B0 support. |
|---|
| 527 | * |
|---|
| 528 | * Hydra_Software_Devel/18 12/5/06 3:00p gmullen |
|---|
| 529 | * PR26325: Added support for CAP filtering. |
|---|
| 530 | * |
|---|
| 531 | * Hydra_Software_Devel/17 12/5/06 2:04p gmullen |
|---|
| 532 | * PR26278: Allow user to configure byte alignment of data in message |
|---|
| 533 | * buffer. |
|---|
| 534 | * |
|---|
| 535 | * Hydra_Software_Devel/16 11/17/06 5:34p gmullen |
|---|
| 536 | * PR26034: Fixed BXPT_Remux_AllocPidMap(). |
|---|
| 537 | * |
|---|
| 538 | * Hydra_Software_Devel/15 11/15/06 3:22p gmullen |
|---|
| 539 | * PR15309: Added BXPT_P_EnablePidChannel. |
|---|
| 540 | * |
|---|
| 541 | * Hydra_Software_Devel/14 11/2/06 3:05p katrep |
|---|
| 542 | * PR25278: Added PidChannelNum argument to BXPT_AddFilterToGroup API. |
|---|
| 543 | * |
|---|
| 544 | * Hydra_Software_Devel/13 11/2/06 2:42p gmullen |
|---|
| 545 | * PR25402: Added handle for secure heap |
|---|
| 546 | * |
|---|
| 547 | * Hydra_Software_Devel/12 8/17/06 6:01p katrep |
|---|
| 548 | * PR23114: Added Support for 7440 chip |
|---|
| 549 | * |
|---|
| 550 | * Hydra_Software_Devel/11 8/10/06 2:51p gmullen |
|---|
| 551 | * PR23189: Added defines for 3563. |
|---|
| 552 | * |
|---|
| 553 | * Hydra_Software_Devel/10 8/4/06 5:16p katrep |
|---|
| 554 | * PR23114: Added support for 7440 |
|---|
| 555 | * |
|---|
| 556 | * Hydra_Software_Devel/9 8/2/06 3:56p gmullen |
|---|
| 557 | * PR23137: Added support for playback data to PCR block. |
|---|
| 558 | * |
|---|
| 559 | * Hydra_Software_Devel/8 7/21/06 12:17p katrep |
|---|
| 560 | * PR21525: Added support for 128,16 byte filters across 4 banks or |
|---|
| 561 | * 64,32byte filters across 2 banks. |
|---|
| 562 | * |
|---|
| 563 | * Hydra_Software_Devel/7 7/17/06 5:19p gmullen |
|---|
| 564 | * PR20624: Added code for 7118. |
|---|
| 565 | * |
|---|
| 566 | * Hydra_Software_Devel/6 7/13/06 11:37a katrep |
|---|
| 567 | * PR20316: Added support to set/unset PSI setting per pid channel basis |
|---|
| 568 | * as it's supported by new HW arch.PR20315:Also added support for 32 |
|---|
| 569 | * byte filters.Default filter size is 16 bytes.32 Bytes filters can be |
|---|
| 570 | * enabled at compile time by -DBXPT_FILTER_32 |
|---|
| 571 | * |
|---|
| 572 | * Hydra_Software_Devel/5 7/12/06 5:54p gmullen |
|---|
| 573 | * PR21042: XC and RS buffers can be customized to reduce total memory |
|---|
| 574 | * needs. |
|---|
| 575 | * |
|---|
| 576 | * Hydra_Software_Devel/4 6/5/06 5:54p gmullen |
|---|
| 577 | * PR18998: Added support for control of ACCEPT_ADAPT_00 in parser regs. |
|---|
| 578 | * |
|---|
| 579 | * Hydra_Software_Devel/3 4/12/06 10:34a gmullen |
|---|
| 580 | * PR20631: Added compilation checks for 7401 B0 |
|---|
| 581 | * |
|---|
| 582 | * Hydra_Software_Devel/2 2/1/06 10:19a gmullen |
|---|
| 583 | * PR18998: Fixed overflow issue in RAVE ITB/CDB, added support for PB |
|---|
| 584 | * channels. |
|---|
| 585 | * |
|---|
| 586 | * Hydra_Software_Devel/1 1/16/06 2:08p gmullen |
|---|
| 587 | * PR18998: Initial checkin for 7400 |
|---|
| 588 | * |
|---|
| 589 | * |
|---|
| 590 | ***************************************************************************/ |
|---|
| 591 | |
|---|
| 592 | /*= Module Overview ********************************************************* |
|---|
| 593 | |
|---|
| 594 | Overview |
|---|
| 595 | |
|---|
| 596 | ***************************************************************************/ |
|---|
| 597 | |
|---|
| 598 | #ifndef BXPT_H__ |
|---|
| 599 | #define BXPT_H__ |
|---|
| 600 | |
|---|
| 601 | #include "breg_mem.h" |
|---|
| 602 | #include "bint.h" |
|---|
| 603 | #include "bmem.h" |
|---|
| 604 | #include "bavc.h" |
|---|
| 605 | #include "bchp.h" |
|---|
| 606 | #include "berr_ids.h" |
|---|
| 607 | #include "bchp_xpt_full_pid_parser.h" |
|---|
| 608 | #include "bchp_xpt_fe.h" |
|---|
| 609 | |
|---|
| 610 | #ifdef __cplusplus |
|---|
| 611 | extern "C" { |
|---|
| 612 | #endif |
|---|
| 613 | |
|---|
| 614 | /*************************************************************************** |
|---|
| 615 | Summary: |
|---|
| 616 | Used to define the number of each type of resource that is supported. |
|---|
| 617 | ****************************************************************************/ |
|---|
| 618 | |
|---|
| 619 | /* These are supported by all the 40nm parts */ |
|---|
| 620 | #define BXPT_HAS_AVS 1 |
|---|
| 621 | #define BXPT_HAS_WAKEUP_PKT_SUPPORT 1 |
|---|
| 622 | #define BXPT_HAS_PIPELINE_ERROR_REPORTING 1 |
|---|
| 623 | #define BXPT_HAS_PACKETSUB_FORCED_INSERTION 1 |
|---|
| 624 | |
|---|
| 625 | /* Mostly chip-specific. */ |
|---|
| 626 | #if( BCHP_CHIP == 7425 ) |
|---|
| 627 | #define BXPT_HAS_TSMUX 1 |
|---|
| 628 | #define BXPT_HAS_DPCRS 1 |
|---|
| 629 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 630 | |
|---|
| 631 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 632 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 633 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 634 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 635 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 636 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 637 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 638 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 639 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 640 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 641 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 642 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 643 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 644 | #define BXPT_HAS_REMUX 1 |
|---|
| 645 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 646 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 647 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 648 | #define BXPT_HAS_RAVE 1 |
|---|
| 649 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 650 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 651 | |
|---|
| 652 | #define BXPT_HAS_MTSIF 1 |
|---|
| 653 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 654 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 655 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 12 ) |
|---|
| 656 | |
|---|
| 657 | /* These changes don't directly affect the API definition */ |
|---|
| 658 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 659 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 660 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 661 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 662 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 663 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 664 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 665 | |
|---|
| 666 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 667 | #ifdef BXPT_FILTER_32 |
|---|
| 668 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 669 | #else |
|---|
| 670 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 671 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 672 | |
|---|
| 673 | #if BCHP_VER >= BCHP_VER_B0 |
|---|
| 674 | #define BXPT_HAS_MPOD_RSBUF 1 |
|---|
| 675 | #define BXPT_NUM_INPUT_BANDS ( 11 ) |
|---|
| 676 | #define BXPT_NUM_PID_CHANNELS ( 512 ) |
|---|
| 677 | #define BXPT_NUM_PLAYBACKS ( 16 ) |
|---|
| 678 | #define BXPT_NUM_RAVE_CONTEXTS ( 48 ) |
|---|
| 679 | #define BXPT_NUM_SCD ( 64 ) |
|---|
| 680 | #define BXPT_NUM_TPIT_PIDS ( 32 ) |
|---|
| 681 | #define BXPT_NUM_TPIT ( 16 ) |
|---|
| 682 | #define BXPT_HAS_PB_PACKETSUB 1 |
|---|
| 683 | |
|---|
| 684 | #if BCHP_VER == BCHP_VER_B0 |
|---|
| 685 | #define BXPT_SW7425_1323_WORKAROUND 1 |
|---|
| 686 | #endif |
|---|
| 687 | #else |
|---|
| 688 | #define BXPT_NUM_INPUT_BANDS ( 10 ) |
|---|
| 689 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 690 | #define BXPT_NUM_PLAYBACKS ( 13 ) |
|---|
| 691 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 692 | #define BXPT_NUM_SCD ( 33 ) |
|---|
| 693 | #define BXPT_NUM_TPIT_PIDS ( 16 ) |
|---|
| 694 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 695 | #endif |
|---|
| 696 | |
|---|
| 697 | #define BXPT_NUM_PCRS ( 8 ) |
|---|
| 698 | |
|---|
| 699 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 700 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 701 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 702 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 703 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 704 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 705 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 706 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 707 | |
|---|
| 708 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 709 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 710 | |
|---|
| 711 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 712 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 713 | #define BXPT_NUM_STCS ( 8 ) |
|---|
| 714 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 715 | |
|---|
| 716 | /* Values are in Mbps */ |
|---|
| 717 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 718 | |
|---|
| 719 | #elif( BCHP_CHIP == 7422 ) |
|---|
| 720 | |
|---|
| 721 | #define BXPT_HAS_DPCRS 1 |
|---|
| 722 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 723 | |
|---|
| 724 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 725 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 726 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 727 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 728 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 729 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 730 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 731 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 732 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 733 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 734 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 735 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 736 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 737 | #define BXPT_HAS_REMUX 1 |
|---|
| 738 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 739 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 740 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 741 | #define BXPT_HAS_RAVE 1 |
|---|
| 742 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 743 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 744 | |
|---|
| 745 | /* These changes don't directly affect the API definition */ |
|---|
| 746 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 747 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 748 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 749 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 750 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 751 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 752 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 753 | |
|---|
| 754 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 755 | #ifdef BXPT_FILTER_32 |
|---|
| 756 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 757 | #else |
|---|
| 758 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 759 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 760 | |
|---|
| 761 | #define BXPT_HAS_MTSIF 1 |
|---|
| 762 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 763 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 764 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 12 ) |
|---|
| 765 | |
|---|
| 766 | #define BXPT_NUM_PCRS ( 8 ) |
|---|
| 767 | |
|---|
| 768 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 769 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 770 | #define BXPT_NUM_TPIT_PIDS ( 16 ) |
|---|
| 771 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 772 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 773 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 774 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 775 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 776 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 777 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 778 | #define BXPT_NUM_SCD ( 33 ) |
|---|
| 779 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 780 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 781 | |
|---|
| 782 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 783 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 784 | |
|---|
| 785 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 786 | #define BXPT_NUM_INPUT_BANDS ( 10 ) |
|---|
| 787 | #define BXPT_NUM_PLAYBACKS ( 13 ) |
|---|
| 788 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 789 | #define BXPT_NUM_STCS ( 4 ) |
|---|
| 790 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 791 | |
|---|
| 792 | /* Values are in Mbps */ |
|---|
| 793 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 794 | |
|---|
| 795 | #elif( BCHP_CHIP == 7435 ) |
|---|
| 796 | #define BXPT_HAS_TSMUX 1 |
|---|
| 797 | #define BXPT_HAS_DPCRS 1 |
|---|
| 798 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 799 | |
|---|
| 800 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 801 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 802 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 803 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 804 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 805 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 806 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 807 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 808 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 809 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 810 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 811 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 812 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 813 | #define BXPT_HAS_REMUX 1 |
|---|
| 814 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 815 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 816 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 817 | #define BXPT_HAS_RAVE 1 |
|---|
| 818 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 819 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 820 | #define BXPT_PCR_OFFSET_STC_SKIP 1 |
|---|
| 821 | |
|---|
| 822 | #define BXPT_HAS_MTSIF 1 |
|---|
| 823 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 824 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 825 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 12 ) |
|---|
| 826 | |
|---|
| 827 | /* These changes don't directly affect the API definition */ |
|---|
| 828 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 829 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 830 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 831 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 832 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 833 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 834 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 835 | |
|---|
| 836 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 837 | #ifdef BXPT_FILTER_32 |
|---|
| 838 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 839 | #else |
|---|
| 840 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 841 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 842 | |
|---|
| 843 | #define BXPT_HAS_MPOD_RSBUF 1 |
|---|
| 844 | #define BXPT_NUM_INPUT_BANDS ( 11 ) |
|---|
| 845 | #define BXPT_NUM_PID_CHANNELS ( 512 ) |
|---|
| 846 | #define BXPT_NUM_PLAYBACKS ( 22 ) |
|---|
| 847 | #define BXPT_NUM_RAVE_CONTEXTS ( 48 ) |
|---|
| 848 | #define BXPT_NUM_SCD ( 64 ) |
|---|
| 849 | #define BXPT_NUM_TPIT_PIDS ( 32 ) |
|---|
| 850 | #define BXPT_NUM_TPIT ( 16 ) |
|---|
| 851 | |
|---|
| 852 | #define BXPT_NUM_PCRS ( 10 ) |
|---|
| 853 | |
|---|
| 854 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 855 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 856 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 857 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 858 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 859 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 860 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 861 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 862 | |
|---|
| 863 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 864 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 865 | |
|---|
| 866 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 867 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 868 | #define BXPT_NUM_STCS ( 8 ) |
|---|
| 869 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 870 | |
|---|
| 871 | /* Values are in Mbps */ |
|---|
| 872 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 873 | |
|---|
| 874 | #elif (BCHP_CHIP == 7358) || (BCHP_CHIP == 7552) |
|---|
| 875 | |
|---|
| 876 | #define BXPT_HAS_DPCRS 1 |
|---|
| 877 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 878 | |
|---|
| 879 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 880 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 881 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 882 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 883 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 884 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 885 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 886 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 887 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 888 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 889 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 890 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 891 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 892 | #define BXPT_HAS_REMUX 1 |
|---|
| 893 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 894 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 895 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 896 | #define BXPT_HAS_RAVE 1 |
|---|
| 897 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 898 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 899 | |
|---|
| 900 | #if BCHP_CHIP == 7552 && BCHP_VER >= BCHP_VER_B0 |
|---|
| 901 | #define BXPT_NUM_INPUT_BANDS ( 10 ) |
|---|
| 902 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 903 | #define BXPT_HAS_MTSIF 1 |
|---|
| 904 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 905 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 906 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 10 ) |
|---|
| 907 | #else |
|---|
| 908 | #define BXPT_NUM_INPUT_BANDS ( 5 ) |
|---|
| 909 | #define BXPT_NUM_PID_PARSERS ( 10 ) |
|---|
| 910 | #endif |
|---|
| 911 | |
|---|
| 912 | /* These changes don't directly affect the API definition */ |
|---|
| 913 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 914 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 915 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 916 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 917 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 918 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 919 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 920 | |
|---|
| 921 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 922 | #ifdef BXPT_FILTER_32 |
|---|
| 923 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 924 | #else |
|---|
| 925 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 926 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 927 | |
|---|
| 928 | #define BXPT_NUM_PCRS ( 8 ) |
|---|
| 929 | |
|---|
| 930 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 931 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 932 | #define BXPT_NUM_TPIT_PIDS ( 16 ) |
|---|
| 933 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 934 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 935 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 936 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 937 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 938 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 939 | #define BXPT_NUM_SCD ( 33 ) |
|---|
| 940 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 941 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 942 | |
|---|
| 943 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 944 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 945 | |
|---|
| 946 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 947 | #define BXPT_NUM_PLAYBACKS ( 4 ) |
|---|
| 948 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 949 | #define BXPT_NUM_STCS ( 4 ) |
|---|
| 950 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 951 | |
|---|
| 952 | /* Values are in Mbps */ |
|---|
| 953 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 954 | |
|---|
| 955 | #elif (BCHP_CHIP == 7231) || (BCHP_CHIP == 7346) |
|---|
| 956 | |
|---|
| 957 | #define BXPT_HAS_DPCRS 1 |
|---|
| 958 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 959 | |
|---|
| 960 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 961 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 962 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 963 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 964 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 965 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 966 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 967 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 968 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 969 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 970 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 971 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 972 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 973 | #define BXPT_HAS_REMUX 1 |
|---|
| 974 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 975 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 976 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 977 | #define BXPT_HAS_RAVE 1 |
|---|
| 978 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 979 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 980 | |
|---|
| 981 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 982 | |
|---|
| 983 | /* These changes don't directly affect the API definition */ |
|---|
| 984 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 985 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 986 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 987 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 988 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 989 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 990 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 991 | |
|---|
| 992 | #if BCHP_CHIP == 7231 && BCHP_VER >= BCHP_VER_B0 |
|---|
| 993 | #define BXPT_HAS_TSMUX 1 |
|---|
| 994 | #define BXPT_NUM_INPUT_BANDS ( 11 ) |
|---|
| 995 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 996 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 16 ) |
|---|
| 997 | #define BXPT_HAS_MTSIF 1 |
|---|
| 998 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 999 | #define BXPT_NUM_STCS ( 8 ) |
|---|
| 1000 | #define BXPT_HAS_MPOD_RSBUF 1 |
|---|
| 1001 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 1002 | #define BXPT_NUM_PLAYBACKS ( 6 ) |
|---|
| 1003 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 1004 | #define BXPT_NUM_SCD ( 33 ) |
|---|
| 1005 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 1006 | #define BXPT_NUM_TPIT_PIDS ( 32 ) |
|---|
| 1007 | #define BXPT_NUM_PCRS ( 4 ) |
|---|
| 1008 | |
|---|
| 1009 | #if BCHP_VER == BCHP_VER_B0 |
|---|
| 1010 | #define BXPT_SW7425_1323_WORKAROUND 1 |
|---|
| 1011 | #endif |
|---|
| 1012 | #elif BCHP_CHIP == 7346 && BCHP_VER >= BCHP_VER_B0 |
|---|
| 1013 | #define BXPT_HAS_TSMUX 1 |
|---|
| 1014 | #define BXPT_NUM_INPUT_BANDS ( 11 ) |
|---|
| 1015 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 1016 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 12 ) |
|---|
| 1017 | #define BXPT_HAS_MTSIF 1 |
|---|
| 1018 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 1019 | #define BXPT_NUM_STCS ( 8 ) |
|---|
| 1020 | #define BXPT_HAS_MPOD_RSBUF 1 |
|---|
| 1021 | #define BXPT_NUM_PID_CHANNELS ( 512 ) |
|---|
| 1022 | #define BXPT_NUM_PLAYBACKS ( 16 ) |
|---|
| 1023 | #define BXPT_NUM_RAVE_CONTEXTS ( 48 ) |
|---|
| 1024 | #define BXPT_NUM_SCD ( 64 ) |
|---|
| 1025 | #define BXPT_NUM_TPIT ( 16 ) |
|---|
| 1026 | #define BXPT_NUM_TPIT_PIDS ( 32 ) |
|---|
| 1027 | #define BXPT_NUM_PCRS ( 8 ) |
|---|
| 1028 | |
|---|
| 1029 | #if BCHP_VER == BCHP_VER_B0 |
|---|
| 1030 | #define BXPT_SW7425_1323_WORKAROUND 1 |
|---|
| 1031 | #endif |
|---|
| 1032 | #else |
|---|
| 1033 | #define BXPT_NUM_INPUT_BANDS ( 8 ) |
|---|
| 1034 | #define BXPT_NUM_PID_PARSERS ( 10 ) |
|---|
| 1035 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 10 ) |
|---|
| 1036 | #define BXPT_NUM_STCS ( 4 ) |
|---|
| 1037 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 1038 | #define BXPT_NUM_PLAYBACKS ( 6 ) |
|---|
| 1039 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 1040 | #define BXPT_NUM_SCD ( 33 ) |
|---|
| 1041 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 1042 | #define BXPT_NUM_TPIT_PIDS ( 16 ) |
|---|
| 1043 | #define BXPT_NUM_PCRS ( 4 ) |
|---|
| 1044 | #endif |
|---|
| 1045 | |
|---|
| 1046 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 1047 | #ifdef BXPT_FILTER_32 |
|---|
| 1048 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 1049 | #else |
|---|
| 1050 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 1051 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 1052 | |
|---|
| 1053 | |
|---|
| 1054 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 1055 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 1056 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 1057 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 1058 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 1059 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 1060 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 1061 | |
|---|
| 1062 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 1063 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 1064 | |
|---|
| 1065 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 1066 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 1067 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 1068 | |
|---|
| 1069 | /* Values are in Mbps */ |
|---|
| 1070 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 1071 | |
|---|
| 1072 | #elif (BCHP_CHIP == 7344) |
|---|
| 1073 | |
|---|
| 1074 | #define BXPT_HAS_DPCRS 1 |
|---|
| 1075 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 1076 | |
|---|
| 1077 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 1078 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 1079 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 1080 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 1081 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 1082 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 1083 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 1084 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 1085 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 1086 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 1087 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 1088 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 1089 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 1090 | #define BXPT_HAS_REMUX 1 |
|---|
| 1091 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 1092 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 1093 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 1094 | #define BXPT_HAS_RAVE 1 |
|---|
| 1095 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 1096 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 1097 | |
|---|
| 1098 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 1099 | |
|---|
| 1100 | /* These changes don't directly affect the API definition */ |
|---|
| 1101 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 1102 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 1103 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 1104 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 1105 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 1106 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 1107 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 1108 | |
|---|
| 1109 | #if BCHP_VER >= BCHP_VER_B0 |
|---|
| 1110 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 1111 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 12 ) |
|---|
| 1112 | #define BXPT_HAS_MTSIF 1 |
|---|
| 1113 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 1114 | #else |
|---|
| 1115 | #define BXPT_NUM_PID_PARSERS ( 10 ) |
|---|
| 1116 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 10 ) |
|---|
| 1117 | #endif |
|---|
| 1118 | |
|---|
| 1119 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 1120 | #ifdef BXPT_FILTER_32 |
|---|
| 1121 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 1122 | #else |
|---|
| 1123 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 1124 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 1125 | |
|---|
| 1126 | #define BXPT_NUM_PCRS ( 4 ) |
|---|
| 1127 | |
|---|
| 1128 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 1129 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 1130 | #define BXPT_NUM_TPIT_PIDS ( 16 ) |
|---|
| 1131 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 1132 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 1133 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 1134 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 1135 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 1136 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 1137 | #define BXPT_NUM_SCD ( 33 ) |
|---|
| 1138 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 1139 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 1140 | |
|---|
| 1141 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 1142 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 1143 | |
|---|
| 1144 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 1145 | #define BXPT_NUM_INPUT_BANDS ( 5 ) |
|---|
| 1146 | #define BXPT_NUM_PLAYBACKS ( 4 ) |
|---|
| 1147 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 1148 | #define BXPT_NUM_STCS ( 4 ) |
|---|
| 1149 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 1150 | |
|---|
| 1151 | /* Values are in Mbps */ |
|---|
| 1152 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 1153 | |
|---|
| 1154 | #elif( BCHP_CHIP == 7640 ) |
|---|
| 1155 | |
|---|
| 1156 | #define BXPT_HAS_DPCRS 1 |
|---|
| 1157 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 1158 | |
|---|
| 1159 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 1160 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 1161 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 1162 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 1163 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 1164 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 1165 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 1166 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 1167 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 1168 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 1169 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 1170 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 1171 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 1172 | #define BXPT_HAS_REMUX 1 |
|---|
| 1173 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 1174 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 1175 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 1176 | #define BXPT_HAS_RAVE 1 |
|---|
| 1177 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 1178 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 1179 | |
|---|
| 1180 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 1181 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 10 ) |
|---|
| 1182 | |
|---|
| 1183 | /* These changes don't directly affect the API definition */ |
|---|
| 1184 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 1185 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 1186 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 1187 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 1188 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 1189 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 1190 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 1191 | |
|---|
| 1192 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 1193 | #ifdef BXPT_FILTER_32 |
|---|
| 1194 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 1195 | #else |
|---|
| 1196 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 1197 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 1198 | |
|---|
| 1199 | #define BXPT_NUM_PCRS ( 4 ) |
|---|
| 1200 | |
|---|
| 1201 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 1202 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 1203 | #define BXPT_NUM_TPIT_PIDS ( 16 ) |
|---|
| 1204 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 1205 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 1206 | #define BXPT_NUM_PID_PARSERS ( 10 ) |
|---|
| 1207 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 1208 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 1209 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 1210 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 1211 | #define BXPT_NUM_SCD ( 33 ) |
|---|
| 1212 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 1213 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 1214 | |
|---|
| 1215 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 1216 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 1217 | |
|---|
| 1218 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 1219 | #define BXPT_NUM_INPUT_BANDS ( 8 ) |
|---|
| 1220 | #define BXPT_NUM_PLAYBACKS ( 6 ) |
|---|
| 1221 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 1222 | #define BXPT_NUM_STCS ( 4 ) |
|---|
| 1223 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 1224 | |
|---|
| 1225 | /* Values are in Mbps */ |
|---|
| 1226 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 1227 | |
|---|
| 1228 | #elif (BCHP_CHIP == 7429) |
|---|
| 1229 | |
|---|
| 1230 | #define BXPT_HAS_DPCRS 1 |
|---|
| 1231 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 1232 | |
|---|
| 1233 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 1234 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 1235 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 1236 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 1237 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 1238 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 1239 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 1240 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 1241 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 1242 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 1243 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 1244 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 1245 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 1246 | #define BXPT_HAS_REMUX 1 |
|---|
| 1247 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 1248 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 1249 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 1250 | #define BXPT_HAS_RAVE 1 |
|---|
| 1251 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 1252 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 1253 | |
|---|
| 1254 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 1255 | |
|---|
| 1256 | /* These changes don't directly affect the API definition */ |
|---|
| 1257 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 1258 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 1259 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 1260 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 1261 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 1262 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 1263 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 1264 | |
|---|
| 1265 | #define BXPT_HAS_TSMUX 1 |
|---|
| 1266 | #define BXPT_NUM_INPUT_BANDS ( 11 ) |
|---|
| 1267 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 1268 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 16 ) |
|---|
| 1269 | #define BXPT_HAS_MTSIF 1 |
|---|
| 1270 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 1271 | #define BXPT_NUM_STCS ( 8 ) |
|---|
| 1272 | #define BXPT_HAS_MPOD_RSBUF 1 |
|---|
| 1273 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 1274 | #define BXPT_NUM_PLAYBACKS ( 6 ) |
|---|
| 1275 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 1276 | #define BXPT_NUM_SCD ( 48 ) |
|---|
| 1277 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 1278 | #define BXPT_NUM_TPIT_PIDS ( 32 ) |
|---|
| 1279 | |
|---|
| 1280 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 1281 | #ifdef BXPT_FILTER_32 |
|---|
| 1282 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 1283 | #else |
|---|
| 1284 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 1285 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 1286 | |
|---|
| 1287 | #define BXPT_NUM_PCRS ( 5 ) |
|---|
| 1288 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 1289 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 1290 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 1291 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 1292 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 1293 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 1294 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 1295 | |
|---|
| 1296 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 1297 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 1298 | |
|---|
| 1299 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 1300 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 1301 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 1302 | |
|---|
| 1303 | /* Values are in Mbps */ |
|---|
| 1304 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 1305 | |
|---|
| 1306 | #elif( BCHP_CHIP == 7360 ) |
|---|
| 1307 | |
|---|
| 1308 | #define BXPT_HAS_DPCRS 1 |
|---|
| 1309 | #define BXPT_HAS_RMX_NULL_THRESHOLD 1 |
|---|
| 1310 | |
|---|
| 1311 | #define BXPT_HAS_RAVE_SCRAMBLING_CONTROL 1 |
|---|
| 1312 | #define BXPT_HAS_PCR_PACING 1 |
|---|
| 1313 | #define BXPT_HAS_MESG_BUFFERS 1 |
|---|
| 1314 | #define BXPT_HAS_FIXED_RSBUF_CONFIG 1 |
|---|
| 1315 | #define BXPT_HAS_FIXED_XCBUF_CONFIG 1 |
|---|
| 1316 | #define BXPT_HAS_DIRECTV_SUPPORT 1 |
|---|
| 1317 | #define BXPT_HAS_PID_CHANNEL_PES_FILTERING 1 |
|---|
| 1318 | #define BXPT_HAS_FIXED_PSUB_DMA_PRIORITY 1 |
|---|
| 1319 | #define BXPT_HAS_REMUX_PCR_OFFSET 1 |
|---|
| 1320 | #define BXPT_HAS_MPOD_SCARD_SUPPORT 1 |
|---|
| 1321 | #define BXPT_HAS_MOSAIC_SUPPORT 1 |
|---|
| 1322 | #define BXPT_HAS_PID2BUF_MAPPING 1 |
|---|
| 1323 | #define BXPT_HAS_IB_PID_PARSERS 1 |
|---|
| 1324 | #define BXPT_HAS_REMUX 1 |
|---|
| 1325 | #define BXPT_HAS_PACKETSUB 1 |
|---|
| 1326 | #define BXPT_PLAYBACK_TS_ERROR_BOUNDS 1 |
|---|
| 1327 | #define BXPT_HAS_32BIT_PB_TIMESTAMPS 1 |
|---|
| 1328 | #define BXPT_HAS_RAVE 1 |
|---|
| 1329 | #define BXPT_HAS_PLAYBACK_PARSERS 1 |
|---|
| 1330 | #define BXPT_HAS_STARTCODE_BUFFER_WORKAROUND 1 |
|---|
| 1331 | |
|---|
| 1332 | #define BXPT_HAS_MTSIF 1 |
|---|
| 1333 | #define BXPT_NUM_MTSIF ( 2 ) |
|---|
| 1334 | #define BXPT_HAS_PARSER_REMAPPING 1 |
|---|
| 1335 | #define BXPT_NUM_REMAPPABLE_FE_PARSERS ( 12 ) |
|---|
| 1336 | |
|---|
| 1337 | /* These changes don't directly affect the API definition */ |
|---|
| 1338 | #define BXPT_DPCR_GLOBAL_PACKET_PROC_CTRL 1 |
|---|
| 1339 | #define BXPT_SEPARATE_REMUX_IO 1 |
|---|
| 1340 | #define BXPT_REC_SCD_MAPPING 1 |
|---|
| 1341 | #define BXPT_NEXT_GEN_COMPARATORS 1 |
|---|
| 1342 | #define BXPT_PER_CONTEXT_PIC_COUNTER 1 |
|---|
| 1343 | #define BXPT_HAS_RAVE_PES_EXTENSIONS 1 |
|---|
| 1344 | #define BXPT_PTS_CONTROL_IN_REC_REG 1 |
|---|
| 1345 | |
|---|
| 1346 | /* Number of filter banks, and the number of filters in each bank. */ |
|---|
| 1347 | #ifdef BXPT_FILTER_32 |
|---|
| 1348 | #define BXPT_NUM_FILTER_BANKS ( 2 ) |
|---|
| 1349 | #else |
|---|
| 1350 | #define BXPT_NUM_FILTER_BANKS ( 4 ) |
|---|
| 1351 | #endif /*BXPT_FILTER_32 **/ |
|---|
| 1352 | |
|---|
| 1353 | #define BXPT_NUM_INPUT_BANDS ( 10 ) |
|---|
| 1354 | #define BXPT_NUM_PID_CHANNELS ( 256 ) |
|---|
| 1355 | #define BXPT_NUM_PLAYBACKS ( 4 ) |
|---|
| 1356 | #define BXPT_NUM_RAVE_CONTEXTS ( 24 ) |
|---|
| 1357 | #define BXPT_NUM_SCD ( 33 ) |
|---|
| 1358 | #define BXPT_NUM_TPIT_PIDS ( 16 ) |
|---|
| 1359 | #define BXPT_NUM_TPIT ( 8 ) |
|---|
| 1360 | |
|---|
| 1361 | #define BXPT_NUM_PCRS ( 4 ) |
|---|
| 1362 | |
|---|
| 1363 | #define BXPT_NUM_FILTERS_PER_BANK ( 32 ) |
|---|
| 1364 | #define BXPT_P_FILTER_TABLE_SIZE BXPT_NUM_FILTERS_PER_BANK |
|---|
| 1365 | #define BXPT_NUM_REMULTIPLEXORS ( 2 ) |
|---|
| 1366 | #define BXPT_NUM_PID_PARSERS ( 16 ) |
|---|
| 1367 | #define BXPT_NUM_MESG_BUFFERS ( 128 ) |
|---|
| 1368 | #define BXPT_NUM_SAM_PID_CHANNEL BXPT_NUM_MESG_BUFFERS |
|---|
| 1369 | #define BXPT_NUM_RAVE_CHANNELS ( 1 ) |
|---|
| 1370 | #define BXPT_NUM_CAP_FILTERS ( 5 ) |
|---|
| 1371 | |
|---|
| 1372 | /* Number of splicing stacks. The stacks are shared between the AV and SCD contexts */ |
|---|
| 1373 | #define BXPT_P_NUM_SPLICING_QUEUES ( 3 ) |
|---|
| 1374 | |
|---|
| 1375 | #define BXPT_NUM_PACKETSUBS ( 8 ) |
|---|
| 1376 | #define BXPT_NUM_PCR_OFFSET_CHANNELS ( 16 ) |
|---|
| 1377 | #define BXPT_NUM_STCS ( 4 ) |
|---|
| 1378 | #define STC_FREE_RUNNING ( 8 ) |
|---|
| 1379 | |
|---|
| 1380 | /* Values are in Mbps */ |
|---|
| 1381 | #define BXPT_P_INITIAL_BUF_BITRATE (30000000) |
|---|
| 1382 | |
|---|
| 1383 | #else |
|---|
| 1384 | |
|---|
| 1385 | #error "UNSUPPORTED CHIP" |
|---|
| 1386 | |
|---|
| 1387 | #endif /* BCHP_CHIP == ??? */ |
|---|
| 1388 | |
|---|
| 1389 | /* SW7425-1384: The PID channels that playback uses for all-pass mode have changed. So has the |
|---|
| 1390 | playback's parser band number, as used in the PID table. */ |
|---|
| 1391 | #if BCHP_XPT_FE_PID_TABLE_i_PLAYBACK_BAND_PARSER_PID_CHANNEL_INPUT_SELECT_MASK == 0x003f0000 |
|---|
| 1392 | #define BXPT_PB_ALLPASS_PID_CHANNEL_START 64 |
|---|
| 1393 | #define BXPT_PB_PARSER_BAND_BASE 64 |
|---|
| 1394 | #elif BCHP_XPT_FE_PID_TABLE_i_PLAYBACK_BAND_PARSER_PID_CHANNEL_INPUT_SELECT_MASK == 0x000f0000 |
|---|
| 1395 | #define BXPT_PB_ALLPASS_PID_CHANNEL_START 16 |
|---|
| 1396 | #define BXPT_PB_PARSER_BAND_BASE 16 |
|---|
| 1397 | #else |
|---|
| 1398 | #error "INTERNAL ERROR" |
|---|
| 1399 | #endif |
|---|
| 1400 | |
|---|
| 1401 | /* Use a separate define, in case this defacto mapping is changed on a future chip. */ |
|---|
| 1402 | #ifdef BXPT_NUM_MESG_BUFFERS |
|---|
| 1403 | #define BXPT_NUM_MESSAGE_CAPABLE_PID_CHANNELS BXPT_NUM_MESG_BUFFERS |
|---|
| 1404 | #endif |
|---|
| 1405 | |
|---|
| 1406 | #define BXPT_GET_PLAYBACK_ALLPASS_CHNL( PbNum ) (PbNum + BXPT_PB_ALLPASS_PID_CHANNEL_START) |
|---|
| 1407 | #define BXPT_GET_IB_PARSER_ALLPASS_CHNL( ParserNum ) (ParserNum) |
|---|
| 1408 | |
|---|
| 1409 | /*************************************************************************** |
|---|
| 1410 | Summary: |
|---|
| 1411 | The handle for the transport module. Users should not directly access the |
|---|
| 1412 | contents. |
|---|
| 1413 | ****************************************************************************/ |
|---|
| 1414 | typedef struct BXPT_P_TransportData *BXPT_Handle; |
|---|
| 1415 | |
|---|
| 1416 | /*************************************************************************** |
|---|
| 1417 | Summary: |
|---|
| 1418 | Macros to generate BINT IDs for some of the errors reported by the parser |
|---|
| 1419 | bands. |
|---|
| 1420 | ****************************************************************************/ |
|---|
| 1421 | #define BXPT_INT_ID_PARSER_LENGTH_ERROR(X) BCHP_INT_ID_CREATE(BCHP_XPT_FE_INTR_STATUS0_REG, (X)) |
|---|
| 1422 | #define BXPT_INT_ID_PARSER_TRANSPORT_ERROR(X) BCHP_INT_ID_CREATE(BCHP_XPT_FE_INTR_STATUS0_REG, (X + 16)) |
|---|
| 1423 | #define BXPT_INT_ID_PARSER_CONTINUITY_ERROR(X) BCHP_INT_ID_CREATE(BCHP_XPT_FULL_PID_PARSER_IBP_PCC_INTR_STATUS_REG, (X)) |
|---|
| 1424 | |
|---|
| 1425 | /*************************************************************************** |
|---|
| 1426 | Summary: |
|---|
| 1427 | Transport specific error codes. |
|---|
| 1428 | ****************************************************************************/ |
|---|
| 1429 | #define BXPT_ERR_NO_AVAILABLE_RESOURCES BERR_MAKE_CODE(BERR_XPT_ID, 0) |
|---|
| 1430 | #define BXPT_ERR_CHANNEL_ALREADY_RUNNING BERR_MAKE_CODE(BERR_XPT_ID, 1) |
|---|
| 1431 | #define BXPT_ERR_CHANNEL_ALREADY_STOPPED BERR_MAKE_CODE(BERR_XPT_ID, 2) |
|---|
| 1432 | #define BXPT_ERR_DEVICE_BUSY BERR_MAKE_CODE(BERR_XPT_ID, 3) |
|---|
| 1433 | #define BXPT_ERR_MESG_BUFFER_NOT_CONFIGURED BERR_MAKE_CODE(BERR_XPT_ID, 4) |
|---|
| 1434 | #define BXPT_ERR_DUPLICATED_PID BERR_MAKE_CODE(BERR_XPT_ID, 5) |
|---|
| 1435 | #define BXPT_ERR_PID_ALREADY_ALLOCATED BERR_MAKE_CODE(BERR_XPT_ID, 6) |
|---|
| 1436 | #define BXPT_ERR_QUEUE_FULL BERR_MAKE_CODE(BERR_XPT_ID, 7) |
|---|
| 1437 | #define BXPT_ERR_RESOURCE_NOT_FOUND BERR_MAKE_CODE(BERR_XPT_ID, 8) |
|---|
| 1438 | #define BXPT_ERR_DATA_PIPELINE BERR_MAKE_CODE(BERR_XPT_ID, 9) |
|---|
| 1439 | |
|---|
| 1440 | /*************************************************************************** |
|---|
| 1441 | Summary: |
|---|
| 1442 | Number of bytes in the default PSI filter. |
|---|
| 1443 | ****************************************************************************/ |
|---|
| 1444 | #ifdef BXPT_FILTER_32 |
|---|
| 1445 | #define BXPT_FILTER_SIZE 32 |
|---|
| 1446 | #else |
|---|
| 1447 | #define BXPT_FILTER_SIZE 16 |
|---|
| 1448 | #endif |
|---|
| 1449 | |
|---|
| 1450 | /*************************************************************************** |
|---|
| 1451 | Summary: |
|---|
| 1452 | Macro to specify that a PID channel should get data from a Playback parser, |
|---|
| 1453 | rather than a Front End parser. For example, to select Playback parser 1 |
|---|
| 1454 | as the source of data, use BXPT_PB_PARSER( 1 ) as the Band argument to |
|---|
| 1455 | BXPT_ConfigurePidChannel(). |
|---|
| 1456 | ****************************************************************************/ |
|---|
| 1457 | #define BXPT_PB_PARSER( x ) ( ( x ) | 0x8000 ) |
|---|
| 1458 | |
|---|
| 1459 | /*************************************************************************** |
|---|
| 1460 | Summary: |
|---|
| 1461 | Enumeration of all the data sources. Some functions that use this enum may |
|---|
| 1462 | not support all members. |
|---|
| 1463 | ****************************************************************************/ |
|---|
| 1464 | typedef enum BXPT_DataSource |
|---|
| 1465 | { |
|---|
| 1466 | BXPT_DataSource_eInputBand, /* External input source. */ |
|---|
| 1467 | BXPT_DataSource_eRemuxFeedback, /* Feedback path from remux block. */ |
|---|
| 1468 | BXPT_DataSource_ePlayback /* Data from playback channels */ |
|---|
| 1469 | } |
|---|
| 1470 | BXPT_DataSource; |
|---|
| 1471 | |
|---|
| 1472 | |
|---|
| 1473 | /*************************************************************************** |
|---|
| 1474 | Summary: |
|---|
| 1475 | Enumeration of the types of PID parsers supported. Note that the types have |
|---|
| 1476 | different features and are not interchangable in some cases. |
|---|
| 1477 | ****************************************************************************/ |
|---|
| 1478 | typedef enum BXPT_ParserType |
|---|
| 1479 | { |
|---|
| 1480 | BXPT_ParserType_eIb, /* Parsers fed from input bands. */ |
|---|
| 1481 | BXPT_ParserType_ePb /* Parsers fed from playback channels. */ |
|---|
| 1482 | } |
|---|
| 1483 | BXPT_ParserType; |
|---|
| 1484 | |
|---|
| 1485 | /*************************************************************************** |
|---|
| 1486 | Summary: |
|---|
| 1487 | The PSI messages transfered into the DMA message buffers may be modified by |
|---|
| 1488 | the hardware to make further parsing by software easier. 3 modifications are |
|---|
| 1489 | supported. They are: |
|---|
| 1490 | |
|---|
| 1491 | Replace CRC bytes with a sentinel - The CRC bytes are overwritten with a |
|---|
| 1492 | fixed sentinel value of 0x98B93846. |
|---|
| 1493 | |
|---|
| 1494 | Replace CRC bytes with match vector - The CRC bytes are replaced with a 32-bit |
|---|
| 1495 | bitmap that indicates which filter(s) associated with the PID channel the |
|---|
| 1496 | message matched. For instance, if message matched filter 1 and 3, then bits |
|---|
| 1497 | 1 and 3 of the vector are set, and all others are 0. |
|---|
| 1498 | |
|---|
| 1499 | Append match vector to message - Append the filter match vector to the |
|---|
| 1500 | message, following the CRC bytes. The CRC isn't overwritten. This append is |
|---|
| 1501 | done before any word-align padding for that message |
|---|
| 1502 | |
|---|
| 1503 | These settings affect all PID channels associated with the given PID parser. |
|---|
| 1504 | ****************************************************************************/ |
|---|
| 1505 | typedef enum BXPT_PsiMesgModModes |
|---|
| 1506 | { |
|---|
| 1507 | BXPT_PsiMesgModModes_eNoMod = 0, /* Do not modify messages. */ |
|---|
| 1508 | BXPT_PsiMesgModModes_eReplaceWithSentinel = 1, /* Replace CRC bytes with Sentinel. */ |
|---|
| 1509 | BXPT_PsiMesgModModes_eReplaceWithMatchVector = 2, /* Replace CRC bytes with filter match vector */ |
|---|
| 1510 | BXPT_PsiMesgModModes_eAppendMatchVector = 3 /* Replace CRC bytes with filter match vector */ |
|---|
| 1511 | } |
|---|
| 1512 | BXPT_PsiMesgModModes; |
|---|
| 1513 | |
|---|
| 1514 | /*************************************************************************** |
|---|
| 1515 | Summary: |
|---|
| 1516 | Controls the type of timestamp generated as packets pass through this parser band. |
|---|
| 1517 | ****************************************************************************/ |
|---|
| 1518 | typedef enum BXPT_ParserTimestampMode |
|---|
| 1519 | { |
|---|
| 1520 | BXPT_ParserTimestampMode_eAutoSelect = 0, /* Use Mod-300 timestamp if the transport stream is MPEG; use binary timestamp otherwise. */ |
|---|
| 1521 | BXPT_ParserTimestampMode_eMod300 = 2, /* Use Mod-300 timestamp. */ |
|---|
| 1522 | BXPT_ParserTimestampMode_eBinary = 3 /* Use binary timestamp. */ |
|---|
| 1523 | } |
|---|
| 1524 | BXPT_ParserTimestampMode; |
|---|
| 1525 | |
|---|
| 1526 | /*************************************************************************** |
|---|
| 1527 | Summary: |
|---|
| 1528 | Defines the polarity values for input band related parameters. |
|---|
| 1529 | ****************************************************************************/ |
|---|
| 1530 | typedef enum BXPT_Polarity |
|---|
| 1531 | { |
|---|
| 1532 | BXPT_Polarity_eActiveHigh, |
|---|
| 1533 | BXPT_Polarity_eActiveLow |
|---|
| 1534 | } |
|---|
| 1535 | BXPT_Polarity; |
|---|
| 1536 | |
|---|
| 1537 | /*************************************************************************** |
|---|
| 1538 | Summary: |
|---|
| 1539 | Maximum bitrates for each input band parser and each playback parser. These are |
|---|
| 1540 | rates expected *after* PID parsing. Value is specified in Mbps. |
|---|
| 1541 | |
|---|
| 1542 | The valid range for PID parser data rates is from BXPT_MIN_PARSER_RATE up to |
|---|
| 1543 | BXPT_MAX_PARSER_RATE, inclusive. A value of 0 has special meaning: this indicates |
|---|
| 1544 | that the PID parser is not going to be used. |
|---|
| 1545 | ****************************************************************************/ |
|---|
| 1546 | |
|---|
| 1547 | /* In Mbps */ |
|---|
| 1548 | #define BXPT_MIN_PARSER_RATE (10000) |
|---|
| 1549 | #define BXPT_MAX_PARSER_RATE (108000000) |
|---|
| 1550 | |
|---|
| 1551 | typedef struct BXPT_P_ParserClients |
|---|
| 1552 | { |
|---|
| 1553 | /* If true, send this parser's data to ... */ |
|---|
| 1554 | bool ToRave; /* ... the RAVE */ |
|---|
| 1555 | bool ToMsg; /* ... the message filters */ |
|---|
| 1556 | |
|---|
| 1557 | #if BXPT_HAS_REMUX |
|---|
| 1558 | bool ToRmx[ BXPT_NUM_REMULTIPLEXORS ]; /* ... the remuxes. */ |
|---|
| 1559 | #endif |
|---|
| 1560 | |
|---|
| 1561 | bool ToMpodRs; /* ... the MPOD RS buffers, thence to the MPOD */ |
|---|
| 1562 | } |
|---|
| 1563 | BXPT_P_ParserClients; |
|---|
| 1564 | |
|---|
| 1565 | typedef struct BXPT_BandWidthConfig |
|---|
| 1566 | { |
|---|
| 1567 | #if BXPT_HAS_IB_PID_PARSERS |
|---|
| 1568 | unsigned MaxInputRate[ BXPT_NUM_PID_PARSERS ]; |
|---|
| 1569 | BXPT_P_ParserClients IbParserClients[ BXPT_NUM_PID_PARSERS ]; |
|---|
| 1570 | #endif |
|---|
| 1571 | |
|---|
| 1572 | #if BXPT_HAS_PLAYBACK_PARSERS |
|---|
| 1573 | unsigned MaxPlaybackRate[ BXPT_NUM_PLAYBACKS ]; |
|---|
| 1574 | BXPT_P_ParserClients PlaybackParserClients[ BXPT_NUM_PLAYBACKS ]; |
|---|
| 1575 | #endif |
|---|
| 1576 | |
|---|
| 1577 | #if BXPT_HAS_REMUX |
|---|
| 1578 | /* Set to 'false' if the app does not expect to use the remux blocks. Default setting is 'true' */ |
|---|
| 1579 | bool RemuxUsed[ BXPT_NUM_REMULTIPLEXORS ]; |
|---|
| 1580 | #endif |
|---|
| 1581 | } |
|---|
| 1582 | BXPT_BandWidthConfig; |
|---|
| 1583 | |
|---|
| 1584 | /*************************************************************************** |
|---|
| 1585 | Summary: |
|---|
| 1586 | Config for the MTSIF interface. |
|---|
| 1587 | ****************************************************************************/ |
|---|
| 1588 | typedef struct BXPT_MtsifConfig |
|---|
| 1589 | { |
|---|
| 1590 | /* Width of the MTSIF bus. Allowable values are 1, 2, 4, and 8 bits */ |
|---|
| 1591 | unsigned RxInterfaceWidth; |
|---|
| 1592 | |
|---|
| 1593 | /* 1 = rising edge, 0 = falling edge. NOTE: On some parts, due to a |
|---|
| 1594 | hardware bug, these values might not match those given in the register |
|---|
| 1595 | docs. The portinginterface will handle that. */ |
|---|
| 1596 | unsigned RxClockPolarity; |
|---|
| 1597 | |
|---|
| 1598 | bool Enable; /* Interface enabled or not. */ |
|---|
| 1599 | } |
|---|
| 1600 | BXPT_MtsifConfig; |
|---|
| 1601 | |
|---|
| 1602 | /*************************************************************************** |
|---|
| 1603 | Summary: |
|---|
| 1604 | Default settings and/or actions to used during BXPT_Open(). |
|---|
| 1605 | ****************************************************************************/ |
|---|
| 1606 | typedef struct BXPT_DefaultSettings |
|---|
| 1607 | { |
|---|
| 1608 | #if BXPT_HAS_FIXED_RSBUF_CONFIG || BXPT_HAS_FIXED_XCBUF_CONFIG |
|---|
| 1609 | BXPT_BandWidthConfig BandwidthConfig; |
|---|
| 1610 | #endif |
|---|
| 1611 | |
|---|
| 1612 | /* Handle for secure memory allocations. This is initialized to NULL */ |
|---|
| 1613 | BMEM_Handle hRHeap; |
|---|
| 1614 | |
|---|
| 1615 | /* |
|---|
| 1616 | ** Handle for playback memory mapping. In some cases, the playback |
|---|
| 1617 | ** descriptors/buffers are taken from a heap other than the system |
|---|
| 1618 | ** heap that XPT was opened with. In that case, the handle for that |
|---|
| 1619 | ** heap should be set here. This is initialized to NULL. If it is not |
|---|
| 1620 | ** overridden, the heap used at BXPT_Open will be used. |
|---|
| 1621 | */ |
|---|
| 1622 | BMEM_Handle hPbHeap; |
|---|
| 1623 | |
|---|
| 1624 | /* |
|---|
| 1625 | ** When true, data sent to the mesg filters will go via the R-pipe. When |
|---|
| 1626 | ** false, data is sent on the G-pipe. Default is the G-pipe. |
|---|
| 1627 | */ |
|---|
| 1628 | bool MesgDataOnRPipe; |
|---|
| 1629 | |
|---|
| 1630 | #if BXPT_HAS_MTSIF |
|---|
| 1631 | /* Settings for the MTSIF RX block(s). The receivers default to disabled. */ |
|---|
| 1632 | BXPT_MtsifConfig MtsifConfig[ BXPT_NUM_MTSIF ]; |
|---|
| 1633 | #endif |
|---|
| 1634 | } |
|---|
| 1635 | BXPT_DefaultSettings; |
|---|
| 1636 | |
|---|
| 1637 | /*************************************************************************** |
|---|
| 1638 | Summary: |
|---|
| 1639 | The Capability structure contains handy stuff describing what is supported |
|---|
| 1640 | by this core. |
|---|
| 1641 | ****************************************************************************/ |
|---|
| 1642 | typedef struct BXPT_Capability |
|---|
| 1643 | { |
|---|
| 1644 | unsigned int MaxPlaybacks; /* Number of playback blocks we support. */ |
|---|
| 1645 | unsigned int MaxPidChannels; /* Number of PID channels we support. */ |
|---|
| 1646 | unsigned int MaxPidParsers; /* Number of PID parsers we support. */ |
|---|
| 1647 | unsigned int MaxInputBands; /* Max number of input bands we support. */ |
|---|
| 1648 | unsigned int MaxTpitPids; /* Max number of TPIT PIDs each record can support. */ |
|---|
| 1649 | unsigned int MaxFilterBanks; /* Max number of filter banks */ |
|---|
| 1650 | unsigned int MaxFiltersPerBank; /* Number of filters in each bank. */ |
|---|
| 1651 | unsigned int MaxPcrs; /* Max number of Pcr blocks */ |
|---|
| 1652 | unsigned int MaxPacketSubs; /* Max number of packet subsitution channels. */ |
|---|
| 1653 | |
|---|
| 1654 | unsigned int MaxRaveContexts; /* Max number of RAVE contexts (AV plus record). */ |
|---|
| 1655 | } |
|---|
| 1656 | BXPT_Capability; |
|---|
| 1657 | |
|---|
| 1658 | #if BXPT_HAS_IB_PID_PARSERS |
|---|
| 1659 | |
|---|
| 1660 | /*************************************************************************** |
|---|
| 1661 | Summary: |
|---|
| 1662 | Settings for a parser band. |
|---|
| 1663 | ****************************************************************************/ |
|---|
| 1664 | typedef struct BXPT_ParserConfig |
|---|
| 1665 | { |
|---|
| 1666 | bool ErrorInputIgnore; /* PID parser ignores the error input signal and TEI bit */ |
|---|
| 1667 | BXPT_ParserTimestampMode TsMode; /* Controls the type of timestamp generated as packets pass through the parser band. */ |
|---|
| 1668 | bool AcceptNulls; /* NULL packets are not discarded if true */ |
|---|
| 1669 | bool AcceptAdapt00; /* Packets with an Adaptation Field of 00b will not be dropped. */ |
|---|
| 1670 | } |
|---|
| 1671 | BXPT_ParserConfig; |
|---|
| 1672 | |
|---|
| 1673 | /*************************************************************************** |
|---|
| 1674 | Summary: |
|---|
| 1675 | Parser Settings for a per pid channel. New chip architecture supports these |
|---|
| 1676 | setting for each pid channnel. This structure is to be used with the new |
|---|
| 1677 | archicture to configure the pasrer settings for each pid channel. |
|---|
| 1678 | ****************************************************************************/ |
|---|
| 1679 | typedef struct BXPT_PidPsiConfig |
|---|
| 1680 | { |
|---|
| 1681 | bool SaveShortPsiMsg; |
|---|
| 1682 | bool SaveLongPsiMsg; |
|---|
| 1683 | bool PsfCrcDis; |
|---|
| 1684 | BXPT_PsiMesgModModes PsiMsgMod; |
|---|
| 1685 | bool ContCountIgnore; |
|---|
| 1686 | bool AcceptAdapt00; /* Packets with an adaptation field of 00 are accepted if true */ |
|---|
| 1687 | } |
|---|
| 1688 | BXPT_PidPsiConfig; |
|---|
| 1689 | |
|---|
| 1690 | /*************************************************************************** |
|---|
| 1691 | Summary: |
|---|
| 1692 | Settings for a input band. |
|---|
| 1693 | ****************************************************************************/ |
|---|
| 1694 | typedef struct BXPT_InputBandConfig |
|---|
| 1695 | { |
|---|
| 1696 | BXPT_Polarity ClockPolSel; /* Defines which edge of the input band clock is used */ |
|---|
| 1697 | BXPT_Polarity SyncPolSel; /* Input band sync signal active high/low select */ |
|---|
| 1698 | BXPT_Polarity DataPolSel; /* Input band data signal active high/low select */ |
|---|
| 1699 | BXPT_Polarity ValidPolSel; /* Input band valid signal active high/low select */ |
|---|
| 1700 | BXPT_Polarity ErrorPolSel; /* Input band error signal active high/low select */ |
|---|
| 1701 | bool EnableErrorInput; /* Use the error input signal */ |
|---|
| 1702 | bool SyncDetectEn; /* Selects whether the circuit performs local sync detection */ |
|---|
| 1703 | bool UseSyncAsValid; /* Sync input is used as valid; internal sync detection must be enabled by the user */ |
|---|
| 1704 | bool ForceValid; /* Use input valid signal or ignore it. */ |
|---|
| 1705 | bool LsbFirst; /* Controls whether each byte is received MSB or LSB first */ |
|---|
| 1706 | bool ParallelInputSel; /* Select parallel data input for this port instead of serial. Not available on all input bands. */ |
|---|
| 1707 | unsigned int IbPktLength; /* Transport packet length value used for this input band. */ |
|---|
| 1708 | } |
|---|
| 1709 | BXPT_InputBandConfig; |
|---|
| 1710 | |
|---|
| 1711 | #endif |
|---|
| 1712 | |
|---|
| 1713 | /*************************************************************************** |
|---|
| 1714 | Summary: |
|---|
| 1715 | Defines the message buffer sizes that are supported. |
|---|
| 1716 | ****************************************************************************/ |
|---|
| 1717 | typedef enum BXPT_MessageBufferSize |
|---|
| 1718 | { |
|---|
| 1719 | BXPT_MessageBufferSize_e1kB, |
|---|
| 1720 | BXPT_MessageBufferSize_e2kB, |
|---|
| 1721 | BXPT_MessageBufferSize_e4kB, |
|---|
| 1722 | BXPT_MessageBufferSize_e8kB, |
|---|
| 1723 | BXPT_MessageBufferSize_e16kB, |
|---|
| 1724 | BXPT_MessageBufferSize_e32kB, |
|---|
| 1725 | BXPT_MessageBufferSize_e64kB, |
|---|
| 1726 | BXPT_MessageBufferSize_e128kB, |
|---|
| 1727 | BXPT_MessageBufferSize_e256kB, |
|---|
| 1728 | BXPT_MessageBufferSize_e512kB |
|---|
| 1729 | } |
|---|
| 1730 | BXPT_MessageBufferSize; |
|---|
| 1731 | |
|---|
| 1732 | /*************************************************************************** |
|---|
| 1733 | Summary: |
|---|
| 1734 | A PSI/SI message filter. The fields of the structure are written to or read |
|---|
| 1735 | from the hardware filters by the BXPT_GetFilter() and BXPT_SetFilter() |
|---|
| 1736 | calls. |
|---|
| 1737 | |
|---|
| 1738 | The arrays are read or written using contents of the first byte as the most |
|---|
| 1739 | significant bits of the filter, and subsequent bytes containing subsequen |
|---|
| 1740 | bits. I.e. Mask[0] contains mask bits 96 through 103, mask[1] contains bits |
|---|
| 1741 | 64 through 95, etc. |
|---|
| 1742 | ****************************************************************************/ |
|---|
| 1743 | typedef struct BXPT_Filter |
|---|
| 1744 | { |
|---|
| 1745 | uint8_t Mask[ BXPT_FILTER_SIZE ]; |
|---|
| 1746 | uint8_t Coeficient[ BXPT_FILTER_SIZE ]; |
|---|
| 1747 | uint8_t Exclusion[ BXPT_FILTER_SIZE ]; |
|---|
| 1748 | } |
|---|
| 1749 | BXPT_Filter; |
|---|
| 1750 | |
|---|
| 1751 | /*************************************************************************** |
|---|
| 1752 | Summary: |
|---|
| 1753 | Data needed to configure a channel for PSI message filtering. Caller |
|---|
| 1754 | supplies the PID and band that carry the packets to be filtered. The filter |
|---|
| 1755 | enable masks are a bit map, with 1 bit for each filter in the transport |
|---|
| 1756 | core. To enable filtering by filter 2, set bit 2 in the appropriate mask |
|---|
| 1757 | member ( this is done automatically by BXPT_AddFilterToGroup() ). |
|---|
| 1758 | ****************************************************************************/ |
|---|
| 1759 | typedef struct BXPT_PsiMessageSettings |
|---|
| 1760 | { |
|---|
| 1761 | unsigned int Pid; /* Which PID carries the PSI messages. */ |
|---|
| 1762 | unsigned int Band; /* The band that carries the PID. */ |
|---|
| 1763 | bool CrcDisable; /* Disable CRC checks for this PID channel. */ |
|---|
| 1764 | |
|---|
| 1765 | unsigned int Bank; /* Which filter bank has the filters */ |
|---|
| 1766 | uint32_t FilterEnableMask; /* Enable bits for filters 0 through 31 */ |
|---|
| 1767 | |
|---|
| 1768 | /* |
|---|
| 1769 | ** Set to true to have data byte-aligned in the message buffer. If false, |
|---|
| 1770 | ** the data is word aligned, with bytes of value 0x55 inserted as padding. |
|---|
| 1771 | ** This is done for software compatability with older chips that didn't |
|---|
| 1772 | ** support byte-alignment. |
|---|
| 1773 | */ |
|---|
| 1774 | bool ByteAlign; |
|---|
| 1775 | |
|---|
| 1776 | /* |
|---|
| 1777 | ** Use R-pipe data. This will affect ALL message buffers being fed by |
|---|
| 1778 | ** the PID channel is buffer is using. Hardware forces that condition. |
|---|
| 1779 | ** |
|---|
| 1780 | ** In summary, R pipe data will be used if either UseRPipe is true or |
|---|
| 1781 | ** if MesgDataOnRPipe was true when BXPT_Open() was called. |
|---|
| 1782 | */ |
|---|
| 1783 | bool UseRPipe; |
|---|
| 1784 | |
|---|
| 1785 | unsigned StartingOffset; /* Offset into the message section where the filter comparison will start. |
|---|
| 1786 | Default is 0, max is 255. */ |
|---|
| 1787 | bool SkipByte2; /* Skip the 3rd byte (offset 2) when doing the filter comparison. Default is false. */ |
|---|
| 1788 | } |
|---|
| 1789 | BXPT_PsiMessageSettings; |
|---|
| 1790 | |
|---|
| 1791 | /*************************************************************************** |
|---|
| 1792 | Summary: |
|---|
| 1793 | Defines the types of single PID channel recoding this transport supports. |
|---|
| 1794 | ****************************************************************************/ |
|---|
| 1795 | typedef enum BXPT_SingleChannelRecordType |
|---|
| 1796 | { |
|---|
| 1797 | BXPT_SingleChannelRecordType_ePes, /* Recording PES level data. */ |
|---|
| 1798 | BXPT_SingleChannelRecordType_ePacketSaveAll, /* Recoding entire transport packets. */ |
|---|
| 1799 | BXPT_SingleChannelRecordType_ePesSaveAll |
|---|
| 1800 | } |
|---|
| 1801 | BXPT_SingleChannelRecordType; |
|---|
| 1802 | |
|---|
| 1803 | /*************************************************************************** |
|---|
| 1804 | Summary: |
|---|
| 1805 | Data needed to configure a single PID channel recording. |
|---|
| 1806 | ****************************************************************************/ |
|---|
| 1807 | typedef struct BXPT_PidChannelRecordSettings |
|---|
| 1808 | { |
|---|
| 1809 | unsigned int Pid; /* Which PID to record. */ |
|---|
| 1810 | unsigned int Band; /* The band the PID is on. */ |
|---|
| 1811 | BXPT_SingleChannelRecordType RecordType; /* Type of recording to do. */ |
|---|
| 1812 | |
|---|
| 1813 | /* |
|---|
| 1814 | ** Set to true to have data byte-aligned in the message buffer. If false, |
|---|
| 1815 | ** the data is word aligned, with bytes of value 0x55 inserted as padding. |
|---|
| 1816 | ** This is done for software compatability with older chips that didn't |
|---|
| 1817 | ** support byte-alignment. |
|---|
| 1818 | */ |
|---|
| 1819 | bool ByteAlign; |
|---|
| 1820 | |
|---|
| 1821 | /* |
|---|
| 1822 | ** Use R-pipe data. This will affect ALL message buffers being fed by |
|---|
| 1823 | ** the PID channel is buffer is using. Hardware forces that condition. |
|---|
| 1824 | ** |
|---|
| 1825 | ** In summary, R pipe data will be used if either UseRPipe is true or |
|---|
| 1826 | ** if MesgDataOnRPipe was true when BXPT_Open() was called. |
|---|
| 1827 | */ |
|---|
| 1828 | bool UseRPipe; |
|---|
| 1829 | } |
|---|
| 1830 | BXPT_PidChannelRecordSettings; |
|---|
| 1831 | |
|---|
| 1832 | /*************************************************************************** |
|---|
| 1833 | Summary: |
|---|
| 1834 | Control the Continuity Count checking, configurable on a per-PID channel basis. |
|---|
| 1835 | ****************************************************************************/ |
|---|
| 1836 | typedef struct BXPT_PidChannel_CC_Config |
|---|
| 1837 | { |
|---|
| 1838 | bool Primary_CC_CheckEnable; /* CC handling for the Primary PID (PID Table). */ |
|---|
| 1839 | bool Secondary_CC_CheckEnable; /* CC handling for the Secondary PID (SPID Table). */ |
|---|
| 1840 | bool Generate_CC_Enable; /* Generate and insert CC values for TS streams generated by the playback packetizer */ |
|---|
| 1841 | unsigned Initial_CC_Value; /* Starting value for inserted continuity counts. Used when Generate_CC_Enable == true. */ |
|---|
| 1842 | } |
|---|
| 1843 | BXPT_PidChannel_CC_Config; |
|---|
| 1844 | |
|---|
| 1845 | #if BXPT_HAS_PARSER_REMAPPING |
|---|
| 1846 | /*************************************************************************** |
|---|
| 1847 | Summary: |
|---|
| 1848 | In XPT cores that support this feature, a physical input band parser or |
|---|
| 1849 | playback parser may be "remapped" to another "virtual" input band or |
|---|
| 1850 | playback parser. Packets seen by a phyiscal parser are presented to the rest |
|---|
| 1851 | of XPT as if they came from the virtual parser. |
|---|
| 1852 | |
|---|
| 1853 | For example, if front-end parser 2 is remapped to playback parser 4, then |
|---|
| 1854 | all packets seen by front-end parser 2 will be treated by the rest of XPT |
|---|
| 1855 | as if they came from playback parser 4. This affects how blocks like the |
|---|
| 1856 | PID table are configured. |
|---|
| 1857 | |
|---|
| 1858 | At BXPT_Open(), all parser mappings default to themselves. I.e, front-end |
|---|
| 1859 | parser 0 is mapped to front-end parser 0, and so forth. |
|---|
| 1860 | |
|---|
| 1861 | All API calls that take a parser band number as an input would use the |
|---|
| 1862 | virtual band number, with two exceptions: the indexes into the FrontEnd |
|---|
| 1863 | and Playback arrays used by BXPT_GetParserMapping() and |
|---|
| 1864 | BXPT_SetParserMapping() will always refer to physical parsers. |
|---|
| 1865 | ****************************************************************************/ |
|---|
| 1866 | typedef struct BXPT_BandMap |
|---|
| 1867 | { |
|---|
| 1868 | unsigned VirtualParserBandNum; |
|---|
| 1869 | bool VirtualParserIsPlayback; |
|---|
| 1870 | } |
|---|
| 1871 | BXPT_BandMap; |
|---|
| 1872 | |
|---|
| 1873 | /* Physical to virtual parser band mapping. */ |
|---|
| 1874 | typedef struct BXPT_ParserBandMapping |
|---|
| 1875 | { |
|---|
| 1876 | /* The indexes into these arrays represent physical parser bands. */ |
|---|
| 1877 | BXPT_BandMap FrontEnd[ BXPT_NUM_PID_PARSERS ]; |
|---|
| 1878 | BXPT_BandMap Playback[ BXPT_NUM_PLAYBACKS ]; |
|---|
| 1879 | } |
|---|
| 1880 | BXPT_ParserBandMapping; |
|---|
| 1881 | |
|---|
| 1882 | /*************************************************************************** |
|---|
| 1883 | Summary: |
|---|
| 1884 | Get the current parser band mapping. |
|---|
| 1885 | |
|---|
| 1886 | Description: |
|---|
| 1887 | Retrieve the current physical to virtual parser band mapping. See the comments |
|---|
| 1888 | for the BXPT_ParserBandMapping structure for more information. |
|---|
| 1889 | |
|---|
| 1890 | Returns: |
|---|
| 1891 | void |
|---|
| 1892 | ****************************************************************************/ |
|---|
| 1893 | void BXPT_GetParserMapping( |
|---|
| 1894 | BXPT_Handle hXpt, /* [in] Handle for the Transport. */ |
|---|
| 1895 | BXPT_ParserBandMapping *ParserMap |
|---|
| 1896 | ); |
|---|
| 1897 | |
|---|
| 1898 | /*************************************************************************** |
|---|
| 1899 | Summary: |
|---|
| 1900 | Set the current parser band mapping. |
|---|
| 1901 | |
|---|
| 1902 | Description: |
|---|
| 1903 | Set the current physical to virtual parser band mapping. See the comments |
|---|
| 1904 | for the BXPT_ParserBandMapping structure for more information. |
|---|
| 1905 | |
|---|
| 1906 | Returns: |
|---|
| 1907 | void |
|---|
| 1908 | ****************************************************************************/ |
|---|
| 1909 | BERR_Code BXPT_SetParserMapping( |
|---|
| 1910 | BXPT_Handle hXpt, /* [in] Handle for the Transport. */ |
|---|
| 1911 | const BXPT_ParserBandMapping *ParserMap |
|---|
| 1912 | ); |
|---|
| 1913 | #endif |
|---|
| 1914 | |
|---|
| 1915 | /*************************************************************************** |
|---|
| 1916 | Summary: |
|---|
| 1917 | Return the default settings for the transport core. |
|---|
| 1918 | |
|---|
| 1919 | Description: |
|---|
| 1920 | The transport core has certain default settings which the user can override |
|---|
| 1921 | when the device is opened. This function returns those defaults in a structure |
|---|
| 1922 | that can be changed, and then passed to BXPT_Open(). |
|---|
| 1923 | |
|---|
| 1924 | Returns: |
|---|
| 1925 | BERR_SUCCESS - Device opened. |
|---|
| 1926 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 1927 | |
|---|
| 1928 | See Also: |
|---|
| 1929 | BXPT_Open |
|---|
| 1930 | ****************************************************************************/ |
|---|
| 1931 | BERR_Code BXPT_GetDefaultSettings( |
|---|
| 1932 | BXPT_DefaultSettings *Defaults, /* [out] Defaults to use during init.*/ |
|---|
| 1933 | BCHP_Handle hChip /* [in] Handle to used chip. */ |
|---|
| 1934 | ); |
|---|
| 1935 | |
|---|
| 1936 | /*************************************************************************** |
|---|
| 1937 | Summary: |
|---|
| 1938 | Opens the transport module. |
|---|
| 1939 | |
|---|
| 1940 | Description: |
|---|
| 1941 | The transport core is reset and initialized. Dynamic resources needed by the |
|---|
| 1942 | transport module are allocated. A handle to use when configuring the core is |
|---|
| 1943 | created and returned. The caller may specify certain default and/or |
|---|
| 1944 | initialization actions by setting the appropriate members of the default |
|---|
| 1945 | settings parameter. |
|---|
| 1946 | |
|---|
| 1947 | Returns: |
|---|
| 1948 | BERR_SUCCESS - Device opened. |
|---|
| 1949 | BERR_OUT_OF_DEVICE_MEMORY - Memory failure (should not happen) |
|---|
| 1950 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 1951 | |
|---|
| 1952 | See Also: |
|---|
| 1953 | BXPT_GetDefaultSettings, BXPT_Close |
|---|
| 1954 | ****************************************************************************/ |
|---|
| 1955 | BERR_Code BXPT_Open( |
|---|
| 1956 | BXPT_Handle *hXpt, /* [out] Transport handle. */ |
|---|
| 1957 | BCHP_Handle hChip, /* [in] Handle to used chip. */ |
|---|
| 1958 | BREG_Handle hRegister, /* [in] Handle to access regiters. */ |
|---|
| 1959 | BMEM_Handle hMemory, /* [in] Handle to memory heap to use. */ |
|---|
| 1960 | BINT_Handle hInt, /* [in] Handle to interrupt interface to use. */ |
|---|
| 1961 | const BXPT_DefaultSettings *Defaults /* [in] Defaults to use during init.*/ |
|---|
| 1962 | ); |
|---|
| 1963 | |
|---|
| 1964 | /*************************************************************************** |
|---|
| 1965 | Summary: |
|---|
| 1966 | Close the transport module. |
|---|
| 1967 | |
|---|
| 1968 | Description: |
|---|
| 1969 | Release any memory and other system resources allocated by the data transport |
|---|
| 1970 | core. Reset the transport core to insure that all interrupt sources are |
|---|
| 1971 | disabled. |
|---|
| 1972 | |
|---|
| 1973 | Returns: |
|---|
| 1974 | void |
|---|
| 1975 | |
|---|
| 1976 | See Also: |
|---|
| 1977 | BXPT_Open |
|---|
| 1978 | ****************************************************************************/ |
|---|
| 1979 | void BXPT_Close( |
|---|
| 1980 | BXPT_Handle hXpt /* [in] Handle for the Transport to be closed. */ |
|---|
| 1981 | ); |
|---|
| 1982 | |
|---|
| 1983 | /*************************************************************************** |
|---|
| 1984 | Summary: |
|---|
| 1985 | Standby settings for XPT |
|---|
| 1986 | ****************************************************************************/ |
|---|
| 1987 | typedef struct BXPT_StandbySettings |
|---|
| 1988 | { |
|---|
| 1989 | /* |
|---|
| 1990 | ** Enable handling of "wakeup" packets from the demod. See bxpt_wakeup.h |
|---|
| 1991 | ** for a full description and example code. Enabling this feature will |
|---|
| 1992 | ** keep the CLK216 to XPT running during standby mode. |
|---|
| 1993 | */ |
|---|
| 1994 | bool UseWakeupPacket; /* Defaults to false. */ |
|---|
| 1995 | |
|---|
| 1996 | /* XPT can enter standby in S3 or S2 mode. |
|---|
| 1997 | in S2 standby, only SRAM-based registers are saved/restored. |
|---|
| 1998 | in S3 standby, all registers are saved/restored. */ |
|---|
| 1999 | bool S3Standby; /* Defaults to false */ |
|---|
| 2000 | } |
|---|
| 2001 | BXPT_StandbySettings; |
|---|
| 2002 | |
|---|
| 2003 | /*************************************************************************** |
|---|
| 2004 | Summary: |
|---|
| 2005 | Get default standby settings |
|---|
| 2006 | |
|---|
| 2007 | Description: |
|---|
| 2008 | Return default standby settings for BXPT_Standby |
|---|
| 2009 | |
|---|
| 2010 | Returns: |
|---|
| 2011 | void |
|---|
| 2012 | |
|---|
| 2013 | See Also: |
|---|
| 2014 | BXPT_Standby |
|---|
| 2015 | ****************************************************************************/ |
|---|
| 2016 | void BXPT_GetDefaultStandbySettings( |
|---|
| 2017 | BXPT_StandbySettings *pSettings |
|---|
| 2018 | ); |
|---|
| 2019 | |
|---|
| 2020 | /*************************************************************************** |
|---|
| 2021 | Summary: |
|---|
| 2022 | Enter standby mode |
|---|
| 2023 | |
|---|
| 2024 | Description: |
|---|
| 2025 | Enter standby with XPT. This allows you to enter a minimal power state without |
|---|
| 2026 | calling BXPT_Close. Standby is not possible if XPT is currently in use. |
|---|
| 2027 | This means that upper-level SW must disable parsers and close all playback, |
|---|
| 2028 | packetsub and remux channels. |
|---|
| 2029 | |
|---|
| 2030 | If standby is not supported on this platform, calling this function has no effect. |
|---|
| 2031 | |
|---|
| 2032 | No BXPT_* calls are allowed until standby mode is exitted by calling |
|---|
| 2033 | BXPT_Resume. |
|---|
| 2034 | |
|---|
| 2035 | Returns: |
|---|
| 2036 | BERR_SUCCESS - Standby entered successfully |
|---|
| 2037 | BERR_UNKNOWN - Could not enter standby |
|---|
| 2038 | |
|---|
| 2039 | See Also: |
|---|
| 2040 | BXPT_Resume |
|---|
| 2041 | ****************************************************************************/ |
|---|
| 2042 | BERR_Code BXPT_Standby( |
|---|
| 2043 | BXPT_Handle hXpt, |
|---|
| 2044 | BXPT_StandbySettings *pSettings |
|---|
| 2045 | ); |
|---|
| 2046 | |
|---|
| 2047 | /*************************************************************************** |
|---|
| 2048 | Summary: |
|---|
| 2049 | Exit standby mode |
|---|
| 2050 | |
|---|
| 2051 | Description: |
|---|
| 2052 | Exit standby with XPT. This re-enables XPT clocks and upper-level SW is |
|---|
| 2053 | free to make BXPT_* calls again. |
|---|
| 2054 | |
|---|
| 2055 | Returns: |
|---|
| 2056 | BERR_SUCCESS - Standby exitted successfully |
|---|
| 2057 | BERR_UNKNOWN - Currently not in standby mode |
|---|
| 2058 | |
|---|
| 2059 | See Also: |
|---|
| 2060 | BXPT_Standby |
|---|
| 2061 | ****************************************************************************/ |
|---|
| 2062 | BERR_Code BXPT_Resume( |
|---|
| 2063 | BXPT_Handle hXpt |
|---|
| 2064 | ); |
|---|
| 2065 | |
|---|
| 2066 | /*************************************************************************** |
|---|
| 2067 | Summary: |
|---|
| 2068 | Get the capability params for the transport core. |
|---|
| 2069 | |
|---|
| 2070 | Description: |
|---|
| 2071 | The transport core has a certain resources, such as PID channels, that can |
|---|
| 2072 | vary in number from one version of the chip to the next. This function returns |
|---|
| 2073 | the quantity of each such resource in the device reference by the transport |
|---|
| 2074 | handle. See the structure definition for the complete list of info that is |
|---|
| 2075 | returned. |
|---|
| 2076 | |
|---|
| 2077 | Returns: |
|---|
| 2078 | void |
|---|
| 2079 | ****************************************************************************/ |
|---|
| 2080 | void BXPT_GetCapability( |
|---|
| 2081 | BXPT_Handle hXpt, /* [in] Which transport to get data. */ |
|---|
| 2082 | BXPT_Capability *Capability /* [out] Where to put the capability data. */ |
|---|
| 2083 | ); |
|---|
| 2084 | |
|---|
| 2085 | #if BXPT_HAS_IB_PID_PARSERS |
|---|
| 2086 | |
|---|
| 2087 | /*************************************************************************** |
|---|
| 2088 | Summary: |
|---|
| 2089 | Retrieves the current parser band configuration. |
|---|
| 2090 | |
|---|
| 2091 | Description: |
|---|
| 2092 | Read the current settings for the given parser band from the chip. Settings |
|---|
| 2093 | are returned in the structure that is passed in. See the structure for the |
|---|
| 2094 | complete list of supported settings. |
|---|
| 2095 | |
|---|
| 2096 | Returns: |
|---|
| 2097 | BERR_SUCCESS - Copied the parser config. |
|---|
| 2098 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2099 | |
|---|
| 2100 | See Also: |
|---|
| 2101 | BXPT_SetParserConfig |
|---|
| 2102 | ****************************************************************************/ |
|---|
| 2103 | BERR_Code BXPT_GetParserConfig( |
|---|
| 2104 | BXPT_Handle hXpt, /* [in] Handle for the transport to access. */ |
|---|
| 2105 | unsigned int ParserNum, /* [in] Which parser band to access. */ |
|---|
| 2106 | BXPT_ParserConfig *ParserConfig /* [out] The current settings */ |
|---|
| 2107 | ); |
|---|
| 2108 | |
|---|
| 2109 | /*************************************************************************** |
|---|
| 2110 | Summary: |
|---|
| 2111 | Sets the current parser band configuration. |
|---|
| 2112 | |
|---|
| 2113 | Description: |
|---|
| 2114 | Writes the given parser band configuration to the device. The caller supplies |
|---|
| 2115 | a structure containing the new parser band settings. The new settings take |
|---|
| 2116 | effect as soon as the function returns. |
|---|
| 2117 | |
|---|
| 2118 | Returns: |
|---|
| 2119 | BERR_SUCCESS - Transfered the parser config to the chip. |
|---|
| 2120 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2121 | |
|---|
| 2122 | See Also: |
|---|
| 2123 | BXPT_GetParserConfig |
|---|
| 2124 | ****************************************************************************/ |
|---|
| 2125 | BERR_Code BXPT_SetParserConfig( |
|---|
| 2126 | BXPT_Handle hXpt, /* [in] Handle for the transport to access. */ |
|---|
| 2127 | unsigned int ParserNum, /* [in] Which parser band to access. */ |
|---|
| 2128 | const BXPT_ParserConfig *ParserConfig /* [in] The new settings */ |
|---|
| 2129 | ); |
|---|
| 2130 | |
|---|
| 2131 | /*************************************************************************** |
|---|
| 2132 | Summary: |
|---|
| 2133 | Retrieves the default input band configuration. |
|---|
| 2134 | |
|---|
| 2135 | Description: |
|---|
| 2136 | Read the default settings for the given input band from the chip. Settings |
|---|
| 2137 | are returned in the structure that is passed in. See the structure for the |
|---|
| 2138 | complete list of supported settings. |
|---|
| 2139 | |
|---|
| 2140 | Returns: |
|---|
| 2141 | BERR_SUCCESS - Default config returned. |
|---|
| 2142 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2143 | |
|---|
| 2144 | See Also: |
|---|
| 2145 | BXPT_SetInputBandConfig |
|---|
| 2146 | ****************************************************************************/ |
|---|
| 2147 | BERR_Code BXPT_GetDefaultInputBandConfig( |
|---|
| 2148 | BXPT_Handle hXpt, /* [in] Handle for the transport to access. */ |
|---|
| 2149 | unsigned int BandNum, /* [in] Which input band to access. */ |
|---|
| 2150 | BXPT_InputBandConfig *InputBandConfig /* [out] The current settings */ |
|---|
| 2151 | ); |
|---|
| 2152 | |
|---|
| 2153 | /*************************************************************************** |
|---|
| 2154 | Summary: |
|---|
| 2155 | Retrieves the current input band configuration. |
|---|
| 2156 | |
|---|
| 2157 | Description: |
|---|
| 2158 | Read the current settings for the given input band from the chip. Settings |
|---|
| 2159 | are returned in the structure that is passed in. See the structure for the |
|---|
| 2160 | complete list of supported settings. |
|---|
| 2161 | |
|---|
| 2162 | Returns: |
|---|
| 2163 | BERR_SUCCESS - Retrieved the input band config. |
|---|
| 2164 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2165 | |
|---|
| 2166 | See Also: |
|---|
| 2167 | BXPT_SetInputBandConfig |
|---|
| 2168 | ****************************************************************************/ |
|---|
| 2169 | BERR_Code BXPT_GetInputBandConfig( |
|---|
| 2170 | BXPT_Handle hXpt, /* [in] Handle for the transport to access. */ |
|---|
| 2171 | unsigned int BandNum, /* [in] Which input band to access. */ |
|---|
| 2172 | BXPT_InputBandConfig *InputBandConfig /* [out] The current settings */ |
|---|
| 2173 | ); |
|---|
| 2174 | |
|---|
| 2175 | /*************************************************************************** |
|---|
| 2176 | Summary: |
|---|
| 2177 | Sets the current input band configuration. |
|---|
| 2178 | |
|---|
| 2179 | Description: |
|---|
| 2180 | Writes the given input band configuration to the device. The caller supplies |
|---|
| 2181 | a structure containing the new input band settings. The new settings take |
|---|
| 2182 | effect as soon as the function returns. |
|---|
| 2183 | |
|---|
| 2184 | Returns: |
|---|
| 2185 | BERR_SUCCESS - Transfered the input config to the chip. |
|---|
| 2186 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2187 | |
|---|
| 2188 | See Also: |
|---|
| 2189 | BXPT_GetInputBandConfig |
|---|
| 2190 | ****************************************************************************/ |
|---|
| 2191 | BERR_Code BXPT_SetInputBandConfig( |
|---|
| 2192 | BXPT_Handle hXpt, /* [in] Handle for the transport to access. */ |
|---|
| 2193 | unsigned int BandNum, /* [in] Which input band to access. */ |
|---|
| 2194 | const BXPT_InputBandConfig *InputBandConfig /* [in] The new settings */ |
|---|
| 2195 | ); |
|---|
| 2196 | |
|---|
| 2197 | /*************************************************************************** |
|---|
| 2198 | Summary: |
|---|
| 2199 | Configure parser band to pass ALL PIDS except NULLs. |
|---|
| 2200 | |
|---|
| 2201 | Description: |
|---|
| 2202 | Enable the parser band's all-pass mode. If enabled, the parser will ONLY |
|---|
| 2203 | filter out NULL PIDs. All other PIDs in the stream will forwarded on a |
|---|
| 2204 | single PID channel. That single PID channel fixed for each parser band: |
|---|
| 2205 | parser 0 will forward packets on PID channel 0, parser 1 will forward on |
|---|
| 2206 | PID channel 1, etc. |
|---|
| 2207 | |
|---|
| 2208 | Returns: |
|---|
| 2209 | BERR_SUCCESS - All-Pass mode changed per AllPass argument. |
|---|
| 2210 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2211 | ****************************************************************************/ |
|---|
| 2212 | BERR_Code BXPT_ParserAllPassMode( |
|---|
| 2213 | BXPT_Handle hXpt, /* [in] Handle for the transport to access. */ |
|---|
| 2214 | unsigned int BandNum, /* [in] Which input band to access. */ |
|---|
| 2215 | bool AllPass /* [in] All-pass enabled if true, or not if false. */ |
|---|
| 2216 | ); |
|---|
| 2217 | |
|---|
| 2218 | /*************************************************************************** |
|---|
| 2219 | Summary: |
|---|
| 2220 | Set a parser band's data source. |
|---|
| 2221 | |
|---|
| 2222 | Description: |
|---|
| 2223 | Select the data source for a given parser band. The allowable data sources |
|---|
| 2224 | are listed in the ParserDataSource enumeration. There may be (and probably |
|---|
| 2225 | will be) more than 1 instance of each ParserDataSource; the WhichSource |
|---|
| 2226 | parameter selects which instance is to be used. |
|---|
| 2227 | |
|---|
| 2228 | Returns: |
|---|
| 2229 | BERR_SUCCESS - Data source has been set in hardware. |
|---|
| 2230 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2231 | |
|---|
| 2232 | See Also: |
|---|
| 2233 | BXPT_GetParserDataSource |
|---|
| 2234 | ***************************************************************************/ |
|---|
| 2235 | BERR_Code BXPT_SetParserDataSource( |
|---|
| 2236 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2237 | unsigned int ParserBand, /* [in] Which parser to configure */ |
|---|
| 2238 | BXPT_DataSource DataSource, /* [in] The data source. */ |
|---|
| 2239 | unsigned int WhichSource /* [in] Which instance of the source */ |
|---|
| 2240 | ); |
|---|
| 2241 | |
|---|
| 2242 | /*************************************************************************** |
|---|
| 2243 | Summary: |
|---|
| 2244 | Get a parser band's data source. |
|---|
| 2245 | |
|---|
| 2246 | Description: |
|---|
| 2247 | Return the data source for a given parser band. The allowable data sources |
|---|
| 2248 | are listed in the ParserDataSource enumeration. There may be (and probably |
|---|
| 2249 | will be) more than 1 instance of each ParserDataSource; the WhichSource |
|---|
| 2250 | parameter denotes which instance is currently being used. |
|---|
| 2251 | |
|---|
| 2252 | Returns: |
|---|
| 2253 | BERR_SUCCESS - Data source retrieved from hardware. |
|---|
| 2254 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2255 | |
|---|
| 2256 | See Also: |
|---|
| 2257 | BXPT_SetParserDataSource |
|---|
| 2258 | ***************************************************************************/ |
|---|
| 2259 | BERR_Code BXPT_GetParserDataSource( |
|---|
| 2260 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2261 | unsigned int ParserBand, /* [in] Which parser to configure */ |
|---|
| 2262 | BXPT_DataSource *DataSource, /* [out] The data source. */ |
|---|
| 2263 | unsigned int *WhichSource /* [out] Which instance of the source */ |
|---|
| 2264 | ); |
|---|
| 2265 | |
|---|
| 2266 | /*************************************************************************** |
|---|
| 2267 | Summary: |
|---|
| 2268 | Enable or disable a parser band. |
|---|
| 2269 | |
|---|
| 2270 | Description: |
|---|
| 2271 | Start or stop PID parsing for the given parser band. When enabled, the parser |
|---|
| 2272 | band will remove all PIDs it receives that are not assigned to a PID channel. |
|---|
| 2273 | When disabled, no all PIDs will be removed. |
|---|
| 2274 | |
|---|
| 2275 | Returns: |
|---|
| 2276 | BERR_SUCCESS - Data source retrieved from hardware. |
|---|
| 2277 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2278 | ***************************************************************************/ |
|---|
| 2279 | BERR_Code BXPT_SetParserEnable( |
|---|
| 2280 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2281 | unsigned int ParserBand, /* [in] Which parser to configure */ |
|---|
| 2282 | bool Enable /* [in] Parser enabled if true, disabled if false. */ |
|---|
| 2283 | ); |
|---|
| 2284 | |
|---|
| 2285 | #endif |
|---|
| 2286 | |
|---|
| 2287 | /*************************************************************************** |
|---|
| 2288 | Summary: |
|---|
| 2289 | Enable the given PID channel. This will not allocate a PID channel. |
|---|
| 2290 | |
|---|
| 2291 | Description: |
|---|
| 2292 | Enable a PID channel. Sets the enable bit in the given PID channel's |
|---|
| 2293 | register. This function will NOT allocate a PID channel. |
|---|
| 2294 | |
|---|
| 2295 | Returns: |
|---|
| 2296 | BERR_SUCCESS - PID channel enabled. |
|---|
| 2297 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2298 | ***************************************************************************/ |
|---|
| 2299 | BERR_Code BXPT_EnablePidChannel( |
|---|
| 2300 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2301 | unsigned int PidChannelNum /* [in] Which PID channel. */ |
|---|
| 2302 | ); |
|---|
| 2303 | |
|---|
| 2304 | /*************************************************************************** |
|---|
| 2305 | Summary: |
|---|
| 2306 | Disable the given PID channel. |
|---|
| 2307 | |
|---|
| 2308 | Description: |
|---|
| 2309 | Clears the enable bit in the given PID channel's register. This call will |
|---|
| 2310 | not deallocate the channel; it simply turns the channel off. |
|---|
| 2311 | |
|---|
| 2312 | Returns: |
|---|
| 2313 | BERR_SUCCESS - PID channel disabled. |
|---|
| 2314 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2315 | |
|---|
| 2316 | See Also: |
|---|
| 2317 | BXPT_EnablePidChannel |
|---|
| 2318 | ***************************************************************************/ |
|---|
| 2319 | BERR_Code BXPT_DisablePidChannel( |
|---|
| 2320 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2321 | unsigned int PidChannelNum /* [in] Which PID channel. */ |
|---|
| 2322 | ); |
|---|
| 2323 | |
|---|
| 2324 | /*************************************************************************** |
|---|
| 2325 | Summary: |
|---|
| 2326 | Allocate a new PID channel. |
|---|
| 2327 | |
|---|
| 2328 | Description: |
|---|
| 2329 | Allocate an unused PID channel, and return that channel's number. This is |
|---|
| 2330 | usefull for cases where the caller needs a PID channel, but hasn't |
|---|
| 2331 | determined which PID or parser band that channel will be assigned to. |
|---|
| 2332 | |
|---|
| 2333 | The caller specifies if the channel must have a message buffer associated |
|---|
| 2334 | with it. In some architectures, PID channels exist that don't have message |
|---|
| 2335 | buffer support. Channels used solely for audio or video decoding are one |
|---|
| 2336 | example. |
|---|
| 2337 | |
|---|
| 2338 | Returns: |
|---|
| 2339 | BERR_SUCCESS - PID channel allocated. |
|---|
| 2340 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2341 | |
|---|
| 2342 | See Also: |
|---|
| 2343 | BXPT_FreePidChannel, BXPT_FreeAllPidChannels |
|---|
| 2344 | ***************************************************************************/ |
|---|
| 2345 | BERR_Code BXPT_AllocPidChannel( |
|---|
| 2346 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2347 | bool NeedMessageBuffer, /* [in] Is a message buffer required? */ |
|---|
| 2348 | unsigned int *PidChannelNum /* [out] The allocated channel number. */ |
|---|
| 2349 | ); |
|---|
| 2350 | |
|---|
| 2351 | /*************************************************************************** |
|---|
| 2352 | Summary: |
|---|
| 2353 | Set the PID and parser band for a given PID channel. |
|---|
| 2354 | |
|---|
| 2355 | Description: |
|---|
| 2356 | Configure the PID and parser band for the given PID channel. It is not |
|---|
| 2357 | necessary to allocate the PID channel first, although it is recommended that |
|---|
| 2358 | this be done. The PID channel is not enabled; see BXPT_EnablePidChannel(). |
|---|
| 2359 | |
|---|
| 2360 | Note: For 74xx builds, the hardware supports two different classes of parsers: |
|---|
| 2361 | Input Band and Playback Channel. The two are entirely separate and can't be |
|---|
| 2362 | used interchangably. To select a playback parser, the Band argument must |
|---|
| 2363 | be wrapped is wrapped in a macro that indicates the argument refers to a |
|---|
| 2364 | playback parser, like so: |
|---|
| 2365 | |
|---|
| 2366 | BXPT_ConfigurePidChannel( hXpt, PidChannelNum, Pid, BXPT_PB_PARSER( BandNum ) ); |
|---|
| 2367 | |
|---|
| 2368 | If the BXPT_PB_PARSER() macro is not used, BandNum is taken to refer to an |
|---|
| 2369 | Input Band parser. |
|---|
| 2370 | |
|---|
| 2371 | Returns: |
|---|
| 2372 | BERR_SUCCESS - PID channel configured. |
|---|
| 2373 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2374 | |
|---|
| 2375 | See Also: |
|---|
| 2376 | BXPT_EnablePidChannel, BXPT_SetPidChnlConfig |
|---|
| 2377 | ***************************************************************************/ |
|---|
| 2378 | BERR_Code BXPT_ConfigurePidChannel( |
|---|
| 2379 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2380 | unsigned int PidChannelNum, /* [in] Which channel to configure. */ |
|---|
| 2381 | unsigned int Pid, /* [in] PID to use. */ |
|---|
| 2382 | unsigned int Band /* [in] The parser band to use. */ |
|---|
| 2383 | ); |
|---|
| 2384 | |
|---|
| 2385 | #ifdef ENABLE_PLAYBACK_MUX |
|---|
| 2386 | /*************************************************************************** |
|---|
| 2387 | Summary: |
|---|
| 2388 | Sets a PID channel to the switched state. |
|---|
| 2389 | |
|---|
| 2390 | Description: |
|---|
| 2391 | This function turns on or off PID channel switching on the specified PID |
|---|
| 2392 | channel. This is used to provide a multiplexed input on top of a playback |
|---|
| 2393 | parser (specifically the last playback parser). |
|---|
| 2394 | |
|---|
| 2395 | Returns: |
|---|
| 2396 | BERR_SUCCESS - PID channel configured. |
|---|
| 2397 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2398 | |
|---|
| 2399 | See Also: |
|---|
| 2400 | BXPT_SwitchPidChannel |
|---|
| 2401 | ***************************************************************************/ |
|---|
| 2402 | BERR_Code BXPT_SetPidChannelSwitched( |
|---|
| 2403 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2404 | unsigned int PidChannelNum, /* [in] Which PID channel. */ |
|---|
| 2405 | bool IsSwitched /* [in] Switch state. */ |
|---|
| 2406 | ); |
|---|
| 2407 | |
|---|
| 2408 | /*************************************************************************** |
|---|
| 2409 | Summary: |
|---|
| 2410 | Sets a PID channel to the switched state. Callable from an interrupt context. |
|---|
| 2411 | |
|---|
| 2412 | Description: |
|---|
| 2413 | Same as BXPT_SetPidChannelSwitched() but callable from an ISR. |
|---|
| 2414 | |
|---|
| 2415 | Returns: |
|---|
| 2416 | BERR_SUCCESS - PID channel configured. |
|---|
| 2417 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2418 | |
|---|
| 2419 | See Also: |
|---|
| 2420 | BXPT_SwitchPidChannel |
|---|
| 2421 | ***************************************************************************/ |
|---|
| 2422 | BERR_Code BXPT_SetPidChannelSwitched_isr( |
|---|
| 2423 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2424 | unsigned int PidChannelNum, /* [in] Which PID channel. */ |
|---|
| 2425 | bool IsSwitched /* [in] Switch state. */ |
|---|
| 2426 | ); |
|---|
| 2427 | |
|---|
| 2428 | /*************************************************************************** |
|---|
| 2429 | Summary: |
|---|
| 2430 | Enables/disables a switched PID channel. Never to be used within an ISR. |
|---|
| 2431 | |
|---|
| 2432 | Description: |
|---|
| 2433 | This function is used to enable or disable a switched PID channel. Switched |
|---|
| 2434 | PID channels are used to provide a multiplexed input on top of a playback |
|---|
| 2435 | parser (specifically the last playback parser). |
|---|
| 2436 | |
|---|
| 2437 | Returns: |
|---|
| 2438 | TRUE - PID channel was enabled/disabled |
|---|
| 2439 | FALSE - PID channel was unable to be enabled/disabled |
|---|
| 2440 | |
|---|
| 2441 | See Also: |
|---|
| 2442 | BXPT_SetPidChannelSwitched, BXPT_SwitchPidChannelISR |
|---|
| 2443 | ***************************************************************************/ |
|---|
| 2444 | bool BXPT_SwitchPidChannel( |
|---|
| 2445 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2446 | unsigned int PidChannelNum, /* [in] Which PID channel. */ |
|---|
| 2447 | bool EnableIt /* [in] Enabled state. */ |
|---|
| 2448 | ); |
|---|
| 2449 | |
|---|
| 2450 | /*************************************************************************** |
|---|
| 2451 | Summary: |
|---|
| 2452 | Enables/disables a switched PID channel. To be used only within an ISR. |
|---|
| 2453 | |
|---|
| 2454 | Description: |
|---|
| 2455 | This function is used to enable or disable a switched PID channel. Switched |
|---|
| 2456 | PID channels are used to provide a multiplexed input on top of a playback |
|---|
| 2457 | parser (specifically the last playback parser). |
|---|
| 2458 | |
|---|
| 2459 | Returns: |
|---|
| 2460 | TRUE - PID channel was enabled/disabled |
|---|
| 2461 | FALSE - PID channel was unable to be enabled/disabled |
|---|
| 2462 | |
|---|
| 2463 | See Also: |
|---|
| 2464 | BXPT_SetPidChannelSwitched, BXPT_SwitchPidChannel |
|---|
| 2465 | ***************************************************************************/ |
|---|
| 2466 | bool BXPT_SwitchPidChannelISR( |
|---|
| 2467 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2468 | unsigned int PidChannelNum, /* [in] Which PID channel. */ |
|---|
| 2469 | bool EnableIt /* [in] Enabled state. */ |
|---|
| 2470 | ); |
|---|
| 2471 | |
|---|
| 2472 | /*************************************************************************** |
|---|
| 2473 | Summary: |
|---|
| 2474 | Set the number of playback blocks to be used for playback muxing. |
|---|
| 2475 | |
|---|
| 2476 | Description: |
|---|
| 2477 | This function is used to specify how many hardware playback blocks are |
|---|
| 2478 | to be used for time-multiplexing playback of transport streams. Of the |
|---|
| 2479 | available HW playback blocks, the last "Num" blocks will be used for muxing. |
|---|
| 2480 | This function must only be called once and called during system initialization. |
|---|
| 2481 | |
|---|
| 2482 | Returns: |
|---|
| 2483 | BERR_SUCCESS - Playback blocks are reserved for muxing. |
|---|
| 2484 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2485 | |
|---|
| 2486 | ***************************************************************************/ |
|---|
| 2487 | BERR_Code BXPT_SetNumPlaybackMux( |
|---|
| 2488 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2489 | unsigned int Num /* [in] Number of playback mux blocks */ |
|---|
| 2490 | ); |
|---|
| 2491 | |
|---|
| 2492 | #endif /*ENABLE_PLAYBACK_MUX*/ |
|---|
| 2493 | |
|---|
| 2494 | /*************************************************************************** |
|---|
| 2495 | Summary: |
|---|
| 2496 | Free the given PID channel. |
|---|
| 2497 | |
|---|
| 2498 | Description: |
|---|
| 2499 | An allocated PID channel is returned to the pool of available channel. The |
|---|
| 2500 | PID channel must have been previously allocated by a call to |
|---|
| 2501 | BXPT_AllocPidChannel(). |
|---|
| 2502 | |
|---|
| 2503 | Returns: |
|---|
| 2504 | BERR_SUCCESS - PID channel freed. |
|---|
| 2505 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2506 | |
|---|
| 2507 | See Also: |
|---|
| 2508 | BXPT_EnablePidChannel, BXPT_AllocPidChannel |
|---|
| 2509 | ***************************************************************************/ |
|---|
| 2510 | BERR_Code BXPT_FreePidChannel( |
|---|
| 2511 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2512 | unsigned int PidChannelNum /* [in] PID channel to free up. */ |
|---|
| 2513 | ); |
|---|
| 2514 | |
|---|
| 2515 | /*************************************************************************** |
|---|
| 2516 | Summary: |
|---|
| 2517 | Free all allocated PID channels. |
|---|
| 2518 | |
|---|
| 2519 | Description: |
|---|
| 2520 | Release ALL the PID channels associated with the given data transport core. |
|---|
| 2521 | Each channel is released. The PID channels must have been previously |
|---|
| 2522 | allocated by a call to BXPT_AllocPidChannel(). |
|---|
| 2523 | |
|---|
| 2524 | Returns: |
|---|
| 2525 | void. |
|---|
| 2526 | |
|---|
| 2527 | See Also: |
|---|
| 2528 | BXPT_EnablePidChannel, BXPT_AllocPidChannel |
|---|
| 2529 | ***************************************************************************/ |
|---|
| 2530 | void BXPT_FreeAllPidChannels( |
|---|
| 2531 | BXPT_Handle hXpt /* [in] Handle for this transport */ |
|---|
| 2532 | ); |
|---|
| 2533 | |
|---|
| 2534 | /*************************************************************************** |
|---|
| 2535 | Summary: |
|---|
| 2536 | Request allocation of a specific PID channel. |
|---|
| 2537 | |
|---|
| 2538 | Description: |
|---|
| 2539 | In some cases, the user may want to use a specific PID channel. There is no |
|---|
| 2540 | way to guarentee which channel BXPT_AllocPidChannel() will return, so this |
|---|
| 2541 | function has been added to allow users to 'allocate' a specific PID channel. |
|---|
| 2542 | If the request succeedes, the PidChannelNum can be used exactly like a |
|---|
| 2543 | PID channel allocated by BXPT_AllocPidChannel(). NOTE: when the user nolonger |
|---|
| 2544 | needs the requested PID channel, BXPT_FreePidChannel() should be called to |
|---|
| 2545 | tell the porting interface that channel is available for alloc. |
|---|
| 2546 | |
|---|
| 2547 | Returns: |
|---|
| 2548 | BERR_SUCCESS - Read offset has been updated. |
|---|
| 2549 | BERR_INVALID_PARAMETER - Bad PidChannelNum |
|---|
| 2550 | BXPT_ERR_PID_ALREADY_ALLOCATED - The channel has already been allocated. |
|---|
| 2551 | |
|---|
| 2552 | See Also: |
|---|
| 2553 | BXPT_AllocPidChannel(), BXPT_FreePidChannel() |
|---|
| 2554 | ***************************************************************************/ |
|---|
| 2555 | BERR_Code BXPT_RequestPidChannel( |
|---|
| 2556 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2557 | unsigned int PidChannelNum /* [out] The channel number the user wants. */ |
|---|
| 2558 | ); |
|---|
| 2559 | |
|---|
| 2560 | #if BXPT_HAS_MESG_BUFFERS |
|---|
| 2561 | |
|---|
| 2562 | /*************************************************************************** |
|---|
| 2563 | Summary: |
|---|
| 2564 | Allocate a PSI message filter. |
|---|
| 2565 | |
|---|
| 2566 | Description: |
|---|
| 2567 | Allocate a 16-byte PSI filter, from the requested filter bank. The first unused |
|---|
| 2568 | filter is returned. The filters used for a given PID channel must all come |
|---|
| 2569 | from the same bank. Note that only banks 0 and 1 can be used. |
|---|
| 2570 | |
|---|
| 2571 | Returns: |
|---|
| 2572 | BERR_SUCCESS - Filter allocated. |
|---|
| 2573 | BXPT_ERR_NO_AVAILABLE_RESOURCES - No filters available |
|---|
| 2574 | |
|---|
| 2575 | See Also: |
|---|
| 2576 | BXPT_FreePSIFilter |
|---|
| 2577 | ***************************************************************************/ |
|---|
| 2578 | BERR_Code BXPT_AllocPSIFilter( |
|---|
| 2579 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2580 | unsigned int Bank, /* [in] Which bank to allocate from. */ |
|---|
| 2581 | unsigned int *FilterNum /* [out] Number for the allocated filter. */ |
|---|
| 2582 | ); |
|---|
| 2583 | |
|---|
| 2584 | /*************************************************************************** |
|---|
| 2585 | Summary: |
|---|
| 2586 | Free a PSI message filter. |
|---|
| 2587 | |
|---|
| 2588 | Description: |
|---|
| 2589 | Frees a previously allocated filter. The filter is marked as available for |
|---|
| 2590 | allocation. |
|---|
| 2591 | |
|---|
| 2592 | Returns: |
|---|
| 2593 | BERR_SUCCESS - Filter freed. |
|---|
| 2594 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2595 | |
|---|
| 2596 | See Also: |
|---|
| 2597 | BXPT_AllocPSIFilter |
|---|
| 2598 | ***************************************************************************/ |
|---|
| 2599 | BERR_Code BXPT_FreePSIFilter( |
|---|
| 2600 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2601 | unsigned int Bank, /* [in] Which bank to free the filter from. */ |
|---|
| 2602 | unsigned int FilterNum /* [in] Which filter to free up. */ |
|---|
| 2603 | ); |
|---|
| 2604 | |
|---|
| 2605 | /*************************************************************************** |
|---|
| 2606 | Summary: |
|---|
| 2607 | Return the filtering arrays for a PSI filter. |
|---|
| 2608 | |
|---|
| 2609 | Description: |
|---|
| 2610 | Retrieve the coefficient, mask, and exclusion byte arrays for a given |
|---|
| 2611 | filter. The data is copied into a structure, which was passed in by pointer. |
|---|
| 2612 | |
|---|
| 2613 | Returns: |
|---|
| 2614 | BERR_SUCCESS - PID channel configured. |
|---|
| 2615 | BERR_INVALID_PARAMETER - Bad input parameter. |
|---|
| 2616 | |
|---|
| 2617 | See Also: |
|---|
| 2618 | BXPT_AllocPSIFilter, BXPT_SetFilter |
|---|
| 2619 | ***************************************************************************/ |
|---|
| 2620 | BERR_Code BXPT_GetFilter( |
|---|
| 2621 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2622 | unsigned int Bank, /* [in] Which bank the filter belongs to. */ |
|---|
| 2623 | unsigned int FilterNum, /* [in] Which filter to get data from. */ |
|---|
| 2624 | BXPT_Filter *Filter /* [out] Filter data */ |
|---|
| 2625 | ); |
|---|
| 2626 | |
|---|
| 2627 | /*************************************************************************** |
|---|
| 2628 | Summary: |
|---|
| 2629 | Load the filtering arrays for a PSI filter. |
|---|
| 2630 | |
|---|
| 2631 | Description: |
|---|
| 2632 | Load the coefficient, mask, and exclusion byte arrays for a given filter, |
|---|
| 2633 | using data passed in by the caller. |
|---|
| 2634 | |
|---|
| 2635 | Returns: |
|---|
| 2636 | BERR_SUCCESS - PID channel configured. |
|---|
| 2637 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2638 | |
|---|
| 2639 | See Also: |
|---|
| 2640 | BXPT_AllocPSIFilter, BXPT_GetFilter |
|---|
| 2641 | ***************************************************************************/ |
|---|
| 2642 | BERR_Code BXPT_SetFilter( |
|---|
| 2643 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2644 | unsigned int Bank, /* [in] Which bank the filter belongs to. */ |
|---|
| 2645 | unsigned int FilterNum, /* [in] Which filter to get data from. */ |
|---|
| 2646 | const BXPT_Filter *Filter /* [in] Filter data to be loaded */ |
|---|
| 2647 | ); |
|---|
| 2648 | |
|---|
| 2649 | /*************************************************************************** |
|---|
| 2650 | Summary: |
|---|
| 2651 | Change a filter's coefficeint byte. |
|---|
| 2652 | |
|---|
| 2653 | Description: |
|---|
| 2654 | Change a single coefficient byte in a given filter. Caller specifies which |
|---|
| 2655 | byte by giving an offset into the filter array; this is the same offset |
|---|
| 2656 | the byte had in the BXPT_Filter arrays used to initialize the filter. |
|---|
| 2657 | |
|---|
| 2658 | Returns: |
|---|
| 2659 | BERR_SUCCESS - Coeffecient byte changed. |
|---|
| 2660 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2661 | |
|---|
| 2662 | See Also: |
|---|
| 2663 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter |
|---|
| 2664 | ***************************************************************************/ |
|---|
| 2665 | BERR_Code BXPT_ChangeFilterCoefficientByte( |
|---|
| 2666 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2667 | unsigned int Bank, /* [in] Which bank the filter belongs to. */ |
|---|
| 2668 | unsigned int FilterNum, /* [in] Which filter to change. */ |
|---|
| 2669 | unsigned int ByteOffset, /* [in] Which byte in the array to change */ |
|---|
| 2670 | uint8_t FilterByte /* [in] New filter byte to be written. */ |
|---|
| 2671 | ); |
|---|
| 2672 | |
|---|
| 2673 | /*************************************************************************** |
|---|
| 2674 | Summary: |
|---|
| 2675 | Change a filter's mask byte. |
|---|
| 2676 | |
|---|
| 2677 | Description: |
|---|
| 2678 | Change a single mask byte in a given filter. Caller specifies which |
|---|
| 2679 | byte by giving an offset into the filter array; this is the same offset |
|---|
| 2680 | the byte had in the BXPT_Filter arrays used to initialize the filter. |
|---|
| 2681 | |
|---|
| 2682 | Returns: |
|---|
| 2683 | BERR_SUCCESS - Mask byte changed. |
|---|
| 2684 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2685 | |
|---|
| 2686 | See Also: |
|---|
| 2687 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter |
|---|
| 2688 | ***************************************************************************/ |
|---|
| 2689 | BERR_Code BXPT_ChangeFilterMaskByte( |
|---|
| 2690 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2691 | unsigned int Bank, /* [in] Which bank the filter belongs to. */ |
|---|
| 2692 | unsigned int FilterNum, /* [in] Which filter to change. */ |
|---|
| 2693 | unsigned int ByteOffset, /* [in] Which byte in the array to change */ |
|---|
| 2694 | uint8_t MaskByte /* [in] New mask byte to be written. */ |
|---|
| 2695 | ); |
|---|
| 2696 | |
|---|
| 2697 | /*************************************************************************** |
|---|
| 2698 | Summary: |
|---|
| 2699 | Change a filter's exclusion byte. |
|---|
| 2700 | |
|---|
| 2701 | Description: |
|---|
| 2702 | Change a single exclusion byte in a given filter. Caller specifies which |
|---|
| 2703 | byte by giving an offset into the filter array; this is the same offset |
|---|
| 2704 | the byte had in the BXPT_Filter arrays used to initialize the filter. |
|---|
| 2705 | |
|---|
| 2706 | Returns: |
|---|
| 2707 | BERR_SUCCESS - Exclusion byte changed. |
|---|
| 2708 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2709 | |
|---|
| 2710 | See Also: |
|---|
| 2711 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter |
|---|
| 2712 | ***************************************************************************/ |
|---|
| 2713 | BERR_Code BXPT_ChangeFilterExclusionByte( |
|---|
| 2714 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2715 | unsigned int Bank, /* [in] Which bank the filter belongs to. */ |
|---|
| 2716 | unsigned int FilterNum, /* [in] Which filter to change. */ |
|---|
| 2717 | unsigned int ByteOffset, /* [in] Which byte in the array to change */ |
|---|
| 2718 | uint8_t ExclusionByte /* [in] New exclusion byte to be written. */ |
|---|
| 2719 | ); |
|---|
| 2720 | |
|---|
| 2721 | /* |
|---|
| 2722 | NOTE: The BXPT_RemoveFilterFromGroup() API NO LONGER MAKES SENSE WITH THE |
|---|
| 2723 | PID2BUF HARDWARE. USERS SHOULD CALL BXPT_RemoveFilterFromGroupAndBuffer |
|---|
| 2724 | instead. |
|---|
| 2725 | */ |
|---|
| 2726 | /*************************************************************************** |
|---|
| 2727 | Summary: |
|---|
| 2728 | Remove a filter from a group. |
|---|
| 2729 | |
|---|
| 2730 | Description: |
|---|
| 2731 | Remove a given filter from the group of filters maintained in the Settings |
|---|
| 2732 | structure. The filter will no longer be applied to the PID that the group |
|---|
| 2733 | is associated with. |
|---|
| 2734 | |
|---|
| 2735 | Returns: |
|---|
| 2736 | BERR_SUCCESS - Filter successfully removed to the group. |
|---|
| 2737 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2738 | |
|---|
| 2739 | See Also: |
|---|
| 2740 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, BXPT_AddFilterToGroup |
|---|
| 2741 | ***************************************************************************/ |
|---|
| 2742 | BERR_Code BXPT_RemoveFilterFromGroup( |
|---|
| 2743 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2744 | unsigned int FilterNum, /* [in] Which filter to remove. */ |
|---|
| 2745 | BXPT_PsiMessageSettings *Settings /* [in,out] Filter group to add to. */ |
|---|
| 2746 | ); |
|---|
| 2747 | |
|---|
| 2748 | /*************************************************************************** |
|---|
| 2749 | Summary: |
|---|
| 2750 | Remove a filter from a group. |
|---|
| 2751 | |
|---|
| 2752 | Description: |
|---|
| 2753 | Remove a given filter from the group of filters maintained in the Settings |
|---|
| 2754 | structure. The filter will no longer be applied to the PID that the group |
|---|
| 2755 | is associated with. |
|---|
| 2756 | |
|---|
| 2757 | Returns: |
|---|
| 2758 | BERR_SUCCESS - Filter successfully removed to the group. |
|---|
| 2759 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2760 | |
|---|
| 2761 | See Also: |
|---|
| 2762 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, BXPT_AddFilterToGroup |
|---|
| 2763 | ***************************************************************************/ |
|---|
| 2764 | BERR_Code BXPT_RemoveFilterFromGroupAndBuffer( |
|---|
| 2765 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2766 | unsigned int FilterNum, /* [in] Which filter to remove. */ |
|---|
| 2767 | unsigned int BufferNum, /* [in] Which message buffer is using this filter. */ |
|---|
| 2768 | BXPT_PsiMessageSettings *Settings /* [in] Filter group to add to. */ |
|---|
| 2769 | ); |
|---|
| 2770 | |
|---|
| 2771 | /*************************************************************************** |
|---|
| 2772 | Summary: |
|---|
| 2773 | Get default values for the PSI Settings structure. |
|---|
| 2774 | |
|---|
| 2775 | Description: |
|---|
| 2776 | Full in the given BXPT_PsiMessageSettings struct with default values. |
|---|
| 2777 | |
|---|
| 2778 | Returns: |
|---|
| 2779 | void |
|---|
| 2780 | |
|---|
| 2781 | See Also: |
|---|
| 2782 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, BXPT_AddFilterToGroup, |
|---|
| 2783 | BXPT_StopPsiMessageCapture, BXPT_SetPidChannelBuffer |
|---|
| 2784 | ***************************************************************************/ |
|---|
| 2785 | void BXPT_GetDefaultPsiSettings( |
|---|
| 2786 | BXPT_PsiMessageSettings *Settings /* [out] PSI defaults */ |
|---|
| 2787 | ); |
|---|
| 2788 | |
|---|
| 2789 | /*************************************************************************** |
|---|
| 2790 | Summary: |
|---|
| 2791 | Check for new data in a message buffer. |
|---|
| 2792 | |
|---|
| 2793 | Description: |
|---|
| 2794 | Check for new messages in the buffer associated with the given PID channel. |
|---|
| 2795 | If there are messages, the address of the buffer is returned and the |
|---|
| 2796 | 'MessageSize' and 'MoreDataAvailable' params are updated as described below. |
|---|
| 2797 | Note that their could be more than one new message in the buffer. |
|---|
| 2798 | |
|---|
| 2799 | The 'MessageSize' and 'MoreDataAvailable' params are used together to |
|---|
| 2800 | give the number of bytes that the messages occupy. Since the hardware buffer |
|---|
| 2801 | is circular, the messages may have wrapped around the end of the buffer to |
|---|
| 2802 | the beginning. The 'MoreDataAvailable' param will be set to true if the |
|---|
| 2803 | wrap-around condition has occurred. |
|---|
| 2804 | |
|---|
| 2805 | Thus, if 'MoreDataAvailable' is false, the value of 'MessageSize' is the |
|---|
| 2806 | total size of the messages. The user should read the data from 'BufferAddr', |
|---|
| 2807 | then call BXPT_UpdateReadOffset() to signal that the data has been read. |
|---|
| 2808 | |
|---|
| 2809 | If 'MoreDataAvailable' is true, the messages have wrapped. In this case, |
|---|
| 2810 | 'MessageSize' is the number of bytes from the start of the messages to the |
|---|
| 2811 | end of the buffer. After reading the data and calling BXPT_UpdateReadOffset(), |
|---|
| 2812 | the user should call BXPT_CheckBuffer() again to retrieve the rest of the |
|---|
| 2813 | message bytes. |
|---|
| 2814 | |
|---|
| 2815 | Returns: |
|---|
| 2816 | BERR_SUCCESS - No errors found during the check. |
|---|
| 2817 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2818 | |
|---|
| 2819 | See Also: |
|---|
| 2820 | BXPT_UpdateReadOffset, BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, |
|---|
| 2821 | BXPT_AddFilterToGroup, BXPT_SetupPidChannelRecord, |
|---|
| 2822 | BXPT_SetupChannelForPsiMessages |
|---|
| 2823 | ***************************************************************************/ |
|---|
| 2824 | BERR_Code BXPT_CheckBuffer( |
|---|
| 2825 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2826 | unsigned int MesgBuffNum, /* [in] Message buffer to check. This is same as PidChNum in case of 1-to-1 mapping*/ |
|---|
| 2827 | uint8_t **BufferAddr, /* [out] Address of the buffer. */ |
|---|
| 2828 | size_t *MessageSize, /* [out] Total size of new messages. */ |
|---|
| 2829 | bool *MoreDataAvailable /* [out] TRUE if the buffer wrapped. */ |
|---|
| 2830 | ); |
|---|
| 2831 | |
|---|
| 2832 | /*************************************************************************** |
|---|
| 2833 | Summary: |
|---|
| 2834 | Check for new data in a message buffer. Account for any the possibilty that |
|---|
| 2835 | the data wrapped around the end of the buffer. |
|---|
| 2836 | |
|---|
| 2837 | Description: |
|---|
| 2838 | Check for new messages in the buffer associated with the given PID channel. |
|---|
| 2839 | Two conditions could occur: the data did not wrap around, or it did. If the |
|---|
| 2840 | data did not wrap, the address of the buffer is returned in "BufferAddr" and |
|---|
| 2841 | the 'MessageSize' is set to the number of bytes in the message. "WrapBufferAddr" |
|---|
| 2842 | will be NULL and "MessageSizeAfterWrap" will be 0. |
|---|
| 2843 | |
|---|
| 2844 | If the data did wrap, "BufferAddr" and the 'MessageSize' will reflect the data |
|---|
| 2845 | before the wrap around, while "WrapBufferAddr" will be non-NULL and |
|---|
| 2846 | "MessageSizeAfterWrap" will indicate the number of bytes after the wrap. |
|---|
| 2847 | |
|---|
| 2848 | Returns: |
|---|
| 2849 | BERR_SUCCESS - No errors found during the check. |
|---|
| 2850 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2851 | |
|---|
| 2852 | See Also: |
|---|
| 2853 | BXPT_UpdateReadOffset, BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, |
|---|
| 2854 | BXPT_AddFilterToGroup, BXPT_SetupPidChannelRecord, |
|---|
| 2855 | BXPT_SetupChannelForPsiMessages |
|---|
| 2856 | ***************************************************************************/ |
|---|
| 2857 | BERR_Code BXPT_CheckBufferWithWrap( |
|---|
| 2858 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2859 | unsigned int MesgBufferNum, /* [in] buffer to check.*/ |
|---|
| 2860 | uint8_t **BufferAddr, /* [out] Address of the buffer. */ |
|---|
| 2861 | size_t *MessageSizeBeforeWrap, /* [out] Total size of new messages before the buffer wrapped. */ |
|---|
| 2862 | uint8_t **WrapBufferAddr, /* [out] Address of the wraparound data. 0 if no wrap */ |
|---|
| 2863 | size_t *MessageSizeAfterWrap /* Total size of message starting at the base. NULL if no wrap */ |
|---|
| 2864 | ); |
|---|
| 2865 | |
|---|
| 2866 | /*************************************************************************** |
|---|
| 2867 | Summary: |
|---|
| 2868 | Check for new data in a message buffer, and copy any new data into the user |
|---|
| 2869 | supplied storage location. |
|---|
| 2870 | |
|---|
| 2871 | Description: |
|---|
| 2872 | Check for new messages in the given message buffer. |
|---|
| 2873 | If new messages are available, they will be copied into the user supplied |
|---|
| 2874 | storage area, up to the number of bytes passed in through the BufferSize |
|---|
| 2875 | parameter. On return, BufferSize will indicate how many bytes where actually |
|---|
| 2876 | copied in. The user-supplied storage area should be the same size as the |
|---|
| 2877 | message buffer, to insure that no data is lost due to insufficient storage. |
|---|
| 2878 | |
|---|
| 2879 | This call supports the use of duplicated PID channels. In that case, some |
|---|
| 2880 | PSI data in the message buffers may be corrupted. If the buffer contains |
|---|
| 2881 | PSI data, the data will be validated by checking the length field of each |
|---|
| 2882 | PSI message. If any corrupted messages are seen, the message buffer will |
|---|
| 2883 | be discarded and this call will not copy any data into the user-supplied |
|---|
| 2884 | storage. |
|---|
| 2885 | |
|---|
| 2886 | If duplicated PIDs are used, this call should be used instead of |
|---|
| 2887 | BXPT_CheckBuffer() and BXPT_UpdateReadOffset(). This call can also be used |
|---|
| 2888 | for any cases where BXPT_CheckBuffer() and BXPT_UpdateReadOffset() are |
|---|
| 2889 | currently used. |
|---|
| 2890 | |
|---|
| 2891 | Returns: |
|---|
| 2892 | BERR_SUCCESS - No errors found during the check. |
|---|
| 2893 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2894 | |
|---|
| 2895 | See Also: |
|---|
| 2896 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, BXPT_AddFilterToGroup, |
|---|
| 2897 | BXPT_SetupPidChannelRecord, BXPT_SetupChannelForPsiMessages |
|---|
| 2898 | ***************************************************************************/ |
|---|
| 2899 | BERR_Code BXPT_GetBuffer( |
|---|
| 2900 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2901 | unsigned int MesgBuffNum, /* [in] Message buffer to check. This is same as PidChNum in case of 1-to-1 mapping*/ |
|---|
| 2902 | uint8_t *BufferAddr, /* [out] Address of the buffer. */ |
|---|
| 2903 | size_t *BufferSize /* [in,out] Size of message buffer (on input), size of new messages (on output). */ |
|---|
| 2904 | ); |
|---|
| 2905 | |
|---|
| 2906 | /*************************************************************************** |
|---|
| 2907 | Summary: |
|---|
| 2908 | Check for new data in a message buffer, and copy any new data into the user |
|---|
| 2909 | supplied storage location. |
|---|
| 2910 | |
|---|
| 2911 | Description: |
|---|
| 2912 | Check BXPT_GetBuffer() for more description. Use this API only in case if you want to |
|---|
| 2913 | avoid BXPT_UpdateReadOffset() entering into critical section. |
|---|
| 2914 | ***************************************************************************/ |
|---|
| 2915 | BERR_Code BXPT_GetBuffer_isr( |
|---|
| 2916 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2917 | unsigned int MesgBuffNum, /* [in] Message buffer to check. This is same as PidChNum in case of 1-to-1 mapping*/ |
|---|
| 2918 | uint8_t *BufferAddr, /* [out] Address of the buffer. */ |
|---|
| 2919 | size_t *BufferSize /* [in,out] Size of message buffer (on input), size of new messages (on output). */ |
|---|
| 2920 | ); |
|---|
| 2921 | |
|---|
| 2922 | /*************************************************************************** |
|---|
| 2923 | Summary: |
|---|
| 2924 | Update a message buffer's read offset. |
|---|
| 2925 | |
|---|
| 2926 | Description: |
|---|
| 2927 | Update the read pointer of the given message buffer. Doing so tells the |
|---|
| 2928 | transport hardware that the buffer space 'behind' the read pointer is |
|---|
| 2929 | available for new messages. This action clears the interrupt asserted when |
|---|
| 2930 | new data has been transfered into the buffer. |
|---|
| 2931 | |
|---|
| 2932 | Returns: |
|---|
| 2933 | BERR_SUCCESS - Read offset has been updated. |
|---|
| 2934 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2935 | |
|---|
| 2936 | See Also: |
|---|
| 2937 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, BXPT_AddFilterToGroup, |
|---|
| 2938 | BXPT_SetupPidChannelRecord, BXPT_SetupChannelForPsiMessages |
|---|
| 2939 | ***************************************************************************/ |
|---|
| 2940 | BERR_Code BXPT_UpdateReadOffset( |
|---|
| 2941 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2942 | unsigned int MesgBuffNum, /* [in] Message buffer to check. This is same as PidChNum in case of 1-to-1 mapping*/ |
|---|
| 2943 | size_t BytesRead /* [in] Number of bytes read. */ |
|---|
| 2944 | ); |
|---|
| 2945 | |
|---|
| 2946 | |
|---|
| 2947 | /*************************************************************************** |
|---|
| 2948 | Summary: |
|---|
| 2949 | Update a message buffer's read offset, ISR version. |
|---|
| 2950 | |
|---|
| 2951 | Description: |
|---|
| 2952 | Use this call when running in an interrupt context. |
|---|
| 2953 | |
|---|
| 2954 | Returns: |
|---|
| 2955 | BERR_SUCCESS - Read offset has been updated. |
|---|
| 2956 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2957 | |
|---|
| 2958 | See Also: |
|---|
| 2959 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, BXPT_AddFilterToGroup, |
|---|
| 2960 | BXPT_SetupPidChannelRecord, BXPT_SetupChannelForPsiMessages |
|---|
| 2961 | ***************************************************************************/ |
|---|
| 2962 | BERR_Code BXPT_UpdateReadOffset_isr( |
|---|
| 2963 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2964 | unsigned int MesgBuffNum, /* [in] Message buffer to check. This is same as PidChNum in case of 1-to-1 mapping*/ |
|---|
| 2965 | size_t BytesRead /* [in] Number of bytes read. */ |
|---|
| 2966 | ); |
|---|
| 2967 | |
|---|
| 2968 | /*************************************************************************** |
|---|
| 2969 | Summary: |
|---|
| 2970 | Pause or resume a PES recording session. |
|---|
| 2971 | |
|---|
| 2972 | Description: |
|---|
| 2973 | Pause or resume a PES recording that uses the message buffers. This call, |
|---|
| 2974 | unlike BXPT_StopPidChannelRecord(), does not disable the PID channel when the |
|---|
| 2975 | record is stopped. If other blocks in the transport core are using this PID |
|---|
| 2976 | channel, their data will not be interrupted by this call. |
|---|
| 2977 | |
|---|
| 2978 | When the PES record is resumed, the associated message buffer will be flushed, |
|---|
| 2979 | removing any old stale data. |
|---|
| 2980 | |
|---|
| 2981 | Returns: |
|---|
| 2982 | BERR_SUCCESS - Recording pause (or resume) successful. |
|---|
| 2983 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 2984 | |
|---|
| 2985 | See Also: |
|---|
| 2986 | BXPT_StartPidChannelRecord(), BXPT_StopPidChannelRecord() |
|---|
| 2987 | ***************************************************************************/ |
|---|
| 2988 | BERR_Code BXPT_PausePesRecord( |
|---|
| 2989 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 2990 | unsigned int MesgBuffNum, /* [in] Message buffer to check. This is same as PidChNum in case of 1-to-1 mapping*/ |
|---|
| 2991 | bool Pause /* [in] Enable or disable pause */ |
|---|
| 2992 | ); |
|---|
| 2993 | |
|---|
| 2994 | /*************************************************************************** |
|---|
| 2995 | Summary: |
|---|
| 2996 | Pause or resume a PSI capture session. |
|---|
| 2997 | |
|---|
| 2998 | Description: |
|---|
| 2999 | Pause or resume a PSI capture. This call, unlike BXPT_StopPidChannelRecord(), |
|---|
| 3000 | does not disable the PID channel when the capture is stopped. If other blocks |
|---|
| 3001 | in the transport core are using this PID channel, their data will not be |
|---|
| 3002 | interrupted. |
|---|
| 3003 | |
|---|
| 3004 | When the PSI capture is resumed, the associated message buffer will be flushed, |
|---|
| 3005 | removing any old stale data. |
|---|
| 3006 | |
|---|
| 3007 | Returns: |
|---|
| 3008 | BERR_SUCCESS - PSI capture pause (or resume) successful. |
|---|
| 3009 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3010 | |
|---|
| 3011 | See Also: |
|---|
| 3012 | BXPT_StartPidChannelRecord(), BXPT_StopPidChannelRecord() |
|---|
| 3013 | ***************************************************************************/ |
|---|
| 3014 | BERR_Code BXPT_PausePsiCapture( |
|---|
| 3015 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3016 | unsigned int MesgBuffNum, /* [in] Message buffer to check. This is same as PidChNum in case of 1-to-1 mapping*/ |
|---|
| 3017 | bool Pause /* [in] Enable or disable pause */ |
|---|
| 3018 | ); |
|---|
| 3019 | |
|---|
| 3020 | /*************************************************************************** |
|---|
| 3021 | Summary: |
|---|
| 3022 | Get the current message buffer depth. |
|---|
| 3023 | |
|---|
| 3024 | Description: |
|---|
| 3025 | Compute the total number of unread bytes in the given message buffer, |
|---|
| 3026 | including any data that wrapped around the end of the buffer. |
|---|
| 3027 | |
|---|
| 3028 | Returns: |
|---|
| 3029 | BERR_SUCCESS - Depth returned in *BufferDepth. |
|---|
| 3030 | BERR_INVALID_PARAMETER - Bad PidChannelNum |
|---|
| 3031 | |
|---|
| 3032 | See Also: |
|---|
| 3033 | BXPT_AllocPidChannel(), BXPT_FreePidChannel() |
|---|
| 3034 | ***************************************************************************/ |
|---|
| 3035 | BERR_Code BXPT_GetMesgBufferDepth( |
|---|
| 3036 | BXPT_Handle hXpt, /* [in] Handle for this transport instance */ |
|---|
| 3037 | unsigned int PidChannelNum, /* [in] Which PID channel's buffer to query */ |
|---|
| 3038 | size_t *BufferDepth /* [out] Unread byte count */ |
|---|
| 3039 | ); |
|---|
| 3040 | |
|---|
| 3041 | /*************************************************************************** |
|---|
| 3042 | Summary: |
|---|
| 3043 | Get the current message buffer error status. |
|---|
| 3044 | |
|---|
| 3045 | Description: |
|---|
| 3046 | Get the error status of all the message buffers. |
|---|
| 3047 | This API should be used with L2 error interrupt to identify the type of error |
|---|
| 3048 | and message bufffer which has triggered the error interrupt |
|---|
| 3049 | |
|---|
| 3050 | Returns: |
|---|
| 3051 | BERR_SUCCESS - |
|---|
| 3052 | BERR_INVALID_PARAMETER - Bad message buffer number |
|---|
| 3053 | See Also: |
|---|
| 3054 | ***************************************************************************/ |
|---|
| 3055 | BERR_Code BXPT_Mesg_GetErrorStatus( |
|---|
| 3056 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3057 | unsigned MesgBufferNum, /* [in] Which buffer to get the status of */ |
|---|
| 3058 | bool *ErrorStatus /* [out] Error status for the message buffer */ |
|---|
| 3059 | ); |
|---|
| 3060 | |
|---|
| 3061 | /*************************************************************************** |
|---|
| 3062 | Summary: |
|---|
| 3063 | Determine which PID channel is feeding data to a given message buffer. |
|---|
| 3064 | |
|---|
| 3065 | Description: |
|---|
| 3066 | Look up the which PID channel is mapped to the given message buffer. If such |
|---|
| 3067 | a channel is found, return it in *PidChannelNum. Otherwise, set *PidChannelNum |
|---|
| 3068 | to an invalid PID table index and BXPT_ERR_RESOURCE_NOT_FOUND is returned. |
|---|
| 3069 | |
|---|
| 3070 | Returns: |
|---|
| 3071 | BERR_SUCCESS - PidChannelNum |
|---|
| 3072 | BERR_INVALID_PARAMETER - Bad MesgBufferNum |
|---|
| 3073 | BXPT_ERR_RESOURCE_NOT_FOUND - MesgBuffer is not mapped to a PID channel |
|---|
| 3074 | |
|---|
| 3075 | See Also: |
|---|
| 3076 | ***************************************************************************/ |
|---|
| 3077 | BERR_Code BXPT_Mesg_GetPidChannelFromBufferNum( |
|---|
| 3078 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3079 | unsigned int MesgBufferNum, /* [in] Which Buffer Number. */ |
|---|
| 3080 | unsigned int *PidChannelNum /* [out] Which PID channel. */ |
|---|
| 3081 | ); |
|---|
| 3082 | |
|---|
| 3083 | #endif |
|---|
| 3084 | |
|---|
| 3085 | /*************************************************************************** |
|---|
| 3086 | Summary: |
|---|
| 3087 | Get a PID channel's configuration. |
|---|
| 3088 | |
|---|
| 3089 | Description: |
|---|
| 3090 | Retrieve the PID and parser band that a PID channel has been configured for. |
|---|
| 3091 | Also indicate if the parser band is a playback parser, as opposed to input |
|---|
| 3092 | band parser. |
|---|
| 3093 | |
|---|
| 3094 | Returns: |
|---|
| 3095 | BERR_SUCCESS |
|---|
| 3096 | BERR_INVALID_PARAMETER - Invalid PidChannelNum passed in. |
|---|
| 3097 | See Also: |
|---|
| 3098 | ***************************************************************************/ |
|---|
| 3099 | BERR_Code BXPT_GetPidChannelConfig( |
|---|
| 3100 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3101 | unsigned int PidChannelNum, /* [in] Which channel to get config for. */ |
|---|
| 3102 | unsigned int *Pid, /* [out] The PID its using. */ |
|---|
| 3103 | unsigned int *Band, /* [out] The parser band the channel is mapped to. */ |
|---|
| 3104 | bool *IsPlayback /* [out] true if band is a playback parser, false if input */ |
|---|
| 3105 | ); |
|---|
| 3106 | |
|---|
| 3107 | /*************************************************************************** |
|---|
| 3108 | Summary: |
|---|
| 3109 | Get a PID channel's Continuity Count checking configuration. |
|---|
| 3110 | |
|---|
| 3111 | Description: |
|---|
| 3112 | Continuity Count handling can be controlled on a per-PID channel basis. Get |
|---|
| 3113 | the current settings for the given PID channel. See the BXPT_PidChannel_CC_Config |
|---|
| 3114 | structure definition for further details. |
|---|
| 3115 | |
|---|
| 3116 | Returns: |
|---|
| 3117 | BERR_SUCCESS |
|---|
| 3118 | BERR_INVALID_PARAMETER - Invalid PidChannelNum passed in. |
|---|
| 3119 | |
|---|
| 3120 | See Also: |
|---|
| 3121 | BXPT_SetPidChannel_CC_Config |
|---|
| 3122 | ***************************************************************************/ |
|---|
| 3123 | BERR_Code BXPT_GetPidChannel_CC_Config( |
|---|
| 3124 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3125 | unsigned int PidChannelNum, /* [in] Which channel to get config for. */ |
|---|
| 3126 | BXPT_PidChannel_CC_Config *Cfg |
|---|
| 3127 | ); |
|---|
| 3128 | |
|---|
| 3129 | /*************************************************************************** |
|---|
| 3130 | Summary: |
|---|
| 3131 | Set a PID channel's Continuity Count checking configuration. |
|---|
| 3132 | |
|---|
| 3133 | Description: |
|---|
| 3134 | Continuity Count handling can be controlled on a per-PID channel basis. Give |
|---|
| 3135 | new settings for the given PID channel. See the BXPT_PidChannel_CC_Config |
|---|
| 3136 | structure definition for further details. |
|---|
| 3137 | |
|---|
| 3138 | Returns: |
|---|
| 3139 | BERR_SUCCESS |
|---|
| 3140 | BERR_INVALID_PARAMETER - Invalid PidChannelNum passed in. |
|---|
| 3141 | |
|---|
| 3142 | See Also: |
|---|
| 3143 | BXPT_GetPidChannel_CC_Config |
|---|
| 3144 | ***************************************************************************/ |
|---|
| 3145 | BERR_Code BXPT_SetPidChannel_CC_Config( |
|---|
| 3146 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3147 | unsigned int PidChannelNum, /* [in] Which channel to get config for. */ |
|---|
| 3148 | const BXPT_PidChannel_CC_Config *Cfg |
|---|
| 3149 | ); |
|---|
| 3150 | |
|---|
| 3151 | /*************************************************************************** |
|---|
| 3152 | Summary: |
|---|
| 3153 | Use only if you need PID to multiple buffer mapping capability. |
|---|
| 3154 | Retrieves the current PSI setting for the given pid channel. |
|---|
| 3155 | |
|---|
| 3156 | Description: |
|---|
| 3157 | Read the current settings for the given pid channel chip. Settings |
|---|
| 3158 | are returned in the structure that is passed in. See the structure for the |
|---|
| 3159 | complete list of supported settings. |
|---|
| 3160 | |
|---|
| 3161 | Returns: |
|---|
| 3162 | BERR_SUCCESS - Copied the parser config. |
|---|
| 3163 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3164 | |
|---|
| 3165 | See Also: |
|---|
| 3166 | BXPT_SetPidChannelPsiSettings |
|---|
| 3167 | ****************************************************************************/ |
|---|
| 3168 | BERR_Code BXPT_Mesg_GetPidChannelPsiSettings( |
|---|
| 3169 | BXPT_Handle hXpt, /* [In] Handle for this transport */ |
|---|
| 3170 | unsigned int PidChannelNum, /* [In] The pid channel to configure. */ |
|---|
| 3171 | unsigned int MesgBufferNum, /* [In] The pid channel to configure. */ |
|---|
| 3172 | bool *OverrideParserSettings, /* [Out] true if these settings are overriding the parser versions */ |
|---|
| 3173 | BXPT_PidPsiConfig *Config /* [Out] Message mode setting for pid channel. */ |
|---|
| 3174 | ); |
|---|
| 3175 | |
|---|
| 3176 | /*************************************************************************** |
|---|
| 3177 | Summary: |
|---|
| 3178 | Use only if you need PID to multiple buffer mapping capability. |
|---|
| 3179 | Override the PSI settings for the Pid channel or Reset the per pid channel PSI |
|---|
| 3180 | settings to the paser band settings |
|---|
| 3181 | |
|---|
| 3182 | Description: |
|---|
| 3183 | Writes the given PSI configuration to the pid channel or reset the PSI configuration |
|---|
| 3184 | to the paser band setting .Each parser band has its own PSI settings set by |
|---|
| 3185 | BXPT_SetParserConfig API. On the new chip architectures each pid channel can have its |
|---|
| 3186 | own PSI settings. This API lets the user change the PSI settings on per pid channel |
|---|
| 3187 | basis. User should un-override the setting when different PSI settings are no |
|---|
| 3188 | longer desired |
|---|
| 3189 | |
|---|
| 3190 | Returns: |
|---|
| 3191 | BERR_SUCCESS - Transfered the parser config to the chip. |
|---|
| 3192 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3193 | |
|---|
| 3194 | See Also: |
|---|
| 3195 | BXPT_GetParserConfig,BXPT_GetPidChannelPsiSettings |
|---|
| 3196 | ****************************************************************************/ |
|---|
| 3197 | BERR_Code BXPT_Mesg_SetPidChannelPsiSettings( |
|---|
| 3198 | BXPT_Handle hXpt, /* [In] Handle for this transport */ |
|---|
| 3199 | unsigned int PidChannelNum, /* [In] The pid channel to configure. */ |
|---|
| 3200 | unsigned int MesgBufferNum, /* [In] The Mesg Buffer NUmber to configure. */ |
|---|
| 3201 | bool OverrideParserSettings, /* [In] If set true the PSI settings for |
|---|
| 3202 | this pid channel will be changed to Config |
|---|
| 3203 | else restored to the paser band to which |
|---|
| 3204 | this pid channel is allocated */ |
|---|
| 3205 | const BXPT_PidPsiConfig *Config /* [In] Message mode setting for pid channel. */ |
|---|
| 3206 | ); |
|---|
| 3207 | |
|---|
| 3208 | |
|---|
| 3209 | |
|---|
| 3210 | /*************************************************************************** |
|---|
| 3211 | Summary: |
|---|
| 3212 | This function is Added as a substitiute for BXPT_SetPidChannelBuffer to support |
|---|
| 3213 | PID to multiple buffer mapping capabilities. User has to specify the Message Buffer Number along |
|---|
| 3214 | with the PidChannelNumber. |
|---|
| 3215 | Sets up a region of memory to be used as a PID channel buffer. |
|---|
| 3216 | |
|---|
| 3217 | Description: |
|---|
| 3218 | Setup a region of memory to be used as a PID channel's message buffer. The |
|---|
| 3219 | caller specifies the size (in bytes) of the memory region. The caller may |
|---|
| 3220 | allocate the memory to be used; in that case, a pointer to the user-allocated |
|---|
| 3221 | region would be passed in through the CpuAddr param. If CpuAddr is NULL, |
|---|
| 3222 | this function will do the allocation internally, using BufferSize as the |
|---|
| 3223 | size to allocate. User-allocated buffers must be 1024-byte aligned. |
|---|
| 3224 | |
|---|
| 3225 | Note that the if the caller allocates memory, the caller is also responsible |
|---|
| 3226 | for freeing it. Memory allocated internally by this call will be freed when the |
|---|
| 3227 | transport handle is closed, or when it is called again with a different |
|---|
| 3228 | BufferSize and a NULL CpuAddr. |
|---|
| 3229 | |
|---|
| 3230 | Also, if the caller allocates memory, the size of the area must match one of |
|---|
| 3231 | the sizes defined by the BXPT_MessageBufferSize enumeration. These are the |
|---|
| 3232 | only buffer sizes supported by the underlying hardware. User allocated memory |
|---|
| 3233 | must be obtained through the BMEM memory manager, preferably by using |
|---|
| 3234 | BMEM_AllocAligned(). |
|---|
| 3235 | |
|---|
| 3236 | Returns: |
|---|
| 3237 | BERR_SUCCESS - Message buffer configured. |
|---|
| 3238 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3239 | ***************************************************************************/ |
|---|
| 3240 | BERR_Code BXPT_Mesg_SetPidChannelBuffer( |
|---|
| 3241 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3242 | unsigned int PidChannelNum, /* [in] Which PID channel buffer we want. */ |
|---|
| 3243 | unsigned int MesgBufferNum, /* [in] Which Buffer number we want . */ |
|---|
| 3244 | void *CpuAddr, /* [in] Caller allocated memory, or NULL. */ |
|---|
| 3245 | BXPT_MessageBufferSize BufferSize /* [in] Size, in bytes, of the buffer. */ |
|---|
| 3246 | ); |
|---|
| 3247 | |
|---|
| 3248 | |
|---|
| 3249 | /*************************************************************************** |
|---|
| 3250 | Summary: |
|---|
| 3251 | Use this API only when you need PID to multiple buffer mapping capabilities. |
|---|
| 3252 | Pass Message Buffer Number along with the PidChannelNumber. |
|---|
| 3253 | Add a filter to a group of filters. |
|---|
| 3254 | |
|---|
| 3255 | Description: |
|---|
| 3256 | Add a given filter to the group of filters maintained in the Settings |
|---|
| 3257 | structure. All filters in the group will be used to filter messages carried |
|---|
| 3258 | on the PID channel the group is associated with.Pid channel must be allocated |
|---|
| 3259 | and configured before calling this function. |
|---|
| 3260 | |
|---|
| 3261 | Returns: |
|---|
| 3262 | BERR_SUCCESS - Filter successfully added to the group. |
|---|
| 3263 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3264 | |
|---|
| 3265 | See Also: |
|---|
| 3266 | BXPT_AllocPSIFilter, BXPT_GetFilter, BXPT_SetFilter, |
|---|
| 3267 | BXPT_RemoveFilterFromGroup |
|---|
| 3268 | ***************************************************************************/ |
|---|
| 3269 | BERR_Code BXPT_Mesg_AddFilterToGroup( |
|---|
| 3270 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3271 | unsigned int PidChannelNum, /* [in] Pid channel number */ |
|---|
| 3272 | unsigned int MesgBufferNum, /* [in] Message Buffer number */ |
|---|
| 3273 | unsigned int FilterNum, /* [in] Which filter to add. */ |
|---|
| 3274 | BXPT_PsiMessageSettings *Settings /* [in,out] Filter group to add to. */ |
|---|
| 3275 | ); |
|---|
| 3276 | |
|---|
| 3277 | |
|---|
| 3278 | /*************************************************************************** |
|---|
| 3279 | Summary: |
|---|
| 3280 | Use only if you need PID to multiple buffer mapping capability. |
|---|
| 3281 | Configure for recording a PID channel. |
|---|
| 3282 | |
|---|
| 3283 | Description: |
|---|
| 3284 | Configure for recording a single PID channel, using the message buffers. |
|---|
| 3285 | The PID, parser band, and type of recording to do are specified in the |
|---|
| 3286 | Settings structure. This function will enable the PID channel, but will |
|---|
| 3287 | not install an interrupt handler for the message interrupt. Installing |
|---|
| 3288 | the interrupt should be done before calling this function. |
|---|
| 3289 | |
|---|
| 3290 | The caller must allocate a PID channel before using the function. It should |
|---|
| 3291 | NOT be called if the PID channel is already enabled. |
|---|
| 3292 | |
|---|
| 3293 | BXPT_SetPidChannelBuffer() must have been called at some point prior to |
|---|
| 3294 | calling this function, to insure that the message buffer for this channel |
|---|
| 3295 | has been initialized. |
|---|
| 3296 | |
|---|
| 3297 | Returns: |
|---|
| 3298 | BERR_SUCCESS - PID channel record configured. |
|---|
| 3299 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3300 | BXPT_ERR_MESG_BUFFER_NOT_CONFIGURED - Message buffer not initialized. |
|---|
| 3301 | |
|---|
| 3302 | ***************************************************************************/ |
|---|
| 3303 | BERR_Code BXPT_Mesg_StartPidChannelRecord( |
|---|
| 3304 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3305 | unsigned int PidChannelNum, /* [in] Which PID channel. */ |
|---|
| 3306 | unsigned int MesgBufferNum, /* [in] Which Buffer Number. */ |
|---|
| 3307 | const BXPT_PidChannelRecordSettings *Settings /* [in] Record settings. */ |
|---|
| 3308 | ); |
|---|
| 3309 | |
|---|
| 3310 | |
|---|
| 3311 | /*************************************************************************** |
|---|
| 3312 | Summary: |
|---|
| 3313 | Use Only when you need PID to multiple buffer mapping capabilty |
|---|
| 3314 | Disable recording of a PID channel. |
|---|
| 3315 | |
|---|
| 3316 | Description: |
|---|
| 3317 | Stops the recording of packet or PES data on the given PID channel. The PID |
|---|
| 3318 | channel is disabled. The interrupt handler, if there was one installed, will |
|---|
| 3319 | not be disabled; thus, any data still in the hardware may trigger an interrupt |
|---|
| 3320 | after this function returns. |
|---|
| 3321 | |
|---|
| 3322 | NOTE: This function may sleep for up to 200 microseconds, in order to flush |
|---|
| 3323 | any remaining data from the hardware's internal buffers. |
|---|
| 3324 | |
|---|
| 3325 | Returns: |
|---|
| 3326 | BERR_SUCCESS - PID channel record stopped. |
|---|
| 3327 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3328 | |
|---|
| 3329 | ***************************************************************************/ |
|---|
| 3330 | BERR_Code BXPT_Mesg_StopPidChannelRecord( |
|---|
| 3331 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3332 | unsigned int PidChannelNum, /* [in] Which PID channel. */ |
|---|
| 3333 | unsigned int MesgBufferNum /* [in] Which Buffer Number. */ |
|---|
| 3334 | ); |
|---|
| 3335 | |
|---|
| 3336 | |
|---|
| 3337 | /*************************************************************************** |
|---|
| 3338 | Summary: |
|---|
| 3339 | Use only when you need PID to multiple buffer mapping capability. |
|---|
| 3340 | Configure for capturing PSI messages. |
|---|
| 3341 | |
|---|
| 3342 | Description: |
|---|
| 3343 | Associate one or more PSI message filters with a given PID and parser band. |
|---|
| 3344 | This function will enable the PID channel, but will not install an |
|---|
| 3345 | interrupt handler for the message interrupt. The interrupt handler should be |
|---|
| 3346 | installed before calling this function. |
|---|
| 3347 | |
|---|
| 3348 | The caller must allocate a PID channel before using the function. It should |
|---|
| 3349 | NOT be called if the PID channel is already enabled. |
|---|
| 3350 | |
|---|
| 3351 | BXPT_SetPidChannelBuffer() must have been called at some point prior to |
|---|
| 3352 | calling this function, to insure that the message buffer for this channel |
|---|
| 3353 | has been initialized. |
|---|
| 3354 | |
|---|
| 3355 | Returns: |
|---|
| 3356 | BERR_SUCCESS - PSI filtering is setup. |
|---|
| 3357 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3358 | BXPT_ERR_MESG_BUFFER_NOT_CONFIGURED - Message buffer not initialized. |
|---|
| 3359 | |
|---|
| 3360 | ***************************************************************************/ |
|---|
| 3361 | BERR_Code BXPT_Mesg_StartPsiMessageCapture( |
|---|
| 3362 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3363 | unsigned int PidChannelNum, /* [in] Which PID channel. */ |
|---|
| 3364 | unsigned int MesgBufferNum, /* [in] Which Message Buffer. */ |
|---|
| 3365 | const BXPT_PsiMessageSettings *Settings /* [in] PID, band, and filters to use. */ |
|---|
| 3366 | ); |
|---|
| 3367 | |
|---|
| 3368 | |
|---|
| 3369 | /*************************************************************************** |
|---|
| 3370 | Summary: |
|---|
| 3371 | Use only when you need PID to multiple buffer mapping capability. |
|---|
| 3372 | Stop capturing PSI messages. |
|---|
| 3373 | |
|---|
| 3374 | Description: |
|---|
| 3375 | Disable the PID channel being used to capture PSI messages. Flush any data |
|---|
| 3376 | still in the chip. If the interrupts for the message buffer are still |
|---|
| 3377 | enabled, flushing the data may trigger another interrupt. |
|---|
| 3378 | |
|---|
| 3379 | NOTE: This function may sleep for up to 200 microseconds, in order to flush |
|---|
| 3380 | any remaining data from the hardware's internal buffers. |
|---|
| 3381 | |
|---|
| 3382 | Returns: |
|---|
| 3383 | BERR_SUCCESS - PSI filtering is stopped. |
|---|
| 3384 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3385 | |
|---|
| 3386 | ***************************************************************************/ |
|---|
| 3387 | BERR_Code BXPT_Mesg_StopPsiMessageCapture( |
|---|
| 3388 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3389 | unsigned int PidChannelNum, /* [in] Which PID channel. */ |
|---|
| 3390 | unsigned int MesgBufferNum /* [in] Which PID channel. */ |
|---|
| 3391 | ); |
|---|
| 3392 | |
|---|
| 3393 | |
|---|
| 3394 | |
|---|
| 3395 | /*************************************************************************** |
|---|
| 3396 | Summary: |
|---|
| 3397 | API in bxpt_mesg.c to disable the pid channel to message buffer association |
|---|
| 3398 | that is created after calling the ConfigPid2BufferMap |
|---|
| 3399 | |
|---|
| 3400 | Description: |
|---|
| 3401 | API in bxpt_mesg.c to disable the pid channel to message buffer association |
|---|
| 3402 | that is created after calling the ConfigPid2BufferMap |
|---|
| 3403 | |
|---|
| 3404 | Returns: |
|---|
| 3405 | BERR_SUCCESS - PSI filtering is stopped. |
|---|
| 3406 | BERR_INVALID_PARAMETER - Bad input parameter |
|---|
| 3407 | |
|---|
| 3408 | ***************************************************************************/ |
|---|
| 3409 | BERR_Code BXPT_Mesg_ClearPidChannelBuffer( |
|---|
| 3410 | BXPT_Handle hXpt, /* [in] Handle for this transport */ |
|---|
| 3411 | unsigned int PidChannelNum, /* [in] Which PID channel buffer we want. */ |
|---|
| 3412 | unsigned int MesgBufferNum /* [in] Which Buffer number we want . */ |
|---|
| 3413 | ); |
|---|
| 3414 | |
|---|
| 3415 | #if BXPT_HAS_PIPELINE_ERROR_REPORTING |
|---|
| 3416 | /*************************************************************************** |
|---|
| 3417 | Summary: |
|---|
| 3418 | Check for RS and XC buffer overflows. If any are found, print a user-friendly |
|---|
| 3419 | message through BDBG_ERR(). |
|---|
| 3420 | |
|---|
| 3421 | Returns: |
|---|
| 3422 | BERR_SUCCESS - No error detected. |
|---|
| 3423 | BERR_NOT_SUPPORTED - Not supported on the current chip. |
|---|
| 3424 | BXPT_ERR_DATA_PIPELINE - Error was detected |
|---|
| 3425 | ***************************************************************************/ |
|---|
| 3426 | BERR_Code BXPT_CheckPipelineErrors( |
|---|
| 3427 | BXPT_Handle xpt |
|---|
| 3428 | ); |
|---|
| 3429 | #endif |
|---|
| 3430 | |
|---|
| 3431 | /* |
|---|
| 3432 | ** These functions are called internally. |
|---|
| 3433 | ** Users should NOT uses these functions directly. |
|---|
| 3434 | */ |
|---|
| 3435 | |
|---|
| 3436 | /* Indentify PB parser bands by special bitfields. Also clear those bitfields */ |
|---|
| 3437 | #define BXPT_P_IS_PB( x ) (( x & 0x8000 ) != 0) |
|---|
| 3438 | #define BXPT_P_CLEAR_PB_FLAG( x ) ( x &= 0x7FFF ) |
|---|
| 3439 | |
|---|
| 3440 | BERR_Code BXPT_P_ApplyParserPsiSettings( |
|---|
| 3441 | BXPT_Handle hXpt, |
|---|
| 3442 | unsigned int ParserNum, |
|---|
| 3443 | bool IsPbParser |
|---|
| 3444 | ); |
|---|
| 3445 | |
|---|
| 3446 | BERR_Code BXPT_P_SetPidChannelDestination( |
|---|
| 3447 | BXPT_Handle hXpt, |
|---|
| 3448 | unsigned int PidChannelNum, |
|---|
| 3449 | unsigned Destination, |
|---|
| 3450 | bool EnableIt |
|---|
| 3451 | ); |
|---|
| 3452 | |
|---|
| 3453 | BERR_Code BXPT_P_ClearAllPidChannelDestinations( |
|---|
| 3454 | BXPT_Handle hXpt, |
|---|
| 3455 | unsigned int PidChannelNum |
|---|
| 3456 | ); |
|---|
| 3457 | |
|---|
| 3458 | BERR_Code BXPT_P_DisableFilter( |
|---|
| 3459 | BXPT_Handle hXpt, |
|---|
| 3460 | unsigned int FilterNum, |
|---|
| 3461 | unsigned int PidChannelNum |
|---|
| 3462 | ); |
|---|
| 3463 | |
|---|
| 3464 | BERR_Code BXPT_P_PauseFilters( |
|---|
| 3465 | BXPT_Handle hXpt, |
|---|
| 3466 | unsigned int PidChannelNum, |
|---|
| 3467 | unsigned FilteringOp, |
|---|
| 3468 | bool Pause |
|---|
| 3469 | ); |
|---|
| 3470 | |
|---|
| 3471 | BERR_Code BXPT_P_EnablePidChannel( |
|---|
| 3472 | BXPT_Handle hXpt, |
|---|
| 3473 | unsigned int PidChannelNum |
|---|
| 3474 | ); |
|---|
| 3475 | |
|---|
| 3476 | bool BXPT_P_CanPowerDown( |
|---|
| 3477 | BXPT_Handle hXpt |
|---|
| 3478 | ); |
|---|
| 3479 | |
|---|
| 3480 | #ifdef __cplusplus |
|---|
| 3481 | } |
|---|
| 3482 | #endif |
|---|
| 3483 | |
|---|
| 3484 | #endif /* #ifndef BXPT_H__ */ |
|---|
| 3485 | |
|---|
| 3486 | /* end of file */ |
|---|
| 3487 | |
|---|
| 3488 | |
|---|