]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: nx - fix limits to sg lists for AES-CBC
authorMarcelo Cerri <mhcerri@linux.vnet.ibm.com>
Thu, 29 Aug 2013 14:36:33 +0000 (11:36 -0300)
committerHerbert Xu <herbert@gondor.apana.org.au>
Mon, 2 Sep 2013 10:32:53 +0000 (20:32 +1000)
commit905cd7fc9bc9680c149fd5f6fb69d3a0a8b734c2
tree43bc3d83543d27b436e128ae3452084e367be0e0
parent9be1a559eec15cc00a7dd188eb686fdc210bd1c4
crypto: nx - fix limits to sg lists for AES-CBC

This patch updates the nx-aes-cbc implementation to perform several
hyper calls if needed in order to always respect the length limits for
scatter/gather lists.

Two different limits are considered:

 - "ibm,max-sg-len": maximum number of bytes of each scatter/gather
   list.

 - "ibm,max-sync-cop":
    - The total number of bytes that a scatter/gather list can hold.
    - The maximum number of elements that a scatter/gather list can have.

Reviewed-by: Joy Latten <jmlatten@linux.vnet.ibm.com>
Signed-off-by: Marcelo Cerri <mhcerri@linux.vnet.ibm.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/nx/nx-aes-cbc.c