forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f9004dbfff8a3fbbd7e2a88c8a4327c7f2f8e5b2
kernel/drivers/crypto/allwinner/sun8i-ss/sun8i-ss-cipher.c
....@@ -105,7 +105,7 @@
105105 unsigned int ivsize = crypto_skcipher_ivsize(tfm);
106106 struct sun8i_ss_flow *sf = &ss->flows[rctx->flow];
107107 int i = 0;
108
- u32 a;
108
+ dma_addr_t a;
109109 int err;
110110
111111 rctx->ivlen = ivsize;
....@@ -132,7 +132,7 @@
132132 }
133133 rctx->p_iv[i] = a;
134134 /* we need to setup all others IVs only in the decrypt way */
135
- if (rctx->op_dir & SS_ENCRYPTION)
135
+ if (rctx->op_dir == SS_ENCRYPTION)
136136 return 0;
137137 todo = min(len, sg_dma_len(sg));
138138 len -= todo;