Logo Search packages:      
Sourcecode: linux-fsl-imx51 version File versions  Download package

sf_util.h File Reference


Detailed Description

Header for Sahara Descriptor-chain building Functions.

Definition in file sf_util.h.

#include <fsl_platform.h>
#include <sahara.h>

Go to the source code of this file.

Defines

#define DBG_DESC(hdr, len1, ptr1, len2, ptr2)
#define DESC_D_D(hdr, len1, ptr1, len2, ptr2)
#define DESC_DBG_OFF   system("echo 7 > /proc/sys/kernel/printk")
#define DESC_DBG_ON   system("echo 8 > /proc/sys/kernel/printk")
#define DESC_IN_IN(hdr, len1, ptr1, len2, ptr2)
#define DESC_IN_KEY(hdr, len1, ptr1, key2)
#define DESC_IN_KEYOUT(hdr, len1, ptr1, key2)
#define DESC_IN_OUT(hdr, len1, ptr1, len2, ptr2)
#define DESC_KEY_OUT(hdr, key1, len2, ptr2)
#define DESC_OUT_IN(hdr, len1, ptr1, len2, ptr2)
#define DESC_OUT_OUT(hdr, len1, ptr1, len2, ptr2)
#define DESC_TEMP_ALLOC(size)
#define DESC_TEMP_FREE(ptr)
#define DESC_TEMP_SECURE_ALLOC(size)
#define DESC_TEMP_SECURE_FREE(ptr, size)
#define SAH_HDR_ARC4_READ_SBOX   0x90860000
#define SAH_HDR_ARC4_SET_MODE_KEY   0x90830000
#define SAH_HDR_ARC4_SET_MODE_SBOX   0x90890000
#define SAH_HDR_LLO   0x01000000
#define SAH_HDR_MDHA_HASH   0xA0850000
#define SAH_HDR_MDHA_ICV_CHECK   0xA08A0000
#define SAH_HDR_MDHA_SET_MODE_HASH   0x208D0000
#define SAH_HDR_MDHA_SET_MODE_MD_KEY   0x20880000
#define SAH_HDR_MDHA_STORE_DIGEST   0x20820000
#define SAH_HDR_PKHA_EX_ST_B1   0xC08C0000
#define SAH_HDR_PKHA_LD_A0_A1   0x40840000
#define SAH_HDR_PKHA_LD_A2_A3   0xC0850000
#define SAH_HDR_PKHA_LD_A3_B0   0x40810000
#define SAH_HDR_PKHA_LD_A_B   0xC0830000
#define SAH_HDR_PKHA_LD_A_EX_ST_B   0x408D0000
#define SAH_HDR_PKHA_LD_B0_B1   0xC0860000
#define SAH_HDR_PKHA_LD_B2_B3   0x40870000
#define SAH_HDR_PKHA_LD_N_E   0xC0800000
#define SAH_HDR_PKHA_LD_N_EX_ST_B   0x408E0000
#define SAH_HDR_PKHA_ST_A0_A1   0x40880000
#define SAH_HDR_PKHA_ST_A2_A3   0xC0890000
#define SAH_HDR_PKHA_ST_A_B   0x40820000
#define SAH_HDR_PKHA_ST_B0_B1   0xC08A0000
#define SAH_HDR_PKHA_ST_B1_B2   0xC08F0000
#define SAH_HDR_PKHA_ST_B2_B3   0x408B0000
#define SAH_HDR_RNG_GENERATE   0x308C0000
#define SAH_HDR_SKHA_CBC_ICV   0x10840000
#define SAH_HDR_SKHA_ENC_DEC   0x90850000
#define SAH_HDR_SKHA_READ_CONTEXT_IV   0x10820000
#define SAH_HDR_SKHA_SET_MODE_ENC_DEC   0x108D0000
#define SAH_HDR_SKHA_SET_MODE_IV_KEY   0x10880000
#define sah_insert_mdha_algorithm_md5   0x80000001
#define sah_insert_mdha_algorithm_sha1   0x00000000
#define sah_insert_mdha_algorithm_sha224   0x00000003
#define sah_insert_mdha_algorithm_sha256   0x80000002
#define sah_insert_mdha_hmac   0x80000008
#define sah_insert_mdha_icv_check   0x80001000
#define sah_insert_mdha_init   0x80000020
#define sah_insert_mdha_ipad   0x80000040
#define sah_insert_mdha_mac_full   0x80000200
#define sah_insert_mdha_opad   0x80000080
#define sah_insert_mdha_pdata   0x80000004
#define sah_insert_mdha_ssl   0x80000400
#define sah_insert_pkha_rtn_clr_eram   0x80000002
#define sah_insert_pkha_rtn_clr_mem   0x80000001
#define sah_insert_pkha_rtn_ec_f2m_add   0x0000000C
#define sah_insert_pkha_rtn_ec_f2m_aff_ptmul   0x80000007
#define sah_insert_pkha_rtn_ec_f2m_double   0x8000000D
#define sah_insert_pkha_rtn_ec_f2m_proj_ptmul   0x00000009
#define sah_insert_pkha_rtn_ec_f2m_ptmul   0x80000015
#define sah_insert_pkha_rtn_ec_fp_add   0x0000000A
#define sah_insert_pkha_rtn_ec_fp_aff_ptmul   0x00000006
#define sah_insert_pkha_rtn_ec_fp_double   0x8000000B
#define sah_insert_pkha_rtn_ec_fp_proj_ptmul   0x80000008
#define sah_insert_pkha_rtn_ec_fp_ptmul   0x00000014
#define sah_insert_pkha_rtn_f2m_add   0x80000025
#define sah_insert_pkha_rtn_f2m_add_aff   0x8000001A
#define sah_insert_pkha_rtn_f2m_amodn   0x8000002A
#define sah_insert_pkha_rtn_f2m_dbl_aff   0x00000018
#define sah_insert_pkha_rtn_f2m_emodn   0x80000013
#define sah_insert_pkha_rtn_f2m_exp   0x8000001C
#define sah_insert_pkha_rtn_f2m_gcd   0x80000016
#define sah_insert_pkha_rtn_f2m_inv   0x0000000F
#define sah_insert_pkha_rtn_f2m_mult1_mont   0x80000026
#define sah_insert_pkha_rtn_f2m_mult2_deconv   0x00000027
#define sah_insert_pkha_rtn_f2m_multn   0x8000001F
#define sah_insert_pkha_rtn_f2m_r2modn   0x8000000E
#define sah_insert_pkha_rtn_fp_add_aff   0x0000001B
#define sah_insert_pkha_rtn_fp_dbl_aff   0x80000019
#define sah_insert_pkha_rtn_miller_rabin   0x00000028
#define sah_insert_pkha_rtn_mod_add   0x00000021
#define sah_insert_pkha_rtn_mod_amodn   0x00000029
#define sah_insert_pkha_rtn_mod_emodn   0x00000012
#define sah_insert_pkha_rtn_mod_exp   0x00000003
#define sah_insert_pkha_rtn_mod_exp_teq   0x0000001D
#define sah_insert_pkha_rtn_mod_gcd   0x00000017
#define sah_insert_pkha_rtn_mod_inv   0x80000010
#define sah_insert_pkha_rtn_mod_mult1_mont   0x80000023
#define sah_insert_pkha_rtn_mod_mult2_deconv   0x00000024
#define sah_insert_pkha_rtn_mod_multn   0x80000020
#define sah_insert_pkha_rtn_mod_r2modn   0x80000004
#define sah_insert_pkha_rtn_mod_rrmodp   0x00000005
#define sah_insert_pkha_rtn_mod_sub   0x00000022
#define sah_insert_pkha_rtn_rsa_sstep   0x00000011
#define sah_insert_pkha_rtn_rsa_sstep_teq   0x0000001E
#define sah_insert_pkha_soft_err_false   0x80000200
#define sah_insert_pkha_soft_err_true   0x80000100
#define sah_insert_rng_gen_seed   0x80000001
#define sah_insert_skha_algorithm_aes   0x00000000
#define sah_insert_skha_algorithm_arc4   0x00000003
#define sah_insert_skha_algorithm_des   0x80000001
#define sah_insert_skha_algorithm_tdes   0x80000002
#define sah_insert_skha_aux0   0x80000020
#define sah_insert_skha_ctr_last_block   0x80000020
#define sah_insert_skha_decrypt   0x00000000
#define sah_insert_skha_encrypt   0x80000004
#define sah_insert_skha_mode_cbc   0x80000008
#define sah_insert_skha_mode_ccm   0x80000010
#define sah_insert_skha_mode_ctr   0x00000018
#define sah_insert_skha_mode_ecb   0x00000000
#define sah_insert_skha_modulus_128   0x00001e00
#define sah_insert_skha_no_key_parity   0x80000100
#define sah_insert_skha_no_permute   0x80000020
#define sah_insert_skha_suppress_cbc   0x80000020
#define SAH_SF_DCLS
#define SAH_SF_DESC_CLEAN()
#define SAH_SF_EXECUTE()
#define SAH_SF_USER_CHECK()

