40 #ifndef __DRIVERLIB_DES_H__
41 #define __DRIVERLIB_DES_H__
60 #define DES_CFG_DIR_DECRYPT 0x00000000
61 #define DES_CFG_DIR_ENCRYPT 0x00000004
69 #define DES_CFG_MODE_ECB 0x00000000
70 #define DES_CFG_MODE_CBC 0x00000010
71 #define DES_CFG_MODE_CFB 0x00000020
80 #define DES_CFG_SINGLE 0x00000000
81 #define DES_CFG_TRIPLE 0x00000008
89 #define DES_INT_CONTEXT_IN 0x00000001
90 #define DES_INT_DATA_IN 0x00000002
91 #define DES_INT_DATA_OUT 0x00000004
92 #define DES_INT_DMA_CONTEXT_IN 0x00010000
93 #define DES_INT_DMA_DATA_IN 0x00020000
94 #define DES_INT_DMA_DATA_OUT 0x00040000
102 #define DES_DMA_CONTEXT_IN 0x00000080
103 #define DES_DMA_DATA_OUT 0x00000040
104 #define DES_DMA_DATA_IN 0x00000020
111 extern void DESConfigSet(uint32_t ui32Base, uint32_t ui32Config);
112 extern void DESDataRead(uint32_t ui32Base, uint32_t *pui32Dest);
115 uint32_t *pui32Dest, uint32_t ui32Length);
116 extern void DESDataWrite(uint32_t ui32Base, uint32_t *pui32Src);
118 extern void DESDMADisable(uint32_t ui32Base, uint32_t ui32Flags);
119 extern void DESDMAEnable(uint32_t ui32Base, uint32_t ui32Flags);
120 extern void DESIntClear(uint32_t ui32Base, uint32_t ui32IntFlags);
121 extern void DESIntDisable(uint32_t ui32Base, uint32_t ui32IntFlags);
122 extern void DESIntEnable(uint32_t ui32Base, uint32_t ui32IntFlags);
123 extern void DESIntRegister(uint32_t ui32Base,
void (*pfnHandler)(
void));
124 extern uint32_t
DESIntStatus(uint32_t ui32Base,
bool bMasked);
126 extern bool DESIVSet(uint32_t ui32Base, uint32_t *pui32IVdata);
127 extern void DESKeySet(uint32_t ui32Base, uint32_t *pui32Key);
128 extern void DESLengthSet(uint32_t ui32Base, uint32_t ui32Length);
129 extern void DESReset(uint32_t ui32Base);
140 #endif // __DRIVERLIB_DES_H__
void DESConfigSet(uint32_t ui32Base, uint32_t ui32Config)
uint32_t DESIntStatus(uint32_t ui32Base, bool bMasked)
bool DESDataReadNonBlocking(uint32_t ui32Base, uint32_t *pui32Dest)
void DESLengthSet(uint32_t ui32Base, uint32_t ui32Length)
void DESDMADisable(uint32_t ui32Base, uint32_t ui32Flags)
bool DESDataProcess(uint32_t ui32Base, uint32_t *pui32Src, uint32_t *pui32Dest, uint32_t ui32Length)
void DESIntRegister(uint32_t ui32Base, void(*pfnHandler)(void))
void DESKeySet(uint32_t ui32Base, uint32_t *pui32Key)
bool DESIVSet(uint32_t ui32Base, uint32_t *pui32IVdata)
void DESIntEnable(uint32_t ui32Base, uint32_t ui32IntFlags)
void DESReset(uint32_t ui32Base)
void DESDataWrite(uint32_t ui32Base, uint32_t *pui32Src)
void DESDMAEnable(uint32_t ui32Base, uint32_t ui32Flags)
void DESIntUnregister(uint32_t ui32Base)
void DESIntClear(uint32_t ui32Base, uint32_t ui32IntFlags)
void DESDataRead(uint32_t ui32Base, uint32_t *pui32Dest)
void DESIntDisable(uint32_t ui32Base, uint32_t ui32IntFlags)
bool DESDataWriteNonBlocking(uint32_t ui32Base, uint32_t *pui32Src)