Re: Is CAAM is by default enable?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Re: Is CAAM is by default enable?

765 Views
deven_solanki
Contributor III

Thanks Yuri for quick response.

But my doubt is, if we will not do # modprobe cryptodev ,then it means that it will not use hardware acceleration? 

If yes then why we are not building as inbuilt module ?

And When hardware acceleration is used by processor? , can you give any example.

0 Kudos
Reply
3 Replies

539 Views
Yuri
NXP Employee
NXP Employee
0 Kudos
Reply

539 Views
Yuri
NXP Employee
NXP Employee

Hello,

   From section 50.7 (Limitations) of i.MX Linux® Reference Manual, Rev. 0, 03/2016 :

• Components of the driver do not currently build and run as modules. This may be
rectified in a future version.

  From section 9 (Security) of i.MX Linux® User's Guide , Rev. L4.1.15_1.0.0-ga, 03/2016 :


Using the Freescale CryptoDev security driver causes the system to run much faster than without it.
The CAAM drivers are accelerated through the CryptoDev interface. The openssl command can be used to show the system speed without CryptoDev .

openssl speed -evp aes-128-cbc -engine cryptodev

An example of the key portion of the output is as follows. Library load errors may occur but they can be ignored.
Doing aes-128-cbc for 3s on 16 size blocks: 4177732 aes-128-cbc's in 2.99s
Doing aes-128-cbc for 3s on 64 size blocks: 1149097 aes-128-cbc's in 3.01s
Doing aes-128-cbc for 3s on 256 size blocks: 297714 aes-128-cbc's in 3.00s
Doing aes-128-cbc for 3s on 1024 size blocks: 75118 aes-128-cbc's in 3.00s
Doing aes-128-cbc for 3s on 8192 size blocks: 9414 aes-128-cbc's in 3.00s

Start CryptoDev and run the openssl command again. This time you should be able to see that the timeing values show the
accelerated values. As the block sizes increase, the elapsed time decreases.

modprobe cryptodev
openssl speed -evp aes-128-cbc -engine cryptodev

Here is an example of the accelerated output

Doing aes-128-cbc for 3s on 16 size blocks: 36915 aes-128-cbc's in 0.10s
Doing aes-128-cbc for 3s on 64 size blocks: 34651 aes-128-cbc's in 0.05s
Doing aes-128-cbc for 3s on 256 size blocks: 25926 aes-128-cbc's in 0.10s
Doing aes-128-cbc for 3s on 1024 size blocks: 20274 aes-128-cbc's in 0.04s
Doing aes-128-cbc for 3s on 8192 size blocks: 5656 aes-128-cbc's in 0.02s

Have a great day,
Yuri

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply

539 Views
deven_solanki
Contributor III

Thank you very much for clear my doubt Yuri.

0 Kudos
Reply