Functions

fsl_shw_return_t sah_add_in_key_desc (uint32_t header, const uint8_t *in1, uint32_t in1_length, fsl_shw_sko_t *key_info, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_add_in_keyout_desc (uint32_t header, const uint8_t *in, uint32_t in_length, fsl_shw_sko_t *key_info, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_add_in_out_desc (uint32_t header, const uint8_t *in, uint32_t in_length, uint8_t *out, uint32_t out_length, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_add_key_key_desc (uint32_t header, fsl_shw_sko_t *key_info1, fsl_shw_sko_t *key_info2, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_add_key_out_desc (uint32_t header, const fsl_shw_sko_t *key_info, uint8_t *out, uint32_t out_length, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_add_out_in_desc (uint32_t header, uint8_t *out, uint32_t out_length, const uint8_t *in, uint32_t in_length, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_add_two_d_desc (uint32_t header, const uint8_t *in1, uint32_t in1_length, const uint8_t *in2, uint32_t in2_length, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_add_two_in_desc (uint32_t header, const uint8_t *in1, uint32_t in1_length, const uint8_t *in2, uint32_t in2_length, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_add_two_out_desc (uint32_t header, uint8_t *out1, uint32_t out1_length, uint8_t *out2, uint32_t out2_length, const sah_Mem_Util *mu, sah_Head_Desc **desc_chain)
fsl_shw_return_t sah_validate_uco (fsl_shw_uco_t *uco)
 Verify the user context object.

Variables

const uint32_t sah_insert_mdha_algorithm []
const uint32_t sah_insert_skha_algorithm []
const uint32_t sah_insert_skha_mode []
const uint32_t sah_insert_skha_modulus []


Generated by  Doxygen 1.6.0   Back to index