Skip to content

crypto: scomp - Allocate per-cpu buffers on first use

Herbert Xu linux-crypto 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3crypto: api - Move alg destroy work from instance to templatecrypto/algapi.c include/crypto/algapi.h+30 -100 replies
2/3crypto: api - Ensure cra_type->destroy is done in process contextcrypto/algapi.c crypto/api.c crypto/internal.h+11 -150 replies
3/3crypto: scomp - Allocate per-cpu buffer on first use of each CPUcrypto/scompress.c include/crypto/acompress.h include/crypto/internal/acompress.h +1 more+173 -500 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/3] crypto: scomp - Allocate per-cpu buffers on first use

Per-cpu buffers can be wasteful when the number of CPUs is large, especially if the buffer itself is likely to never be used. Reduce such wastage by only allocating them on first use of a particular CPU.

The first two patches create the gound-work so that scomp can safely flush work structs in its cra_destroy function. The last patch implements allocation on first use.

Herbert Xu (3):
crypto: api - Move alg destroy work from instance to template
crypto: api - Ensure cra_type->destroy is done in process context
crypto: scomp - Allocate per-cpu buffer on first use of each CPU

 crypto/algapi.c                     |  48 +++++--
 crypto/api.c                        |  10 --
 crypto/internal.h                   |   3 +-
 crypto/scompress.c                  | 203 ++++++++++++++++++++++------
 include/crypto/acompress.h          |   6 -
 include/crypto/algapi.h             |   5 +-
 include/crypto/internal/acompress.h |   1 -
 include/crypto/internal/scompress.h |  13 ++
 8 files changed, 214 insertions(+), 75 deletions(-)
Signature · 1 line
2.39.5