dman3.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00054 #ifndef ti_sdo_fc_dman3_DMAN3_
00055 #define ti_sdo_fc_dman3_DMAN3_
00056
00059
00060
00061 #ifdef __cplusplus
00062 extern "C" {
00063 #endif
00064
00065 #include <ti/xdais/ialg.h>
00066 #include <ti/xdais/idma3.h>
00067
00068 #define DMAN3_GTNAME "ti.sdo.fc.dman3"
00070 #define DMAN3_MAXGROUPS 20
00079 #define DMAN3_SOK 0
00080 #define DMAN3_EOUTOFMEMORY -1
00083 #define DMAN3_EFAIL -2
00084 #define DMAN3_EFREE -3
00086 #define DMAN3_EOUTOFTCCS -4
00089 #define DMAN3_EOUTOFPARAMS -5
00092 #define DMAN3_ETCCCONFIG -6
00098 #define DMAN3_EPARAMCONFIG -7
00105
00106
00115 typedef Bool (*DMAN3_ScratchAllocFxn)(IALG_Handle alg, Int mutexId,
00116 IALG_MemRec *memTab, Int numRecs);
00117
00123 typedef Void (*DMAN3_ScratchFreeFxn)(Int mutexId, Void *addr, Uns size);
00124
00125
00136 typedef struct DMAN3_Params {
00143 Uns *qdmaPaRamBase;
00144
00151 Uns maxPaRamEntries;
00152
00162 Uns paRamBaseIndex;
00163
00171 Uns numPaRamEntries;
00172
00179 Uns maxQdmaChannels;
00180
00187 Uns numQdmaChannels;
00188
00196 Uns *qdmaChannels;
00197
00211 Uns tccAllocationMaskH;
00212
00226 Uns tccAllocationMaskL;
00227
00238 Int heapInternal;
00239
00251 Int heapExternal;
00252
00261 unsigned char numTccGroup[DMAN3_MAXGROUPS];
00271 unsigned short numPaRamGroup[DMAN3_MAXGROUPS];
00282 Bool idma3Internal;
00283
00296 DMAN3_ScratchAllocFxn scratchAllocFxn;
00297
00309 DMAN3_ScratchFreeFxn scratchFreeFxn;
00310
00317 Uns nullPaRamIndex;
00318
00323 Uns maxTCs;
00324
00332 Uns *qdmaQueueMap;
00333
00338 Uns *queueTCMap;
00339
00344 Uns *queuePri;
00345
00373 Bool allowUnshared;
00374 } DMAN3_Params;
00375
00376
00380 extern DMAN3_Params DMAN3_PARAMS;
00381
00382
00426 extern Int DMAN3_grantDmaChannels(Int groupId, IALG_Handle algHandle[],
00427 IDMA3_Fxns *dmaFxns[], Int numAlgs);
00428
00432 extern Void DMAN3_exit(Void);
00433
00475 extern Int DMAN3_createChannels(Int groupId, IDMA3_ChannelRec dmaTab[],
00476 Int numChans);
00477
00478
00486 extern Void DMAN3_init(Void);
00487
00488
00510 extern Int DMAN3_releaseDmaChannels(IALG_Handle algHandle[],
00511 IDMA3_Fxns *dmaFxns[], Int numAlgs);
00512
00513
00529 extern Int DMAN3_freeChannels(IDMA3_Handle channelTab[], Int numChans);
00530
00531
00532 #ifdef __cplusplus
00533 }
00534 #endif
00535
00536
00539 #endif
00540
00541
00542
00543