- 22 1月, 2020 20 次提交
-
-
由 Colin Ian King 提交于
There is a spelling mistake in an error message. Fix it. Signed-off-by: NColin Ian King <colin.king@canonical.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Jason A. Donenfeld 提交于
When this was originally ported, the 12-byte nonce vectors were left out to keep things simple. I agree that we don't need nor want a library interface for 12-byte nonces. But these test vectors were specially crafted to look at issues in the underlying primitives and related interactions. Therefore, we actually want to keep around all of the test vectors, and simply have a helper function to test them with. Secondly, the sglist-based chunking code in the library interface is rather complicated, so this adds a developer-only test for ensuring that all the book keeping is correct, across a wide array of possibilities. Signed-off-by: NJason A. Donenfeld <Jason@zx2c4.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Jason A. Donenfeld 提交于
Admist the kbuild robot induced changes, the .gitignore file for the generated file wasn't updated with the non-clashing filename. This commit adjusts that. Signed-off-by: NJason A. Donenfeld <Jason@zx2c4.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Colin Ian King 提交于
Currently the memory allocation failure checks on drv_data and amdtee are using IS_ERR rather than checking for a null pointer. Fix these checks to use the conventional null pointer check. Addresses-Coverity: ("Dereference null return") Fixes: 757cc3e9 ("tee: add AMD-TEE driver") Signed-off-by: NColin Ian King <colin.king@canonical.com> Reviewed-by: NRijo Thomas <Rijo-john.Thomas@amd.com> Acked-by: NJens Wiklander <jens.wiklander@linaro.org> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Gilad Ben-Yossef 提交于
These inline versions of PM function for the case of CONFIG_PM is not set are never used. Erase them. Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Gilad Ben-Yossef 提交于
cc_pm_put_suspend() return value was never checked and is not useful. Turn it into a void functions. Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Gilad Ben-Yossef 提交于
We were using the irq field of the drvdata struct in an overloaded fahsion - saving the IRQ number during init and then storing the pending itnerrupt sources during interrupt in the same field. This worked because these usage are mutually exclusive but are confusing. So simplify the code and change the init use case to use a simple local variable. Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Gilad Ben-Yossef 提交于
The PM code was racy, possibly causing the driver to submit requests to a powered down device. Fix the race and while at it simplify the PM code. Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com> Fixes: 1358c13a ("crypto: ccree - fix resume race condition on init") Cc: stable@kernel.org # v4.20 Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Ofir Drang 提交于
In FDE mode (xts, essiv and bitlocker) the cryptocell hardware requires that the the XEX key will be loaded after Key1. Signed-off-by: NOfir Drang <ofir.drang@arm.com> Cc: stable@vger.kernel.org Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Gilad Ben-Yossef 提交于
cc_do_send_request() cannot fail and always returns -EINPROGRESS. Turn it into a void function and simplify code. Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Gilad Ben-Yossef 提交于
pm_runtime_get_sync() can return 1 as a valid (none error) return code. Treat it as such. Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com> Cc: stable@vger.kernel.org # v4.19+ Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Gilad Ben-Yossef 提交于
We have several loud error log messages that are already reported via the normal return code mechanism and produce a lot of noise when the new testmgr extra test are enabled. Turn these into debug only messages Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Gilad Ben-Yossef 提交于
On AEAD decryption authentication failure we are suppose to zero out the output plaintext buffer. However, we've missed skipping the optional associated data that may prefix the ciphertext. This commit fixes this issue. Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com> Fixes: e88b27c8 ("crypto: ccree - use std api sg_zero_buffer") Cc: stable@vger.kernel.org Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Hadar Gat 提交于
Fixed a typo in a commnet. Signed-off-by: NHadar Gat <hadar.gat@arm.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Hadar Gat 提交于
Fixed typos in ccree error msgs. Signed-off-by: NHadar Gat <hadar.gat@arm.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Tudor Ambarus 提交于
These drivers no longer need it as they are only probed via DT. crypto_platform_data was allocated but unused, so remove it. This is a follow up for: commit 45a536e3 ("crypto: atmel-tdes - Retire dma_request_slave_channel_compat()") commit db28512f ("crypto: atmel-sha - Retire dma_request_slave_channel_compat()") commit 62f72cbd ("crypto: atmel-aes - Retire dma_request_slave_channel_compat()") Signed-off-by: NTudor Ambarus <tudor.ambarus@microchip.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Kees Cook 提交于
In order to avoid CFI function prototype mismatches, this removes the casts on assembly implementations of sha1/256/512 accelerators. The safety checks from BUILD_BUG_ON() remain. Additionally, this renames various arguments for clarity, as suggested by Eric Biggers. Signed-off-by: NKees Cook <keescook@chromium.org> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Vinay Kumar Yadav 提交于
Do not return error when max stid reached, to Fallback to nic mode. Signed-off-by: NVinay Kumar Yadav <vinay.yadav@chelsio.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Vinay Kumar Yadav 提交于
corrected function call context and moved t4_defer_reply to apropriate location. Signed-off-by: NVinay Kumar Yadav <vinay.yadav@chelsio.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Horia Geantă 提交于
Fixes: 8d818c10 ("crypto: caam/qi2 - add DPAA2-CAAM driver") Signed-off-by: NHoria Geantă <horia.geanta@nxp.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
- 16 1月, 2020 20 次提交
-
-
由 Geert Uytterhoeven 提交于
"AEAD" is capitalized everywhere else. Use "an" when followed by a written or spoken vowel. Fixes: be1eb7f7 ("crypto: essiv - create wrapper template for ESSIV generation") Signed-off-by: NGeert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
This branch prediction macro on the hot path can improve small performance(about 2%) according to the test. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
Reorder the input parameters of hpre_crt_para_get to make it cleaner. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
1.Use memzero_explicit to clear key; 2.Fix some little endian writings; 3.Fix some other bugs and stuff of code style; Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
1.Fixed the bug of software tfm leakage. 2.Update HW error log message. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
authenc(hmac(sha1),cbc(aes)), authenc(hmac(sha256),cbc(aes)), and authenc(hmac(sha512),cbc(aes)) support are added for SEC v2. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
1.Define base initiation of QP for context which can be reused. 2.Define cipher initiation for other algorithms. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
After adding branch prediction for skcipher hot path, a little bit income of performance is gotten. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
Add error type parameter for call back checking inside. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
1.Adjust call back function. 2.Adjust parameter checking function. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
1.Put resource including request and resource list into QP context structure to avoid allocate memory repeatedly. 2.Add max context queue number to void kcalloc large memory for QP context. 3.Remove the resource allocation operation. 4.Redefine resource allocation APIs to be shared by other algorithms. 5.Move resource allocation and free inner functions out of operations 'struct sec_req_op', and they are called directly. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
1.Adjust dma map function to be reused by AEAD algorithms; 2.Update some names of internal functions and variables to support AEAD algorithms; 3.Rename 'sec_skcipher_exit' as 'sec_skcipher_uninit'; 4.Rename 'sec_get/put_queue_id' as 'sec_alloc/free_queue_id'; Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
Fixed some print, coding style and comments of HiSilicon SEC V2. Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Zaibo Xu 提交于
Applied some advices of Marco Elver on atomic usage of Debugfs, which is carried out by basing on Arnd Bergmann's fixing patch. Reported-by: NArnd Bergmann <arnd@arndb.de> Reported-by: NMarco Elver <elver@google.com> Signed-off-by: NZaibo Xu <xuzaibo@huawei.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Rijo Thomas 提交于
Remove NULL check for pool variable, since in the current code path it is guaranteed to be non-NULL. Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NRijo Thomas <Rijo-john.Thomas@amd.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Rijo Thomas 提交于
Rename err label to err_device_unregister for better readability. Suggested-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NRijo Thomas <Rijo-john.Thomas@amd.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Rijo Thomas 提交于
Currently, if tee_device_alloc() fails, then tee_device_unregister() is a no-op. Therefore, skip the function call to tee_device_unregister() by introducing a new goto label 'err_free_pool'. Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NRijo Thomas <Rijo-john.Thomas@amd.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Rijo Thomas 提交于
If there is no TEE with which the driver can communicate, then print an error message and return. Suggested-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NRijo Thomas <Rijo-john.Thomas@amd.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Rijo Thomas 提交于
Remove unused variable initialization from driver code. If enabled as a compiler option, compiler may throw warning for unused assignments. Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Fixes: 757cc3e9 ("tee: add AMD-TEE driver") Signed-off-by: NRijo Thomas <Rijo-john.Thomas@amd.com> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-
由 Daniel Axtens 提交于
When the kernel XTS implementation was extended to deal with ciphertext stealing in commit 8083b1bf ("crypto: xts - add support for ciphertext stealing"), a check was added to reject inputs that were too short. However, in the vmx enablement - commit 23966841 ("crypto: vmx/xts - use fallback for ciphertext stealing"), that check wasn't added to the vmx implementation. This disparity leads to errors like the following: alg: skcipher: p8_aes_xts encryption unexpectedly succeeded on test vector "random: len=0 klen=64"; expected_error=-22, cfg="random: inplace may_sleep use_finup src_divs=[<flush>66.99%@+10, 33.1%@alignmask+1155]" Return -EINVAL if asked to operate with a cryptlen smaller than the AES block size. This brings vmx in line with the generic implementation. Reported-by: NErhard Furtner <erhard_f@mailbox.org> Link: https://bugzilla.kernel.org/show_bug.cgi?id=206049 Fixes: 23966841 ("crypto: vmx/xts - use fallback for ciphertext stealing") Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: stable@vger.kernel.org # v5.4+ Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au> [dja: commit message] Signed-off-by: NDaniel Axtens <dja@axtens.net> Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
-