1618b5dc4SHoria Geantă# SPDX-License-Identifier: GPL-2.0 28d818c10SHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_COMMON 38d818c10SHoria Geantă tristate 48d818c10SHoria Geantă 51b46c90cSHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_CRYPTO_API_DESC 61b46c90cSHoria Geantă tristate 71b46c90cSHoria Geantă 81b46c90cSHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_AHASH_API_DESC 91b46c90cSHoria Geantă tristate 101b46c90cSHoria Geantă 118e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM 128d818c10SHoria Geantă tristate "Freescale CAAM-Multicore platform driver backend" 13*beba3771SBreno Leitao depends on FSL_SOC || ARCH_MXC || ARCH_LAYERSCAPE || COMPILE_TEST 14c056d910SHoria Geantă select SOC_BUS 158d818c10SHoria Geantă select CRYPTO_DEV_FSL_CAAM_COMMON 16358ba762SAndrey Smirnov imply FSL_MC_BUS 178e8ec596SKim Phillips help 188e8ec596SKim Phillips Enables the driver module for Freescale's Cryptographic Accelerator 198e8ec596SKim Phillips and Assurance Module (CAAM), also known as the SEC version 4 (SEC4). 20313ea293SRuchika Gupta This module creates job ring devices, and configures h/w 218e8ec596SKim Phillips to operate as a DPAA component automatically, depending 228e8ec596SKim Phillips on h/w feature availability. 238e8ec596SKim Phillips 248e8ec596SKim Phillips To compile this driver as a module, choose M here: the module 258e8ec596SKim Phillips will be called caam. 268e8ec596SKim Phillips 278d818c10SHoria Geantăif CRYPTO_DEV_FSL_CAAM 288d818c10SHoria Geantă 298d818c10SHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_DEBUG 308d818c10SHoria Geantă bool "Enable debug output in CAAM driver" 318d818c10SHoria Geantă help 328d818c10SHoria Geantă Selecting this will enable printing of various debug 338d818c10SHoria Geantă information in the CAAM driver. 348d818c10SHoria Geantă 351b46c90cSHoria Geantămenuconfig CRYPTO_DEV_FSL_CAAM_JR 36313ea293SRuchika Gupta tristate "Freescale CAAM Job Ring driver backend" 37ee38767fSIuliana Prodan select CRYPTO_ENGINE 38313ea293SRuchika Gupta default y 39313ea293SRuchika Gupta help 40313ea293SRuchika Gupta Enables the driver module for Job Rings which are part of 41313ea293SRuchika Gupta Freescale's Cryptographic Accelerator 42313ea293SRuchika Gupta and Assurance Module (CAAM). This module adds a job ring operation 43313ea293SRuchika Gupta interface. 44313ea293SRuchika Gupta 45313ea293SRuchika Gupta To compile this driver as a module, choose M here: the module 46313ea293SRuchika Gupta will be called caam_jr. 47313ea293SRuchika Gupta 488d818c10SHoria Geantăif CRYPTO_DEV_FSL_CAAM_JR 498d818c10SHoria Geantă 508e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_RINGSIZE 518e8ec596SKim Phillips int "Job Ring size" 528e8ec596SKim Phillips range 2 9 538e8ec596SKim Phillips default "9" 548e8ec596SKim Phillips help 558e8ec596SKim Phillips Select size of Job Rings as a power of 2, within the 568e8ec596SKim Phillips range 2-9 (ring size 4-512). 578e8ec596SKim Phillips Examples: 588e8ec596SKim Phillips 2 => 4 598e8ec596SKim Phillips 3 => 8 608e8ec596SKim Phillips 4 => 16 618e8ec596SKim Phillips 5 => 32 628e8ec596SKim Phillips 6 => 64 638e8ec596SKim Phillips 7 => 128 648e8ec596SKim Phillips 8 => 256 658e8ec596SKim Phillips 9 => 512 668e8ec596SKim Phillips 678e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_INTC 688e8ec596SKim Phillips bool "Job Ring interrupt coalescing" 698e8ec596SKim Phillips help 708e8ec596SKim Phillips Enable the Job Ring's interrupt coalescing feature. 718e8ec596SKim Phillips 721a076689SKim Phillips Note: the driver already provides adequate 731a076689SKim Phillips interrupt coalescing in software. 741a076689SKim Phillips 758e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_INTC_COUNT_THLD 768e8ec596SKim Phillips int "Job Ring interrupt coalescing count threshold" 778e8ec596SKim Phillips depends on CRYPTO_DEV_FSL_CAAM_INTC 788e8ec596SKim Phillips range 1 255 798e8ec596SKim Phillips default 255 808e8ec596SKim Phillips help 818e8ec596SKim Phillips Select number of descriptor completions to queue before 828e8ec596SKim Phillips raising an interrupt, in the range 1-255. Note that a selection 838e8ec596SKim Phillips of 1 functionally defeats the coalescing feature, and a selection 848e8ec596SKim Phillips equal or greater than the job ring size will force timeouts. 858e8ec596SKim Phillips 868e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_INTC_TIME_THLD 878e8ec596SKim Phillips int "Job Ring interrupt coalescing timer threshold" 888e8ec596SKim Phillips depends on CRYPTO_DEV_FSL_CAAM_INTC 898e8ec596SKim Phillips range 1 65535 908e8ec596SKim Phillips default 2048 918e8ec596SKim Phillips help 928e8ec596SKim Phillips Select number of bus clocks/64 to timeout in the case that one or 938e8ec596SKim Phillips more descriptor completions are queued without reaching the count 948e8ec596SKim Phillips threshold. Range is 1-65535. 958e8ec596SKim Phillips 968e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_CRYPTO_API 971b46c90cSHoria Geantă bool "Register algorithm implementations with the Crypto API" 988e8ec596SKim Phillips default y 991b46c90cSHoria Geantă select CRYPTO_DEV_FSL_CAAM_CRYPTO_API_DESC 100596103cfSHerbert Xu select CRYPTO_AEAD 1018e8ec596SKim Phillips select CRYPTO_AUTHENC 102b95bba5dSEric Biggers select CRYPTO_SKCIPHER 10304007b0eSArd Biesheuvel select CRYPTO_LIB_DES 1049d9b14dbSAndrei Botila select CRYPTO_XTS 1058e8ec596SKim Phillips help 1068e8ec596SKim Phillips Selecting this will offload crypto for users of the 1078e8ec596SKim Phillips scatterlist crypto API (such as the linux native IPSec 1088e8ec596SKim Phillips stack) to the SEC4 via job ring. 1098e8ec596SKim Phillips 110b189817cSHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_CRYPTO_API_QI 1111b46c90cSHoria Geantă bool "Queue Interface as Crypto API backend" 1128d818c10SHoria Geantă depends on FSL_DPAA && NET 113b189817cSHoria Geantă default y 1141b46c90cSHoria Geantă select CRYPTO_DEV_FSL_CAAM_CRYPTO_API_DESC 115b189817cSHoria Geantă select CRYPTO_AUTHENC 116b95bba5dSEric Biggers select CRYPTO_SKCIPHER 117836d8f43SIuliana Prodan select CRYPTO_DES 11883e8aa91SAndrei Botila select CRYPTO_XTS 119b189817cSHoria Geantă help 120b189817cSHoria Geantă Selecting this will use CAAM Queue Interface (QI) for sending 121b189817cSHoria Geantă & receiving crypto jobs to/from CAAM. This gives better performance 122b189817cSHoria Geantă than job ring interface when the number of cores are more than the 123b189817cSHoria Geantă number of job rings assigned to the kernel. The number of portals 124b189817cSHoria Geantă assigned to the kernel should also be more than the number of 125b189817cSHoria Geantă job rings. 126b189817cSHoria Geantă 127045e3678SYuan Kangconfig CRYPTO_DEV_FSL_CAAM_AHASH_API 1281b46c90cSHoria Geantă bool "Register hash algorithm implementations with Crypto API" 129045e3678SYuan Kang default y 1301b46c90cSHoria Geantă select CRYPTO_DEV_FSL_CAAM_AHASH_API_DESC 131ae8488a5SPaul Bolle select CRYPTO_HASH 132045e3678SYuan Kang help 133045e3678SYuan Kang Selecting this will offload ahash for users of the 134045e3678SYuan Kang scatterlist crypto API to the SEC4 via job ring. 135045e3678SYuan Kang 1368c419778STudor Ambarusconfig CRYPTO_DEV_FSL_CAAM_PKC_API 1371b46c90cSHoria Geantă bool "Register public key cryptography implementations with Crypto API" 1388c419778STudor Ambarus default y 1398c419778STudor Ambarus select CRYPTO_RSA 1408c419778STudor Ambarus help 1418c419778STudor Ambarus Selecting this will allow SEC Public key support for RSA. 1428c419778STudor Ambarus Supported cryptographic primitives: encryption, decryption, 1438c419778STudor Ambarus signature and verification. 1448c419778STudor Ambarus 145e24f7c9eSYuan Kangconfig CRYPTO_DEV_FSL_CAAM_RNG_API 1461b46c90cSHoria Geantă bool "Register caam device for hwrng API" 147e24f7c9eSYuan Kang default y 148e24f7c9eSYuan Kang select CRYPTO_RNG 149e24f7c9eSYuan Kang select HW_RANDOM 150e24f7c9eSYuan Kang help 151e24f7c9eSYuan Kang Selecting this will register the SEC4 hardware rng to 15224c7bf08SHeinrich Schuchardt the hw_random API for supplying the kernel entropy pool. 153e24f7c9eSYuan Kang 1540aa6ac77SMeenakshi Aggarwalconfig CRYPTO_DEV_FSL_CAAM_PRNG_API 1550aa6ac77SMeenakshi Aggarwal bool "Register Pseudo random number generation implementation with Crypto API" 1560aa6ac77SMeenakshi Aggarwal default y 1570aa6ac77SMeenakshi Aggarwal select CRYPTO_RNG 1580aa6ac77SMeenakshi Aggarwal help 1590aa6ac77SMeenakshi Aggarwal Selecting this will register the SEC hardware prng to 1600aa6ac77SMeenakshi Aggarwal the Crypto API. 1610aa6ac77SMeenakshi Aggarwal 162007c3ff1SAhmad Fatoumconfig CRYPTO_DEV_FSL_CAAM_BLOB_GEN 163007c3ff1SAhmad Fatoum bool 164007c3ff1SAhmad Fatoum 1652be0d806SVictoria Milhoan (b42089)config CRYPTO_DEV_FSL_CAAM_RNG_TEST 1662be0d806SVictoria Milhoan (b42089) bool "Test caam rng" 1672be0d806SVictoria Milhoan (b42089) select CRYPTO_DEV_FSL_CAAM_RNG_API 1682be0d806SVictoria Milhoan (b42089) help 1692be0d806SVictoria Milhoan (b42089) Selecting this will enable a self-test to run for the 1702be0d806SVictoria Milhoan (b42089) caam RNG. 1712be0d806SVictoria Milhoan (b42089) This test is several minutes long and executes 1722be0d806SVictoria Milhoan (b42089) just before the RNG is registered with the hw_random API. 1732be0d806SVictoria Milhoan (b42089) 1748d818c10SHoria Geantăendif # CRYPTO_DEV_FSL_CAAM_JR 1758d818c10SHoria Geantă 1768d818c10SHoria Geantăendif # CRYPTO_DEV_FSL_CAAM 1778d818c10SHoria Geantă 1788d818c10SHoria Geantăconfig CRYPTO_DEV_FSL_DPAA2_CAAM 1798d818c10SHoria Geantă tristate "QorIQ DPAA2 CAAM (DPSECI) driver" 1808d818c10SHoria Geantă depends on FSL_MC_DPIO 18196808c59SArnd Bergmann depends on NETDEVICES 1828d818c10SHoria Geantă select CRYPTO_DEV_FSL_CAAM_COMMON 1831b46c90cSHoria Geantă select CRYPTO_DEV_FSL_CAAM_CRYPTO_API_DESC 1841b46c90cSHoria Geantă select CRYPTO_DEV_FSL_CAAM_AHASH_API_DESC 185b95bba5dSEric Biggers select CRYPTO_SKCIPHER 1868d818c10SHoria Geantă select CRYPTO_AUTHENC 1878d818c10SHoria Geantă select CRYPTO_AEAD 1883f16f6c9SHoria Geantă select CRYPTO_HASH 189836d8f43SIuliana Prodan select CRYPTO_DES 19036e2d7cfSAndrei Botila select CRYPTO_XTS 191d4d8edf8SAlex Porosanu help 1928d818c10SHoria Geantă CAAM driver for QorIQ Data Path Acceleration Architecture 2. 1938d818c10SHoria Geantă It handles DPSECI DPAA2 objects that sit on the Management Complex 1948d818c10SHoria Geantă (MC) fsl-mc bus. 1958d818c10SHoria Geantă 1968d818c10SHoria Geantă To compile this as a module, choose M here: the module 1978d818c10SHoria Geantă will be called dpaa2_caam. 198