crypto: omap-sham - split up data to multiple sg elements with huge data
authorTero Kristo <t-kristo@ti.com>
Tue, 5 Nov 2019 14:00:50 +0000 (16:00 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 11 Dec 2019 08:36:57 +0000 (16:36 +0800)
commit462519fc26996a619f7c9cc5f5a34a73934219b9
treee4c519526b17ed5d46ba759429af73ea5086ab8e
parentc28817895464797a8299b24e35ead1085b3e40fb
crypto: omap-sham - split up data to multiple sg elements with huge data

When using huge data amount, allocating free pages fails as the kernel
isn't able to process get_free_page requests larger than MAX_ORDER.
Also, the DMA subsystem has an inherent limitation that data size
larger than some 2MB can't be handled properly. In these cases,
split up the data instead to smaller requests so that the kernel
can allocate the data, and also so that the DMA driver can handle
the separate SG elements.

Signed-off-by: Tero Kristo <t-kristo@ti.com>
Tested-by: Bin Liu <b-liu@ti.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/omap-sham.c