• Home
  • Raw
  • Download

Lines Matching refs:dlen

88 			unsigned int slen, unsigned int dlen)  in update_param()  argument
92 if (p->oremain < dlen) in update_param()
97 p->out += dlen; in update_param()
98 p->oremain -= dlen; in update_param()
99 p->ototal += dlen; in update_param()
165 unsigned int slen = p->iremain, dlen = p->oremain, tmplen; in compress() local
174 if (p->oremain == 0 || hdrsize + c->minimum > dlen) in compress()
195 dlen -= hdrsize; in compress()
200 dlen -= dskip; in compress()
202 if (dlen % c->multiple) in compress()
203 dlen = round_down(dlen, c->multiple); in compress()
204 if (dlen < c->minimum) { in compress()
207 dlen = min(p->oremain, BOUNCE_BUFFER_SIZE); in compress()
208 dlen = round_down(dlen, c->multiple); in compress()
210 pr_debug("using comp dbounce buffer, len %x\n", dlen); in compress()
212 if (dlen > c->maximum) in compress()
213 dlen = c->maximum; in compress()
215 tmplen = dlen; in compress()
218 dlen = tmplen; /* reset dlen, if we're retrying */ in compress()
219 ret = ctx->driver->compress(src, slen, dst, &dlen, ctx->wmem); in compress()
232 memcpy(p->out + dskip, dst, dlen); in compress()
235 g->compressed_length = cpu_to_be32(dlen); in compress()
244 slen, *ignore, dlen, dskip); in compress()
246 return update_param(p, slen, dskip + dlen); in compress()
251 u8 *dst, unsigned int *dlen) in nx842_crypto_compress() argument
267 p.oremain = *dlen; in nx842_crypto_compress()
270 *dlen = 0; in nx842_crypto_compress()
325 *dlen = p.ototal; in nx842_crypto_compress()
327 pr_debug("compress total slen %x dlen %x\n", slen, *dlen); in nx842_crypto_compress()
343 unsigned int dlen = p->oremain, tmplen; in decompress() local
381 if (dlen % c->multiple) in decompress()
382 dlen = round_down(dlen, c->multiple); in decompress()
383 if (dlen < required_len || (u64)dst % c->alignment) { in decompress()
385 dlen = min(required_len, BOUNCE_BUFFER_SIZE); in decompress()
386 pr_debug("using decomp dbounce buffer, len %x\n", dlen); in decompress()
388 if (dlen < c->minimum) in decompress()
390 if (dlen > c->maximum) in decompress()
391 dlen = c->maximum; in decompress()
393 tmplen = dlen; in decompress()
396 dlen = tmplen; /* reset dlen, if we're retrying */ in decompress()
397 ret = ctx->driver->decompress(src, slen, dst, &dlen, ctx->wmem); in decompress()
406 dlen = p->oremain; in decompress()
407 if (dlen < required_len) { /* have ignore bytes */ in decompress()
409 dlen = BOUNCE_BUFFER_SIZE; in decompress()
412 ret = sw842_decompress(src, slen, dst, &dlen); in decompress()
419 dlen -= ignore; in decompress()
424 memcpy(p->out, dst, dlen); in decompress()
427 slen, padding, dlen, ignore); in decompress()
429 return update_param(p, slen + padding, dlen); in decompress()
434 u8 *dst, unsigned int *dlen) in nx842_crypto_decompress() argument
448 p.oremain = *dlen; in nx842_crypto_decompress()
451 *dlen = 0; in nx842_crypto_decompress()
506 *dlen = p.ototal; in nx842_crypto_decompress()
508 pr_debug("decompress total slen %x dlen %x\n", slen, *dlen); in nx842_crypto_decompress()