Skip to content

Commit

Permalink
crypto: doc - optimize compilation
Browse files Browse the repository at this point in the history
The :functions: definition allows the specification of multiple
function references which prevents parsing the header file multiple
times.

Reported-by: Jani Nikula <[email protected]>
Signed-off-by: Stephan Mueller <[email protected]>
Signed-off-by: Jonathan Corbet <[email protected]>
  • Loading branch information
smuellerDD authored and Jonathan Corbet committed Dec 13, 2016
1 parent 3f692d5 commit 3fa71d0
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 401 deletions.
51 changes: 3 additions & 48 deletions Documentation/crypto/api-aead.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,40 +5,13 @@ Authenticated Encryption With Associated Data (AEAD) Algorithm Definitions
:doc: Authenticated Encryption With Associated Data (AEAD) Cipher API

.. kernel-doc:: include/crypto/aead.h
:functions: aead_request

.. kernel-doc:: include/crypto/aead.h
:functions: aead_alg
:functions: aead_request aead_alg

Authenticated Encryption With Associated Data (AEAD) Cipher API
---------------------------------------------------------------

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_alloc_aead

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_free_aead

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_aead_ivsize

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_aead_authsize

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_aead_blocksize

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_aead_setkey

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_aead_setauthsize

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_aead_encrypt

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_aead_decrypt
:functions: crypto_alloc_aead crypto_free_aead crypto_aead_ivsize crypto_aead_authsize crypto_aead_blocksize crypto_aead_setkey crypto_aead_setauthsize crypto_aead_encrypt crypto_aead_decrypt

Asynchronous AEAD Request Handle
--------------------------------
Expand All @@ -47,22 +20,4 @@ Asynchronous AEAD Request Handle
:doc: Asynchronous AEAD Request Handle

.. kernel-doc:: include/crypto/aead.h
:functions: crypto_aead_reqsize

.. kernel-doc:: include/crypto/aead.h
:functions: aead_request_set_tfm

.. kernel-doc:: include/crypto/aead.h
:functions: aead_request_alloc

.. kernel-doc:: include/crypto/aead.h
:functions: aead_request_free

.. kernel-doc:: include/crypto/aead.h
:functions: aead_request_set_callback

.. kernel-doc:: include/crypto/aead.h
:functions: aead_request_set_crypt

.. kernel-doc:: include/crypto/aead.h
:functions: aead_request_set_ad
:functions: crypto_aead_reqsize aead_request_set_tfm aead_request_alloc aead_request_free aead_request_set_callback aead_request_set_crypt aead_request_set_ad
42 changes: 3 additions & 39 deletions Documentation/crypto/api-akcipher.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@ Asymmetric Cipher Algorithm Definitions
---------------------------------------

.. kernel-doc:: include/crypto/akcipher.h
:functions: akcipher_alg

.. kernel-doc:: include/crypto/akcipher.h
:functions: akcipher_request
:functions: akcipher_alg akcipher_request

Asymmetric Cipher API
---------------------
Expand All @@ -14,43 +11,10 @@ Asymmetric Cipher API
:doc: Generic Public Key API

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_alloc_akcipher

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_free_akcipher

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_akcipher_set_pub_key

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_akcipher_set_priv_key

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_akcipher_maxsize

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_akcipher_encrypt

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_akcipher_decrypt

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_akcipher_sign

.. kernel-doc:: include/crypto/akcipher.h
:functions: crypto_akcipher_verify
:functions: crypto_alloc_akcipher crypto_free_akcipher crypto_akcipher_set_pub_key crypto_akcipher_set_priv_key crypto_akcipher_maxsize crypto_akcipher_encrypt crypto_akcipher_decrypt crypto_akcipher_sign crypto_akcipher_verify

Asymmetric Cipher Request Handle
--------------------------------

.. kernel-doc:: include/crypto/akcipher.h
:functions: akcipher_request_alloc

