Skip to content

Commit

Permalink
Merge tag 'v6.15-p6' of git://git.kernel.org/pub/scm/linux/kernel/git…
Browse files Browse the repository at this point in the history
…/herbert/crypto-2.6

Pull crypto fix from Herbert Xu:
 "This fixes a regression in scompress"

* tag 'v6.15-p6' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
  crypto: scompress - increment scomp_scratch_users when already allocated
  • Loading branch information
Linus Torvalds committed Apr 30, 2025
2 parents 8bac889 + a32f192 commit b6ea168
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions crypto/scompress.c
Original file line number Diff line number Diff line change
Expand Up @@ -163,11 +163,10 @@ static int crypto_scomp_init_tfm(struct crypto_tfm *tfm)
if (ret)
goto unlock;
}
if (!scomp_scratch_users) {
if (!scomp_scratch_users++) {
ret = crypto_scomp_alloc_scratches();
if (ret)
goto unlock;
scomp_scratch_users++;
scomp_scratch_users--;
}
unlock:
mutex_unlock(&scomp_lock);
Expand Down

0 comments on commit b6ea168

Please sign in to comment.