1.
For CAAM, please use the patches, available on Freescales public GIT server at the following link:
http://git.freescale.com/git/cgit.cgi/imx/linux-2.6-imx.git/log/?h=imx_3.0.35_4.0.0
Direct link to the patches:
http://git.freescale.com/git/cgit.cgi/imx/linux-2.6-imx.git/commit/?h=imx_3.0.35_4.0.0&id=6068d7a77b2101c172fc2f003f90b1febbf99505
http://git.freescale.com/git/cgit.cgi/imx/linux-2.6-imx.git/commit/?h=imx_3.0.35_4.0.0&id=b30237c79003223c6e8035d5be183cd4f0b469f9
2.
As known, the AF_ALG family provides the user-space interface for the kernel crypto API. While a kernel (2.6.38 and later)
supports the AF_ALG socket interface, various third-party cryptodev implementations are also available.
Here are some links to a couple of starting points:
http://carnivore.it/2011/04/23/openssl_-_af_alg
http://home.gna.org/cryptodev-linux/
http://ocf-linux.sourceforge.net/
The enclosed is implementaion from Dipen Patel.