.. kernel-doc:: include/crypto/akcipher.h
:functions: akcipher_request_free

.. kernel-doc:: include/crypto/akcipher.h
:functions: akcipher_request_set_callback

.. kernel-doc:: include/crypto/akcipher.h
:functions: akcipher_request_set_crypt
:functions: akcipher_request_alloc akcipher_request_free akcipher_request_set_callback akcipher_request_set_crypt
95 changes: 4 additions & 91 deletions Documentation/crypto/api-digest.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,7 @@ Message Digest Algorithm Definitions
:doc: Message Digest Algorithm Definitions

.. kernel-doc:: include/crypto/hash.h
:functions: hash_alg_common

.. kernel-doc:: include/crypto/hash.h
:functions: ahash_alg

.. kernel-doc:: include/crypto/hash.h
:functions: shash_alg
:functions: hash_alg_common ahash_alg shash_alg

Asynchronous Message Digest API
-------------------------------
Expand All @@ -20,40 +14,7 @@ Asynchronous Message Digest API
:doc: Asynchronous Message Digest API

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_alloc_ahash

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_free_ahash

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_init

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_digestsize

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_reqtfm

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_reqsize

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_setkey

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_finup

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_final

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_digest

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_export

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_ahash_import
:functions: crypto_alloc_ahash crypto_free_ahash crypto_ahash_init crypto_ahash_digestsize crypto_ahash_reqtfm crypto_ahash_reqsize crypto_ahash_setkey crypto_ahash_finup crypto_ahash_final crypto_ahash_digest crypto_ahash_export crypto_ahash_import

Asynchronous Hash Request Handle
--------------------------------
Expand All @@ -62,19 +23,7 @@ Asynchronous Hash Request Handle
:doc: Asynchronous Hash Request Handle

.. kernel-doc:: include/crypto/hash.h
:functions: ahash_request_set_tfm

.. kernel-doc:: include/crypto/hash.h
:functions: ahash_request_alloc

.. kernel-doc:: include/crypto/hash.h
:functions: ahash_request_free

.. kernel-doc:: include/crypto/hash.h
:functions: ahash_request_set_callback

.. kernel-doc:: include/crypto/hash.h
:functions: ahash_request_set_crypt
:functions: ahash_request_set_tfm ahash_request_alloc ahash_request_free ahash_request_set_callback ahash_request_set_crypt

Synchronous Message Digest API
------------------------------
Expand All @@ -83,40 +32,4 @@ Synchronous Message Digest API
:doc: Synchronous Message Digest API

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_alloc_shash

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_free_shash

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_blocksize

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_digestsize

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_descsize

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_setkey

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_digest

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_export

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_import

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_init

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_update

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_final

.. kernel-doc:: include/crypto/hash.h
:functions: crypto_shash_finup
:functions: crypto_alloc_shash crypto_free_shash crypto_shash_blocksize crypto_shash_digestsize crypto_shash_descsize crypto_shash_setkey crypto_shash_digest crypto_shash_export crypto_shash_import crypto_shash_init crypto_shash_update crypto_shash_final crypto_shash_finup
64 changes: 5 additions & 59 deletions Documentation/crypto/api-kpp.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,7 @@ Key-agreement Protocol Primitives (KPP) Cipher Algorithm Definitions
--------------------------------------------------------------------

.. kernel-doc:: include/crypto/kpp.h
:functions: kpp_request

.. kernel-doc:: include/crypto/kpp.h
:functions: crypto_kpp

.. kernel-doc:: include/crypto/kpp.h
:functions: kpp_alg

.. kernel-doc:: include/crypto/kpp.h
:functions: kpp_secret
:functions: kpp_request crypto_kpp kpp_alg kpp_secret

Key-agreement Protocol Primitives (KPP) Cipher API
--------------------------------------------------
Expand All @@ -20,40 +11,13 @@ Key-agreement Protocol Primitives (KPP) Cipher API
:doc: Generic Key-agreement Protocol Primitives API

