Lines Matching refs:alen
1262 unsigned long long alen; in s390x_aes_gcm_aad() local
1268 alen = ctx->kma.param.taadl + len; in s390x_aes_gcm_aad()
1269 if (alen > (U64(1) << 61) || (sizeof(len) == 8 && alen < len)) in s390x_aes_gcm_aad()
1271 ctx->kma.param.taadl = alen; in s390x_aes_gcm_aad()
1803 size_t alen) in s390x_aes_ccm_aad() argument
1808 if (!alen) in s390x_aes_ccm_aad()
1816 if (alen < ((1 << 16) - (1 << 8))) { in s390x_aes_ccm_aad()
1817 *(uint16_t *)ptr = alen; in s390x_aes_ccm_aad()
1819 } else if (sizeof(alen) == 8 in s390x_aes_ccm_aad()
1820 && alen >= (size_t)1 << (32 % (sizeof(alen) * 8))) { in s390x_aes_ccm_aad()
1822 *(uint64_t *)(ptr + 2) = alen; in s390x_aes_ccm_aad()
1826 *(uint32_t *)(ptr + 2) = alen; in s390x_aes_ccm_aad()
1830 while (i < 16 && alen) { in s390x_aes_ccm_aad()
1833 --alen; in s390x_aes_ccm_aad()
1847 rem = alen & 0xf; in s390x_aes_ccm_aad()
1848 alen &= ~(size_t)0xf; in s390x_aes_ccm_aad()
1849 if (alen) { in s390x_aes_ccm_aad()
1850 s390x_kmac(aad, alen, ctx->aes.ccm.fc, &ctx->aes.ccm.kmac_param); in s390x_aes_ccm_aad()
1851 ctx->aes.ccm.blocks += alen >> 4; in s390x_aes_ccm_aad()
1852 aad += alen; in s390x_aes_ccm_aad()