Thread (51 messages) 51 messages, 12 authors, 2020-09-29

Re: [patch 00/13] preempt: Make preempt count unconditional

From: Herbert Xu <herbert@gondor.apana.org.au>
Date: 2020-09-15 06:24:12
Also in: dri-devel, intel-gfx, linux-mm, linux-um

On Tue, Sep 15, 2020 at 09:20:59AM +0300, Ard Biesheuvel wrote:
The documentation of kmap_atomic() states the following:

 * The use of kmap_atomic/kunmap_atomic is discouraged - kmap/kunmap
 * gives a more generic (and caching) interface. But kmap_atomic can
 * be used in IRQ contexts, so in some (very limited) cases we need
 * it.

so if this is no longer accurate, perhaps we should fix it?
This hasn't been accurate for at least ten years :)
But another reason I tried to avoid kmap_atomic() is that it disables
preemption unconditionally, even on 64-bit architectures where HIGHMEM
is irrelevant. So using kmap_atomic() here means that the bulk of
WireGuard packet encryption runs with preemption disabled, essentially
for legacy reasons.
Agreed.  We should definitely fix that.

Thanks,
-- 
Email: Herbert Xu [off-list ref]
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help