Skip to content

Commit f775712

Browse files
committed
Merge tag 'v6.5-p3' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
Pull crypto fixes from Herbert Xu: "Fix a regression in the caam driver and af_alg" * tag 'v6.5-p3' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: crypto: fix uninit-value in af_alg_free_resources Revert "crypto: caam - adjust RNG timing to support more devices"
2 parents 4542057 + 080aa61 commit f775712

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

crypto/af_alg.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1241,6 +1241,8 @@ int af_alg_get_rsgl(struct sock *sk, struct msghdr *msg, int flags,
12411241
return -ENOMEM;
12421242
}
12431243

1244+
rsgl->sgl.need_unpin =
1245+
iov_iter_extract_will_pin(&msg->msg_iter);
12441246
rsgl->sgl.sgt.sgl = rsgl->sgl.sgl;
12451247
rsgl->sgl.sgt.nents = 0;
12461248
rsgl->sgl.sgt.orig_nents = 0;
@@ -1255,8 +1257,6 @@ int af_alg_get_rsgl(struct sock *sk, struct msghdr *msg, int flags,
12551257
}
12561258

12571259
sg_mark_end(rsgl->sgl.sgt.sgl + rsgl->sgl.sgt.nents - 1);
1258-
rsgl->sgl.need_unpin =
1259-
iov_iter_extract_will_pin(&msg->msg_iter);
12601260

12611261
/* chain the new scatterlist with previous one */
12621262
if (areq->last_rsgl)

drivers/crypto/caam/ctrl.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -382,8 +382,8 @@ static void kick_trng(struct device *dev, int ent_delay)
382382
val = ent_delay;
383383
/* min. freq. count, equal to 1/4 of the entropy sample length */
384384
wr_reg32(&r4tst->rtfrqmin, val >> 2);
385-
/* max. freq. count, equal to 16 times the entropy sample length */
386-
wr_reg32(&r4tst->rtfrqmax, val << 4);
385+
/* disable maximum frequency count */
386+
wr_reg32(&r4tst->rtfrqmax, RTFRQMAX_DISABLE);
387387
}
388388

389389
wr_reg32(&r4tst->rtsdctl, (val << RTSDCTL_ENT_DLY_SHIFT) |

0 commit comments

Comments
 (0)