Home
last modified time | relevance | path

Searched hist:"255 f6c2e" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/lib/crypto/
H A Dchacha20poly1305.c255f6c2e Mon Sep 14 22:30:24 CDT 2020 Herbert Xu <herbert@gondor.apana.org.au> crypto: lib/chacha20poly1305 - Set SG_MITER_ATOMIC unconditionally

There is no reason for the chacha20poly1305 SG miter code to use
kmap instead of kmap_atomic as the critical section doesn't sleep
anyway. So we can simply get rid of the preemptible check and
set SG_MITER_ATOMIC unconditionally.

Even if we need to reenable preemption to lower latency we should
be doing that by interrupting the SG miter walk rather than using
kmap.

Reported-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
255f6c2e Mon Sep 14 22:30:24 CDT 2020 Herbert Xu <herbert@gondor.apana.org.au> crypto: lib/chacha20poly1305 - Set SG_MITER_ATOMIC unconditionally

There is no reason for the chacha20poly1305 SG miter code to use
kmap instead of kmap_atomic as the critical section doesn't sleep
anyway. So we can simply get rid of the preemptible check and
set SG_MITER_ATOMIC unconditionally.

Even if we need to reenable preemption to lower latency we should
be doing that by interrupting the SG miter walk rather than using
kmap.

Reported-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>