xref: /linux/drivers/crypto/caam/Kconfig (revision 8d818c1055013d355d36188f21c7535687374f6c)
1*8d818c10SHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_COMMON
2*8d818c10SHoria Geantă	tristate
3*8d818c10SHoria Geantă
48e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM
5*8d818c10SHoria Geantă	tristate "Freescale CAAM-Multicore platform driver backend"
69e217795SHoria Geantă	depends on FSL_SOC || ARCH_MXC || ARCH_LAYERSCAPE
7c056d910SHoria Geantă	select SOC_BUS
8*8d818c10SHoria Geantă	select CRYPTO_DEV_FSL_CAAM_COMMON
98e8ec596SKim Phillips	help
108e8ec596SKim Phillips	  Enables the driver module for Freescale's Cryptographic Accelerator
118e8ec596SKim Phillips	  and Assurance Module (CAAM), also known as the SEC version 4 (SEC4).
12313ea293SRuchika Gupta	  This module creates job ring devices, and configures h/w
138e8ec596SKim Phillips	  to operate as a DPAA component automatically, depending
148e8ec596SKim Phillips	  on h/w feature availability.
158e8ec596SKim Phillips
168e8ec596SKim Phillips	  To compile this driver as a module, choose M here: the module
178e8ec596SKim Phillips	  will be called caam.
188e8ec596SKim Phillips
19*8d818c10SHoria Geantăif CRYPTO_DEV_FSL_CAAM
20*8d818c10SHoria Geantă
21*8d818c10SHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_DEBUG
22*8d818c10SHoria Geantă	bool "Enable debug output in CAAM driver"
23*8d818c10SHoria Geantă	help
24*8d818c10SHoria Geantă	  Selecting this will enable printing of various debug
25*8d818c10SHoria Geantă	  information in the CAAM driver.
26*8d818c10SHoria Geantă
27313ea293SRuchika Guptaconfig CRYPTO_DEV_FSL_CAAM_JR
28313ea293SRuchika Gupta	tristate "Freescale CAAM Job Ring driver backend"
29313ea293SRuchika Gupta	default y
30313ea293SRuchika Gupta	help
31313ea293SRuchika Gupta	  Enables the driver module for Job Rings which are part of
32313ea293SRuchika Gupta	  Freescale's Cryptographic Accelerator
33313ea293SRuchika Gupta	  and Assurance Module (CAAM). This module adds a job ring operation
34313ea293SRuchika Gupta	  interface.
35313ea293SRuchika Gupta
36313ea293SRuchika Gupta	  To compile this driver as a module, choose M here: the module
37313ea293SRuchika Gupta	  will be called caam_jr.
38313ea293SRuchika Gupta
39*8d818c10SHoria Geantăif CRYPTO_DEV_FSL_CAAM_JR
40*8d818c10SHoria Geantă
418e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_RINGSIZE
428e8ec596SKim Phillips	int "Job Ring size"
438e8ec596SKim Phillips	range 2 9
448e8ec596SKim Phillips	default "9"
458e8ec596SKim Phillips	help
468e8ec596SKim Phillips	  Select size of Job Rings as a power of 2, within the
478e8ec596SKim Phillips	  range 2-9 (ring size 4-512).
488e8ec596SKim Phillips	  Examples:
498e8ec596SKim Phillips		2 => 4
508e8ec596SKim Phillips		3 => 8
518e8ec596SKim Phillips		4 => 16
528e8ec596SKim Phillips		5 => 32
538e8ec596SKim Phillips		6 => 64
548e8ec596SKim Phillips		7 => 128
558e8ec596SKim Phillips		8 => 256
568e8ec596SKim Phillips		9 => 512
578e8ec596SKim Phillips
588e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_INTC
598e8ec596SKim Phillips	bool "Job Ring interrupt coalescing"
608e8ec596SKim Phillips	help
618e8ec596SKim Phillips	  Enable the Job Ring's interrupt coalescing feature.
628e8ec596SKim Phillips
631a076689SKim Phillips	  Note: the driver already provides adequate
641a076689SKim Phillips	  interrupt coalescing in software.
651a076689SKim Phillips
668e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_INTC_COUNT_THLD
678e8ec596SKim Phillips	int "Job Ring interrupt coalescing count threshold"
688e8ec596SKim Phillips	depends on CRYPTO_DEV_FSL_CAAM_INTC
698e8ec596SKim Phillips	range 1 255
708e8ec596SKim Phillips	default 255
718e8ec596SKim Phillips	help
728e8ec596SKim Phillips	  Select number of descriptor completions to queue before
738e8ec596SKim Phillips	  raising an interrupt, in the range 1-255. Note that a selection
748e8ec596SKim Phillips	  of 1 functionally defeats the coalescing feature, and a selection
758e8ec596SKim Phillips	  equal or greater than the job ring size will force timeouts.
768e8ec596SKim Phillips
778e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_INTC_TIME_THLD
788e8ec596SKim Phillips	int "Job Ring interrupt coalescing timer threshold"
798e8ec596SKim Phillips	depends on CRYPTO_DEV_FSL_CAAM_INTC
808e8ec596SKim Phillips	range 1 65535
818e8ec596SKim Phillips	default 2048
828e8ec596SKim Phillips	help
838e8ec596SKim Phillips	  Select number of bus clocks/64 to timeout in the case that one or
848e8ec596SKim Phillips	  more descriptor completions are queued without reaching the count
858e8ec596SKim Phillips	  threshold. Range is 1-65535.
868e8ec596SKim Phillips
878e8ec596SKim Phillipsconfig CRYPTO_DEV_FSL_CAAM_CRYPTO_API
888e8ec596SKim Phillips	tristate "Register algorithm implementations with the Crypto API"
898e8ec596SKim Phillips	default y
90596103cfSHerbert Xu	select CRYPTO_AEAD
918e8ec596SKim Phillips	select CRYPTO_AUTHENC
92596103cfSHerbert Xu	select CRYPTO_BLKCIPHER
938e8ec596SKim Phillips	help
948e8ec596SKim Phillips	  Selecting this will offload crypto for users of the
958e8ec596SKim Phillips	  scatterlist crypto API (such as the linux native IPSec
968e8ec596SKim Phillips	  stack) to the SEC4 via job ring.
978e8ec596SKim Phillips
988e8ec596SKim Phillips	  To compile this as a module, choose M here: the module
998e8ec596SKim Phillips	  will be called caamalg.
100045e3678SYuan Kang
101b189817cSHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_CRYPTO_API_QI
102b189817cSHoria Geantă	tristate "Queue Interface as Crypto API backend"
103*8d818c10SHoria Geantă	depends on FSL_DPAA && NET
104b189817cSHoria Geantă	default y
105b189817cSHoria Geantă	select CRYPTO_AUTHENC
106b189817cSHoria Geantă	select CRYPTO_BLKCIPHER
107b189817cSHoria Geantă	help
108b189817cSHoria Geantă	  Selecting this will use CAAM Queue Interface (QI) for sending
109b189817cSHoria Geantă	  & receiving crypto jobs to/from CAAM. This gives better performance
110b189817cSHoria Geantă	  than job ring interface when the number of cores are more than the
111b189817cSHoria Geantă	  number of job rings assigned to the kernel. The number of portals
112b189817cSHoria Geantă	  assigned to the kernel should also be more than the number of
113b189817cSHoria Geantă	  job rings.
114b189817cSHoria Geantă
115b189817cSHoria Geantă	  To compile this as a module, choose M here: the module
116b189817cSHoria Geantă	  will be called caamalg_qi.
117b189817cSHoria Geantă
118045e3678SYuan Kangconfig CRYPTO_DEV_FSL_CAAM_AHASH_API
119045e3678SYuan Kang	tristate "Register hash algorithm implementations with Crypto API"
120045e3678SYuan Kang	default y
121ae8488a5SPaul Bolle	select CRYPTO_HASH
122045e3678SYuan Kang	help
123045e3678SYuan Kang	  Selecting this will offload ahash for users of the
124045e3678SYuan Kang	  scatterlist crypto API to the SEC4 via job ring.
125045e3678SYuan Kang
126045e3678SYuan Kang	  To compile this as a module, choose M here: the module
127045e3678SYuan Kang	  will be called caamhash.
128e24f7c9eSYuan Kang
1298c419778STudor Ambarusconfig CRYPTO_DEV_FSL_CAAM_PKC_API
1308c419778STudor Ambarus        tristate "Register public key cryptography implementations with Crypto API"
1318c419778STudor Ambarus        default y
1328c419778STudor Ambarus        select CRYPTO_RSA
1338c419778STudor Ambarus        help
1348c419778STudor Ambarus          Selecting this will allow SEC Public key support for RSA.
1358c419778STudor Ambarus          Supported cryptographic primitives: encryption, decryption,
1368c419778STudor Ambarus          signature and verification.
1378c419778STudor Ambarus          To compile this as a module, choose M here: the module
1388c419778STudor Ambarus          will be called caam_pkc.
1398c419778STudor Ambarus
140e24f7c9eSYuan Kangconfig CRYPTO_DEV_FSL_CAAM_RNG_API
141e24f7c9eSYuan Kang	tristate "Register caam device for hwrng API"
142e24f7c9eSYuan Kang	default y
143e24f7c9eSYuan Kang	select CRYPTO_RNG
144e24f7c9eSYuan Kang	select HW_RANDOM
145e24f7c9eSYuan Kang	help
146e24f7c9eSYuan Kang	  Selecting this will register the SEC4 hardware rng to
147e24f7c9eSYuan Kang	  the hw_random API for suppying the kernel entropy pool.
148e24f7c9eSYuan Kang
149e24f7c9eSYuan Kang	  To compile this as a module, choose M here: the module
150e24f7c9eSYuan Kang	  will be called caamrng.
151d4d8edf8SAlex Porosanu
152*8d818c10SHoria Geantăendif # CRYPTO_DEV_FSL_CAAM_JR
153*8d818c10SHoria Geantă
154*8d818c10SHoria Geantăendif # CRYPTO_DEV_FSL_CAAM
155*8d818c10SHoria Geantă
156*8d818c10SHoria Geantăconfig CRYPTO_DEV_FSL_DPAA2_CAAM
157*8d818c10SHoria Geantă	tristate "QorIQ DPAA2 CAAM (DPSECI) driver"
158*8d818c10SHoria Geantă	depends on FSL_MC_DPIO
159*8d818c10SHoria Geantă	select CRYPTO_DEV_FSL_CAAM_COMMON
160*8d818c10SHoria Geantă	select CRYPTO_AUTHENC
161*8d818c10SHoria Geantă	select CRYPTO_AEAD
162d4d8edf8SAlex Porosanu	help
163*8d818c10SHoria Geantă	  CAAM driver for QorIQ Data Path Acceleration Architecture 2.
164*8d818c10SHoria Geantă	  It handles DPSECI DPAA2 objects that sit on the Management Complex
165*8d818c10SHoria Geantă	  (MC) fsl-mc bus.
166*8d818c10SHoria Geantă
167*8d818c10SHoria Geantă	  To compile this as a module, choose M here: the module
168*8d818c10SHoria Geantă	  will be called dpaa2_caam.
1698cea7b66SHoria Geantă
1708cea7b66SHoria Geantăconfig CRYPTO_DEV_FSL_CAAM_CRYPTO_API_DESC
171b189817cSHoria Geantă	def_tristate (CRYPTO_DEV_FSL_CAAM_CRYPTO_API || \
172*8d818c10SHoria Geantă		      CRYPTO_DEV_FSL_CAAM_CRYPTO_API_QI || \
173*8d818c10SHoria Geantă		      CRYPTO_DEV_FSL_DPAA2_CAAM)
174