Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

crypto: hash - Move core export and import into internel/hash.h

The core export and import functions are targeted at implementors
so move them into internal/hash.h.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

+48 -48
-48
include/crypto/hash.h
··· 507 507 int crypto_ahash_export(struct ahash_request *req, void *out); 508 508 509 509 /** 510 - * crypto_ahash_export_core() - extract core state for message digest 511 - * @req: reference to the ahash_request handle whose state is exported 512 - * @out: output buffer of sufficient size that can hold the hash state 513 - * 514 - * Export the hash state without the partial block buffer. 515 - * 516 - * Context: Softirq or process context. 517 - * Return: 0 if the export creation was successful; < 0 if an error occurred 518 - */ 519 - int crypto_ahash_export_core(struct ahash_request *req, void *out); 520 - 521 - /** 522 510 * crypto_ahash_import() - import message digest state 523 511 * @req: reference to ahash_request handle the state is imported into 524 512 * @in: buffer holding the state ··· 518 530 * Return: 0 if the import was successful; < 0 if an error occurred 519 531 */ 520 532 int crypto_ahash_import(struct ahash_request *req, const void *in); 521 - 522 - /** 523 - * crypto_ahash_import_core() - import core state 524 - * @req: reference to ahash_request handle the state is imported into 525 - * @in: buffer holding the state 526 - * 527 - * Import the hash state without the partial block buffer. 528 - * 529 - * Context: Softirq or process context. 530 - * Return: 0 if the import was successful; < 0 if an error occurred 531 - */ 532 - int crypto_ahash_import_core(struct ahash_request *req, const void *in); 533 533 534 534 /** 535 535 * crypto_ahash_init() - (re)initialize message digest handle ··· 910 934 int crypto_shash_export(struct shash_desc *desc, void *out); 911 935 912 936 /** 913 - * crypto_shash_export_core() - extract core state for message digest 914 - * @desc: reference to the operational state handle whose state is exported 915 - * @out: output buffer of sufficient size that can hold the hash state 916 - * 917 - * Export the hash state without the partial block buffer. 918 - * 919 - * Context: Softirq or process context. 920 - * Return: 0 if the export creation was successful; < 0 if an error occurred 921 - */ 922 - int crypto_shash_export_core(struct shash_desc *desc, void *out); 923 - 924 - /** 925 937 * crypto_shash_import() - import operational state 926 938 * @desc: reference to the operational state handle the state imported into 927 939 * @in: buffer holding the state ··· 922 958 * Return: 0 if the import was successful; < 0 if an error occurred 923 959 */ 924 960 int crypto_shash_import(struct shash_desc *desc, const void *in); 925 - 926 - /** 927 - * crypto_shash_import_core() - import core state 928 - * @desc: reference to the operational state handle the state imported into 929 - * @in: buffer holding the state 930 - * 931 - * Import the hash state without the partial block buffer. 932 - * 933 - * Context: Softirq or process context. 934 - * Return: 0 if the import was successful; < 0 if an error occurred 935 - */ 936 - int crypto_shash_import_core(struct shash_desc *desc, const void *in); 937 961 938 962 /** 939 963 * crypto_shash_init() - (re)initialize message digest
+48
include/crypto/internal/hash.h
··· 305 305 #define HASH_REQUEST_ZERO(name) \ 306 306 memzero_explicit(__##name##_req, sizeof(__##name##_req)) 307 307 308 + /** 309 + * crypto_ahash_export_core() - extract core state for message digest 310 + * @req: reference to the ahash_request handle whose state is exported 311 + * @out: output buffer of sufficient size that can hold the hash state 312 + * 313 + * Export the hash state without the partial block buffer. 314 + * 315 + * Context: Softirq or process context. 316 + * Return: 0 if the export creation was successful; < 0 if an error occurred 317 + */ 318 + int crypto_ahash_export_core(struct ahash_request *req, void *out); 319 + 320 + /** 321 + * crypto_ahash_import_core() - import core state 322 + * @req: reference to ahash_request handle the state is imported into 323 + * @in: buffer holding the state 324 + * 325 + * Import the hash state without the partial block buffer. 326 + * 327 + * Context: Softirq or process context. 328 + * Return: 0 if the import was successful; < 0 if an error occurred 329 + */ 330 + int crypto_ahash_import_core(struct ahash_request *req, const void *in); 331 + 332 + /** 333 + * crypto_shash_export_core() - extract core state for message digest 334 + * @desc: reference to the operational state handle whose state is exported 335 + * @out: output buffer of sufficient size that can hold the hash state 336 + * 337 + * Export the hash state without the partial block buffer. 338 + * 339 + * Context: Softirq or process context. 340 + * Return: 0 if the export creation was successful; < 0 if an error occurred 341 + */ 342 + int crypto_shash_export_core(struct shash_desc *desc, void *out); 343 + 344 + /** 345 + * crypto_shash_import_core() - import core state 346 + * @desc: reference to the operational state handle the state imported into 347 + * @in: buffer holding the state 348 + * 349 + * Import the hash state without the partial block buffer. 350 + * 351 + * Context: Softirq or process context. 352 + * Return: 0 if the import was successful; < 0 if an error occurred 353 + */ 354 + int crypto_shash_import_core(struct shash_desc *desc, const void *in); 355 + 308 356 #endif /* _CRYPTO_INTERNAL_HASH_H */ 309 357