.. kernel-doc:: include/crypto/kpp.h
:functions: crypto_alloc_kpp

.. kernel-doc:: include/crypto/kpp.h
:functions: crypto_free_kpp

.. kernel-doc:: include/crypto/kpp.h
:functions: crypto_kpp_set_secret

.. kernel-doc:: include/crypto/kpp.h
:functions: crypto_kpp_generate_public_key

.. kernel-doc:: include/crypto/kpp.h
:functions: crypto_kpp_compute_shared_secret

.. kernel-doc:: include/crypto/kpp.h
:functions: crypto_kpp_maxsize
:functions: crypto_alloc_kpp crypto_free_kpp crypto_kpp_set_secret crypto_kpp_generate_public_key crypto_kpp_compute_shared_secret crypto_kpp_maxsize

Key-agreement Protocol Primitives (KPP) Cipher Request Handle
-------------------------------------------------------------

.. kernel-doc:: include/crypto/kpp.h
:functions: kpp_request_alloc

.. kernel-doc:: include/crypto/kpp.h
:functions: kpp_request_free

.. kernel-doc:: include/crypto/kpp.h
:functions: kpp_request_set_callback

.. kernel-doc:: include/crypto/kpp.h
:functions: kpp_request_set_input

.. kernel-doc:: include/crypto/kpp.h
:functions: kpp_request_set_output
:functions: kpp_request_alloc kpp_request_free kpp_request_set_callback kpp_request_set_input kpp_request_set_output

ECDH Helper Functions
---------------------
Expand All @@ -62,16 +26,7 @@ ECDH Helper Functions
:doc: ECDH Helper Functions

.. kernel-doc:: include/crypto/ecdh.h
:functions: ecdh

.. kernel-doc:: include/crypto/ecdh.h
:functions: crypto_ecdh_key_len

.. kernel-doc:: include/crypto/ecdh.h
:functions: crypto_ecdh_encode_key

.. kernel-doc:: include/crypto/ecdh.h
:functions: crypto_ecdh_decode_key
:functions: ecdh crypto_ecdh_key_len crypto_ecdh_encode_key crypto_ecdh_decode_key

DH Helper Functions
-------------------
Expand All @@ -80,13 +35,4 @@ DH Helper Functions
:doc: DH Helper Functions

.. kernel-doc:: include/crypto/dh.h
:functions: dh

.. kernel-doc:: include/crypto/dh.h
:functions: crypto_dh_key_len

.. kernel-doc:: include/crypto/dh.h
:functions: crypto_dh_encode_key

.. kernel-doc:: include/crypto/dh.h
:functions: crypto_dh_decode_key
:functions: dh crypto_dh_key_len crypto_dh_encode_key crypto_dh_decode_key
20 changes: 1 addition & 19 deletions Documentation/crypto/api-rng.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,22 +11,4 @@ Crypto API Random Number API
:doc: Random number generator API

.. kernel-doc:: include/crypto/rng.h
:functions: crypto_alloc_rng

.. kernel-doc:: include/crypto/rng.h
:functions: crypto_rng_alg

.. kernel-doc:: include/crypto/rng.h
:functions: crypto_free_rng

.. kernel-doc:: include/crypto/rng.h
:functions: crypto_rng_generate

.. kernel-doc:: include/crypto/rng.h
:functions: crypto_rng_get_bytes

.. kernel-doc:: include/crypto/rng.h
:functions: crypto_rng_reset

.. kernel-doc:: include/crypto/rng.h
:functions: crypto_rng_seedsize
:functions: crypto_alloc_rng crypto_rng_alg crypto_free_rng crypto_rng_generate crypto_rng_get_bytes crypto_rng_reset crypto_rng_seedsize
Loading

0 comments on commit 3fa71d0

Please sign in to comment.