On 1/7/23 02:06, Jakub Kicinski wrote: > Some extra nits here since you need to respin for the build warning > (include the document in some index / toc tree and adjust the length > of the underscores to match the line length). Thanks again, will correct according to your review notes, > > On Tue, 3 Jan 2023 18:42:57 +0000 Dmitry Safonov wrote: >> diff --git a/Documentation/crypto/crypto_pool.rst b/Documentation/crypto/crypto_pool.rst >> new file mode 100644 >> index 000000000000..4b8443171421 >> --- /dev/null >> +++ b/Documentation/crypto/crypto_pool.rst >> @@ -0,0 +1,33 @@ >> +.. SPDX-License-Identifier: GPL-2.0 >> + >> +Per-CPU pool of crypto requests >> +============= >> + >> +Overview >> +-------- >> +The crypto pool API manages pre-allocated per-CPU pool of crypto requests, >> +providing ability to use async crypto requests on fast paths, potentially > > .. you *don't* enable async crypto in this series, right? > >> +on atomic contexts. The allocation and initialization of the requests should > > s/on/in/ atomic contexts > >> +be done before their usage as it's slow-path and may sleep. >> + >> +Order of operations >> +------------------- >> +You are required to allocate a new pool prior using it and manage its lifetime. > > The use of second person is quite uncommon for documentation, but if > you prefer so be it.. I used Documentation/crypto/crypto_engine.rst as an example :-) [where "example" was `cp crypto_{engine,pool}.rst && vim crypto_pool.rst`] > >> +You can allocate a per-CPU pool of ahash requests by ``crypto_pool_alloc_ahash()``. > > You don't need to use the backticks around function names and struct > names. Our doc rendering system recognizes them automatically. > > `make htmldocs` to see for yourself. Thanks, Dmitry