summaryrefslogtreecommitdiffstats
path: root/drivers/crypto
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'linus' of ↵Linus Torvalds2016-01-1284-1531/+6420
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 Pull crypto update from Herbert Xu: "Algorithms: - Add RSA padding algorithm Drivers: - Add GCM mode support to atmel - Add atmel support for SAMA5D2 devices - Add cipher modes to talitos - Add rockchip driver for rk3288 - Add qat support for C3XXX and C62X" * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (103 commits) crypto: hifn_795x, picoxcell - use ablkcipher_request_cast crypto: qat - fix SKU definiftion for c3xxx dev crypto: qat - Fix random config build issue crypto: ccp - use to_pci_dev and to_platform_device crypto: qat - Rename dh895xcc mmp firmware crypto: 842 - remove WARN inside printk crypto: atmel-aes - add debug facilities to monitor register accesses. crypto: atmel-aes - add support to GCM mode crypto: atmel-aes - change the DMA threshold crypto: atmel-aes - fix the counter overflow in CTR mode crypto: atmel-aes - fix atmel-ctr-aes driver for RFC 3686 crypto: atmel-aes - create sections to regroup functions by usage crypto: atmel-aes - fix typo and indentation crypto: atmel-aes - use SIZE_IN_WORDS() helper macro crypto: atmel-aes - improve performances of data transfer crypto: atmel-aes - fix atmel_aes_remove() crypto: atmel-aes - remove useless AES_FLAGS_DMA flag crypto: atmel-aes - reduce latency of DMA completion crypto: atmel-aes - remove unused 'err' member of struct atmel_aes_dev crypto: atmel-aes - rework crypto request completion ...
| * crypto: hifn_795x, picoxcell - use ablkcipher_request_castGeliang Tang2015-12-292-4/+3
| | | | | | | | | | | | | | Use ablkcipher_request_cast() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@163.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - fix SKU definiftion for c3xxx devTadeusz Struk2015-12-252-19/+8
| | | | | | | | | | | | | | c3xxx doesn't have the esram BAR and only has 6 ue. Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - Fix random config build issueTadeusz Struk2015-12-251-2/+10
| | | | | | | | | | | | Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: ccp - use to_pci_dev and to_platform_deviceGeliang Tang2015-12-252-8/+6
| | | | | | | | | | | | | | Use to_pci_dev() and to_platform_device() instead of open-coding. Signed-off-by: Geliang Tang <geliangtang@163.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - Rename dh895xcc mmp firmwareAhsan Atta2015-12-251-1/+1
| | | | | | | | | | | | | | | | | | | | Resending again. The fw name suppoed to be 895xcc instead of 895xxcc. Sorry for the noise. Rename dh895xcc mmp fw to make it consistent with other mmp images. Signed-off-by: Ahsan Atta <ahsan.atta@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - add debug facilities to monitor register accesses.Cyrille Pitchen2015-12-231-1/+114
| | | | | | | | | | | | | | | | | | | | This feature should not be enabled in release but can be usefull for developers who need to monitor register accesses at some specific places. Set the AES_FLAGS_DUMP_REG flag inside dd->flags to start monitoring the I/O accesses, clear it to stop monitoring. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - add support to GCM modeCyrille Pitchen2015-12-233-2/+462
| | | | | | | | | | | | | | This patch adds support to the GCM mode. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - change the DMA thresholdCyrille Pitchen2015-12-231-1/+1
| | | | | | | | | | | | | | | | Increase the DMA threshold to 256: PIO accesses offer better performances than the DMA when processing small amounts of data. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - fix the counter overflow in CTR modeCyrille Pitchen2015-12-231-2/+115
| | | | | | | | | | | | | | | | | | | | Depending on its hardware version, the AES IP provides either a 16 or a 32 bit counter. However the CTR mode expects the size of the counter to be the same as the size of the cipher block, ie 128 bits for AES. This patch detects and handles counter overflows. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - fix atmel-ctr-aes driver for RFC 3686Cyrille Pitchen2015-12-231-1/+1
| | | | | | | | | | | | | | | | crypto_rfc3686_alloc() in crypto/ctr.c expects to be used with a stream cipher (alg->cra_blocksize == 1). Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - create sections to regroup functions by usageCyrille Pitchen2015-12-231-102/+108
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch only creates sections to regroup functions by usage. This will help to integrate the GCM support patch later by making the difference between shared/common and specific code. Hence current sections are: - Shared functions: common code which will be reused by the GCM support. - CPU transfer: handles transfers monitored by the CPU (PIO accesses). - DMA transfer: handles transfers monitored by the DMA controller. - AES async block ciphers: dedicated to the already supported block ciphers - Probe functions: used to register all crypto algorithms. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - fix typo and indentationCyrille Pitchen2015-12-231-31/+25
| | | | | | | | | | | | | | Dummy patch to fix typo and indentation. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - use SIZE_IN_WORDS() helper macroCyrille Pitchen2015-12-231-2/+2
| | | | | | | | | | | | | | This is a dummy cosmetic patch. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - improve performances of data transferCyrille Pitchen2015-12-231-378/+386
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch totally reworks data transfer. 1 - DMA The new code now fully supports scatter-gather lists hence reducing the number of interrupts in some cases. Also buffer alignments are better managed to avoid useless copies. 2 - CPU The new code allows to use PIO accesses even when transferring more than one AES block, so futher patches could tune the DMA threshold (ATMEL_AES_DMA_THRESHOLD). Moreover, CPU transfers now have a chance to be processed synchronously, hence reducing the latency by avoiding context switches when possible (less interrupts to process, less scheduling of the 'done' task). Indeed the 'DATA READY' bit is polled only one time in the Interrupt Status Register before enabling then waiting for the associated interrupt. In some condition, this single poll is enough as the data have already been processed by the AES hardware and so are ready. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - fix atmel_aes_remove()Cyrille Pitchen2015-12-231-0/+1
| | | | | | | | | | | | | | Add missing call to atmel_aes_buff_cleanup(). Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - remove useless AES_FLAGS_DMA flagCyrille Pitchen2015-12-231-22/+15
| | | | | | | | | | | | | | | | Since the 'done' task code was split into atmel_aes_cpu_complete() and atmel_aes_dma_complete(), the AES_FLAGS_DMA flag has become useless. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - reduce latency of DMA completionCyrille Pitchen2015-12-231-2/+2
| | | | | | | | | | | | | | | | | | atmel_aes_dma_callback() now directly calls the 'resume' callback instead of scheduling the done task, which in turn only calls the very same 'resume' callback. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - remove unused 'err' member of struct atmel_aes_devCyrille Pitchen2015-12-231-5/+0
| | | | | | | | | | | | | | This 'err' member was initialized to 0 but its value never changed. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - rework crypto request completionCyrille Pitchen2015-12-231-27/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch introduces a new callback 'resume' in the struct atmel_aes_dev. This callback is run to resume/complete the processing of the crypto request when woken up by I/O events such as AES interrupts or DMA completion. This callback will help implementing the GCM mode support in further patches. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - simplify the configuration of the AES IPCyrille Pitchen2015-12-231-123/+93
| | | | | | | | | | | | | | | | This patch reworks the AES_FLAGS_* to simplify the configuration of the AES IP. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - remove useless write in the Control RegisterCyrille Pitchen2015-12-231-2/+1
| | | | | | | | | | | | | | | | As claimed by the datasheet, writing 0 into the Control Register has no effet. So we remove this useless register access. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - make crypto request queue management more genericCyrille Pitchen2015-12-231-26/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch changes atmel_aes_handle_queue() to make it more generic. The function argument is now a pointer to struct crypto_async_request, which is the common base of struct ablkcipher_request and struct aead_request. Also this patch introduces struct atmel_aes_base_ctx which will be the common base of all the transformation contexts. Hence the very same queue will be used to manage both block cipher and AEAD requests (such as gcm and authenc implemented in further patches). Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - change atmel_aes_write_ctrl() signatureCyrille Pitchen2015-12-231-14/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch changes the signature of atmel_aes_write_ctrl() to make it more generic. This will be used by future patches when implementing new block cipher modes such as GCM. Especially atmel_aes_hw_init() is now called outside atmel_aes_write_ctrl(): this allows to call atmel_aes_write_ctrl() many times, still initializing the hardware only once. Indeed, the support of GCM will require to update the Mode Register and the IV when processing a single request. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - propagate error from atmel_aes_hw_version_init()Cyrille Pitchen2015-12-231-5/+11
| | | | | | | | | | | | | | | | | | Before this patch atmel_aes_hw_version_init() had no returned value. However it calls atmel_aes_hw_init(), which may fail. So check the returned code of atmel_aes_hw_init() and propagate error if needed. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - remove unused header includesCyrille Pitchen2015-12-231-3/+0
| | | | | | | | | | | | | | Hash headers have nothing to do with AES block ciphers. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - fix unregistration order of crypto algorithmsCyrille Pitchen2015-12-231-2/+3
| | | | | | | | | | | | | | | | | | This dummy patch fixes atmel_aes_unregister_algs() so crypto algorithms are unregistered in the reverse order they were registered by atmel_aes_register_algs(). Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - change algorithm prioritiesCyrille Pitchen2015-12-231-9/+11
| | | | | | | | | | | | | | | | | | Increase the algorithm priorities so the hardware acceleration is now preferred to the software computation: the "aes-generice" driver uses 100 as priority. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - constify value argument of atmel_aes_write_n()Cyrille Pitchen2015-12-231-1/+1
| | | | | | | | | | | | | | atmel_aes_write_n() should not modify its value argument. Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-aes - add new versionLeilei Zhao2015-12-231-0/+5
| | | | | | | | | | | | | | Add new version of atmel-aes available with SAMA5D2 devices. Signed-off-by: Leilei Zhao <leilei.zhao@atmel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - use list_for_each_entry*Geliang Tang2015-12-222-29/+12
| | | | | | | | | | | | | | | | Use list_for_each_entry*() instead of list_for_each*() to simplify the code. Signed-off-by: Geliang Tang <geliangtang@163.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: ux500 - Use precalculated hash from headersLABBE Corentin2015-12-222-18/+4
| | | | | | | | | | | | | | | | Precalculated hash for empty message are now present in hash headers. This patch just use them. Signed-off-by: LABBE Corentin <clabbe.montjoie@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: ccp - Use precalculated hash from headersLABBE Corentin2015-12-222-31/+10
| | | | | | | | | | | | | | | | | | | | Precalculated hash for empty message are now present in hash headers. This patch just use them. Signed-off-by: LABBE Corentin <clabbe.montjoie@gmail.com> Tested-by: Tom Lendacky <thomas.lendacky@amd.com> Acked-by: Tom Lendacky <thomas.lendacky@amd.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: n2 - Use precalculated hash from headersLABBE Corentin2015-12-222-27/+9
| | | | | | | | | | | | | | | | Precalculated hash for empty message are now present in hash headers. This patch just use them. Signed-off-by: LABBE Corentin <clabbe.montjoie@gmail.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - fix some timeout testsPingchao Yang2015-12-221-1/+1
| | | | | | | | | | | | | | | | | | Change the timeout condition since the times value would be -1 after running MAX_RETRY_TIMES. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Yang Pingchao <pingchao.yang@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - fix CTX_ENABLES bits shift direction issuePingchao Yang2015-12-221-1/+1
| | | | | | | | | | | | | | | | | | AE CTX bits should be 8-15 in CTX_ENABLES, so the mask value 0xff should be left shifted 0x8. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Yang Pingchao <pingchao.yang@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: omap - Removed unused variable "err"Rahul Pathak2015-12-172-6/+2
| | | | | | | | | | | | | | | | | | | | | | Removed unused variable "err" and directly return "0" Reported by coccicheck - ./drivers/crypto/omap-aes.c:542:5-8: Unneeded variable: "err". Return "0" on line 551 ./drivers/crypto/omap-des.c:530:5-8: Unneeded variable: "err". Return "0" on line 539 Signed-off-by: Rahul Pathak <rpathak@visteon.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: atmel-sha - Removed unused variable "err"Rahul Pathak2015-12-171-2/+1
| | | | | | | | | | | | | | | | | | | | Removed unused variable "err" and directly return "0" Reported by coccicheck - ./drivers/crypto/atmel-sha.c:758:5-8: Unneeded variable: "err". Return "0" on line 766 Signed-off-by: Rahul Pathak <rpathak@visteon.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: nx-842 - Mask XERS0 bit in return valueHaren Myneni2015-12-171-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | NX842 coprocessor sets 3rd bit in CR register with XER[S0] which is nothing to do with NX request. Since this bit can be set with other valuable return status, mast this bit. One of other bits (INITIATED, BUSY or REJECTED) will be returned for any given NX request. Signed-off-by: Haren Myneni <haren@us.ibm.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - uint8_t is not large enough for accel_idTadeusz Struk2015-12-142-3/+3
| | | | | | | | | | | | | | | | | | accel_id has to be large enough to hold ADF_MAX_DEVICES + 1 (which is > 1025) so uint8_t is too small. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: omap-des - Fix "schedule while atomic" bugSam Protsenko2015-12-141-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using DES module the next bug appears: BUG: scheduling while atomic: kworker/0:1/63/0x00000102 With backtrace as follows: <<<<<<<<<<<<<<<<<<<<<<<<<<<<<< cut here >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> [<c0012294>] (dump_backtrace) from [<c00124ac>] (show_stack+0x18/0x1c) [<c0012494>] (show_stack) from [<c0752554>] (dump_stack+0x84/0xc4) [<c07524d0>] (dump_stack) from [<c0750218>] (__schedule_bug+0x54/0x64) [<c07501c4>] (__schedule_bug) from [<c07548a4>] (__schedule+0x4ac/0x53c) [<c07543f8>] (__schedule) from [<c075496c>] (schedule+0x38/0x88) [<c0754934>] (schedule) from [<c03c3984>] (rpm_resume+0x158/0x59c) [<c03c382c>] (rpm_resume) from [<c03c3e1c>] (__pm_runtime_resume+0x54/0x6c) [<c03c3dc8>] (__pm_runtime_resume) from [<c0568ff8>] (omap_des_handle_queue+0x154/0x7bc) [<c0568ea4>] (omap_des_handle_queue) from [<c05696b8>] (omap_des_crypt+0x58/0xbc) [<c0569660>] (omap_des_crypt) from [<c0569730>] (omap_des_cbc_decrypt+0x14/0x18) [<c056971c>] (omap_des_cbc_decrypt) from [<c0297534>] (authenc_verify_ahash_done+0xe0/0xe8) [<c0297454>] (authenc_verify_ahash_done) from [<c056a330>] (omap_sham_finish_req+0x58/0xa8) [<c056a2d8>] (omap_sham_finish_req) from [<c056b714>] (omap_sham_done_task+0x1c0/0x1e0) [<c056b554>] (omap_sham_done_task) from [<c003e53c>] (tasklet_action+0x80/0x118) [<c003e4bc>] (tasklet_action) from [<c003e740>] (__do_softirq+0x11c/0x260) [<c003e624>] (__do_softirq) from [<c003eb64>] (irq_exit+0xc0/0xfc) [<c003eaa4>] (irq_exit) from [<c000f1c4>] (handle_IRQ+0x4c/0x98) [<c000f178>] (handle_IRQ) from [<c0008568>] (gic_handle_irq+0x34/0x64) [<c0008534>] (gic_handle_irq) from [<c0758540>] (__irq_svc+0x40/0x70) <<<<<<<<<<<<<<<<<<<<<<<<<<<<<< cut here >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Insight was seen in drivers/crypto/omap-sham.c driver. All credits for this patch go to Grygorii Strashko. Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - enable VF irq after guest exits ungracefullyZeng Xin2015-12-142-1/+7
| | | | | | | | | | | | | | | | | | | | | | The VF bundle interrupt is not triggered any more in the case when guest is shut down with sample app running. Need to clear the flag interrupt bit when restarting to fix this irrecoverable state. Signed-off-by: Zeng Xin <xin.zeng@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - select PCI_IOV when VF are enabledTadeusz Struk2015-12-111-0/+2
| | | | | | | | | | | | | | | | | | Fix i386-randconfig-x004-12092241. PCI_IOV needs to be selected when VFs are enabled Reported-by: <fengguang.wu@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - ring returning retry even though ring has BWHarvijay Saini2015-12-111-3/+2
| | | | | | | | | | | | | | | | | | | | | | When many threads submit multiple requests they get blocked until all responses are processed, which prevents them from submitting more requests even though there is space on the rings. To fix this we need to decrement the inflight counter early to in the callback. Signed-off-by: Harvijay Saini <harvijayx.saini@intel.com> Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: sahara - fix debug output for 64-bit dma_addr_tArnd Bergmann2015-12-101-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The sahara_dump_descriptors and sahara_dump_links functions attempt to print a dma_addr_t value with a 0x%08x format string, which produces a warning when dma_addr_t is 64-bit wide: drivers/crypto/sahara.c:419:120: warning: format '%x' expects argument of type 'unsigned int', but argument 5 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=] This changes the code to use the %pad format string that is meant for dma_addr_t, which avoids the warning and gives us the correct output in all configurations. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: sahara - fix 64-bit dma_addr_t compilationArnd Bergmann2015-12-101-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The sahara hardware uses DMA descriptors with 32-bit addresses, but dma_addr_t is variable size depending on whether we want to support any devices that use 64-bit DMA addresses in hardware. This means that the definition of the DMA descriptor structure is wrong, and we helpfully get a compiler warning about them too: drivers/crypto/sahara.c:423:372: warning: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=] This changes the definition of the sahara_hw_desc and sahara_hw_link structures to only contain fixed-length members, which is required to make the driver work on ARM LPAE mode, and avoids most of the gcc warnings we get. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - add support for c62xvf accel typeTadeusz Struk2015-12-097-0/+558
| | | | | | | | | | | | | | Add support for c62x accelerator Virtual Function Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - add support for c3xxxvf accel typeTadeusz Struk2015-12-097-1/+559
| | | | | | | | | | | | | | Add support for c3xxx accelerator Virtual Function Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - add support for c62x accel typeTadeusz Struk2015-12-097-0/+683
| | | | | | | | | | | | | | Add support for qat c62x accel type Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
| * crypto: qat - add support for c3xxx accel typeTadeusz Struk2015-12-098-5/+714
| | | | | | | | | | | | | | Add support for c3xxx accel type. Signed-off-by: Tadeusz Struk <tadeusz.struk@intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
OpenPOWER on IntegriCloud