MLK-19449: crypto: caam - Add Power Management
Add support for suspend and resume operation for PM in CAAM driver. When the CAAM goes in suspend, the hardware is considered to do nothing. On some platforms, the power of the CAAM is not turned off so it keeps its configuration. On other platforms, it doesn't so it is necessary to save the state of the CAAM: - JRs MID - Address of input and output rings Limitation: When the CAAM is powered OFF, it is resetted so the JDKEK and TDKEK changes. This impacts crypto transforms using MDHA split-keys which are kept over suspend as they are encrypted with the JDKEK: - hmac(*) from caamhash.c - authenc(hmac(*),*) from caamalg.c - echainiv(authenc(hmac(*),*)) from caamalg.c The issue was already present in current code so this patch does not add a regression in this regard. Reviewed-by:Horia Geantă <horia.geanta@nxp.com> Signed-off-by:
Franck LENORMAND <franck.lenormand@nxp.com> (cherry picked from commit b90e25f2)
Showing
- drivers/crypto/caam/ctrl.c 153 additions, 24 deletionsdrivers/crypto/caam/ctrl.c
- drivers/crypto/caam/inst_rng.c 1 addition, 12 deletionsdrivers/crypto/caam/inst_rng.c
- drivers/crypto/caam/intern.h 34 additions, 1 deletiondrivers/crypto/caam/intern.h
- drivers/crypto/caam/jr.c 258 additions, 79 deletionsdrivers/crypto/caam/jr.c
Loading
Please register or sign in to comment