Lines Matching defs:sc_buf
478 u8 enc, u8 *sc_buf)
483 sc_buf[0] = SA_CRYPTO_PROCESSING;
491 memcpy(&sc_buf[1], mci, MODE_CONTROL_BYTES);
495 if (sa_aes_inv_key(&sc_buf[SC_ENC_KEY_OFFSET], key, key_sz))
499 memcpy(&sc_buf[SC_ENC_KEY_OFFSET], key, key_sz);
507 u8 *sc_buf)
512 sc_buf[0] = SA_HASH_PROCESSING;
514 sc_buf[1] = SA_UPLOAD_HASH_TO_TLR;
515 sc_buf[1] |= ad->auth_ctrl;
522 memcpy(&sc_buf[32], ipad, ad->hash_size);
524 memcpy(&sc_buf[64], opad, ad->hash_size);
527 sc_buf[1] |= SA_BASIC_HASH;
700 u8 *sc_buf = ctx->sc;
704 memzero_explicit(sc_buf, SA_CTX_MAX_SZ);
714 sc_buf[1] = SA_SCCTL_FE_AUTH_ENC;
722 sc_buf[1] = SA_SCCTL_FE_ENC;
727 sc_buf[SA_CTX_SCCTL_OWNER_OFFSET] = 0;
728 memcpy(&sc_buf[2], &sc_id, 2);
729 sc_buf[4] = 0x0;
730 sc_buf[5] = PRIV_ID;
731 sc_buf[6] = PRIV;
732 sc_buf[7] = 0x0;
737 &sc_buf[enc_sc_offset]))
744 &sc_buf[auth_sc_offset]);
747 sc_buf[SA_CTX_SCCTL_OWNER_OFFSET] = 0x80;
750 sa_swiz_128(sc_buf, SA_CTX_MAX_SZ);
755 sa_dump_sc(sc_buf, ctx->sc_phys);