summaryrefslogtreecommitdiff
path: root/include/crypto/internal/acompress.h
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2025-03-17 16:33:59 +0800
committerHerbert Xu <herbert@gondor.apana.org.au>2025-04-07 13:22:25 +0800
commitc47e1f4142a3823b6e963e14db295a8a733804b5 (patch)
tree53b32f282ddba99c35212b498d18c452873d3f30 /include/crypto/internal/acompress.h
parent138804c2c18ca8bd1443dea173b3cc2643995919 (diff)
crypto: scomp - Allocate per-cpu buffer on first use of each CPU
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. On start-up allocate a single buffer on the first possible CPU. For every other CPU a work struct will be scheduled on first use to allocate the buffer for that CPU. Until the allocation succeeds simply use the first CPU's buffer which is protected under a spin lock. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'include/crypto/internal/acompress.h')
-rw-r--r--include/crypto/internal/acompress.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/include/crypto/internal/acompress.h b/include/crypto/internal/acompress.h
index aaf59f3236fa..2af690819a83 100644
--- a/include/crypto/internal/acompress.h
+++ b/include/crypto/internal/acompress.h
@@ -37,7 +37,6 @@
*
* @reqsize: Context size for (de)compression requests
* @base: Common crypto API algorithm data structure
- * @stream: Per-cpu memory for algorithm
* @calg: Cmonn algorithm data structure shared with scomp
*/
struct acomp_alg {