Lines Matching refs:sw

87 swcr_encdec(struct cryptodesc *crd, const struct swcr_data *sw, void *bufv,  in swcr_encdec()  argument
97 exf = sw->sw_exf; in swcr_encdec()
112 exf->reinit(sw->sw_kschedule, iv, 0); in swcr_encdec()
114 exf->reinit(sw->sw_kschedule, 0, iv); in swcr_encdec()
133 exf->reinit(sw->sw_kschedule, iv, 0); in swcr_encdec()
143 exf->encrypt(sw->sw_kschedule, buf + i); in swcr_encdec()
145 exf->decrypt(sw->sw_kschedule, buf + i); in swcr_encdec()
158 exf->encrypt(sw->sw_kschedule, buf + i); in swcr_encdec()
167 exf->decrypt(sw->sw_kschedule, buf + i); in swcr_encdec()
201 exf->encrypt(sw->sw_kschedule, in swcr_encdec()
204 exf->decrypt(sw->sw_kschedule, in swcr_encdec()
212 exf->encrypt(sw->sw_kschedule, blk); in swcr_encdec()
230 exf->decrypt(sw->sw_kschedule, blk); in swcr_encdec()
279 exf->encrypt(sw->sw_kschedule, in swcr_encdec()
282 exf->decrypt(sw->sw_kschedule, in swcr_encdec()
290 exf->encrypt(sw->sw_kschedule, idat); in swcr_encdec()
302 exf->decrypt(sw->sw_kschedule, idat); in swcr_encdec()
344 exf->encrypt(sw->sw_kschedule, in swcr_encdec()
347 exf->decrypt(sw->sw_kschedule, in swcr_encdec()
355 exf->encrypt(sw->sw_kschedule, blk); in swcr_encdec()
373 exf->decrypt(sw->sw_kschedule, blk); in swcr_encdec()
413 exf->encrypt(sw->sw_kschedule, in swcr_encdec()
416 exf->decrypt(sw->sw_kschedule, in swcr_encdec()
424 exf->encrypt(sw->sw_kschedule, idat); in swcr_encdec()
436 exf->decrypt(sw->sw_kschedule, idat); in swcr_encdec()
466 const struct swcr_data *sw, void *buf, int outtype) in swcr_authcompute() argument
473 if (sw->sw_ictx == 0) in swcr_authcompute()
476 axf = sw->sw_axf; in swcr_authcompute()
478 memcpy(&ctx, sw->sw_ictx, axf->ctxsize); in swcr_authcompute()
504 switch (sw->sw_alg) { in swcr_authcompute()
514 if (sw->sw_octx == NULL) in swcr_authcompute()
518 memcpy(&ctx, sw->sw_octx, axf->ctxsize); in swcr_authcompute()
525 if (sw->sw_octx == NULL) in swcr_authcompute()
528 axf->Update(&ctx, sw->sw_octx, sw->sw_klen); in swcr_authcompute()
571 struct swcr_data *sw, *swa, *swe = NULL; in swcr_combined() local
579 for (sw = swcr_sessions[crp->crp_sid & 0xffffffff]; in swcr_combined()
580 sw && sw->sw_alg != crd->crd_alg; in swcr_combined()
581 sw = sw->sw_next) in swcr_combined()
583 if (sw == NULL) in swcr_combined()
586 switch (sw->sw_alg) { in swcr_combined()
589 swe = sw; in swcr_combined()
597 swa = sw; in swcr_combined()
700 swcr_compdec(struct cryptodesc *crd, const struct swcr_data *sw, in swcr_compdec() argument
708 cxf = sw->sw_cxf; in swcr_compdec()
736 sw->sw_alg == CRYPTO_DEFLATE_COMP_NOGROW && in swcr_compdec()
1144 struct swcr_data *sw; in swcr_process() local
1183 for (sw = swcr_sessions[lid]; in swcr_process()
1184 sw && sw->sw_alg != crd->crd_alg; in swcr_process()
1185 sw = sw->sw_next) in swcr_process()
1189 if (sw == NULL) { in swcr_process()
1194 switch (sw->sw_alg) { in swcr_process()
1203 if ((crp->crp_etype = swcr_encdec(crd, sw, in swcr_process()
1225 if ((crp->crp_etype = swcr_authcompute(crp, crd, sw, in swcr_process()
1241 DPRINTF("compdec for %d\n", sw->sw_alg); in swcr_process()
1242 if ((crp->crp_etype = swcr_compdec(crd, sw, in swcr_process()