On Wed, Mar 03, 2021 at 12:26:32PM +0200, Horia Geantă wrote:
> Adding some people in the loop, maybe they could help in understanding
> why lack of "dma-coherent" property for a HW-coherent device could lead to
> unexpected / strange side effects.
>
> On 3/1/2021 5:
Hi All,
I am on a Layerscape LS1046a using Linux-5.11. The CAAM driver sometimes
crashes during the run-time self tests with:
> kernel BUG at drivers/crypto/caam/jr.c:247!
> Internal error: Oops - BUG: 0 [#1] PREEMPT SMP
> Modules linked in:
> CPU: 0 PID: 0 Comm: swapper/0 Not tainted
> 5.11.0-2
f65f9573 ("ubifs: Authenticate replayed journal")
> Cc: # v4.20+
> Cc: Sascha Hauer
> Signed-off-by: Eric Biggers
Looks better that way, thanks.
Acked-by: Sascha Hauer
Sascha
--
Pengutronix e.K. | |
Steuerwalder Str.
On Wed, Jun 12, 2019 at 01:35:36PM +0200, Sascha Hauer wrote:
> On Wed, Jun 12, 2019 at 10:33:56AM +, Horia Geanta wrote:
> > On 6/12/2019 12:40 PM, Sascha Hauer wrote:
> > > Hi Horia,
> > >
> > > On Wed, May 15, 2019 at 01:35:16PM +, Horia Geanta wrote
On Wed, Jun 12, 2019 at 10:33:56AM +, Horia Geanta wrote:
> On 6/12/2019 12:40 PM, Sascha Hauer wrote:
> > Hi Horia,
> >
> > On Wed, May 15, 2019 at 01:35:16PM +, Horia Geanta wrote:
> >> For talitos, the problem is the lack of IV update.
> >>
>
Hi Horia,
On Wed, May 15, 2019 at 01:35:16PM +, Horia Geanta wrote:
> For talitos, the problem is the lack of IV update.
>
> For caam, the problem is incorrect IV update (output IV is equal to last
> ciphertext block, which is correect for cbc, but not for ctr mode).
>
> I am working at a fi
following lines when converting print_hex_dump to
print_hex_dump_debug
- Add 1/4 to avoid crash when debugging is enabled
Sascha Hauer (4):
crypto: caam: print IV only when non NULL
crypto: caam: remove unused defines
crypto: caam: print debug messages at debug level
crypto: caam: print messages
Since eaed71a44ad9 ("crypto: caam - add ecb(*) support") the IV can be
NULL, so only dump it when it's non NULL as designated by the ivsize
variable.
Fixes: eaed71a44ad9 ("crypto: caam - add ecb(*) support")
Signed-off-by: Sascha Hauer
---
drivers/crypto/caam/caam
...) inside #ifdef DEBUG with
print_hex_dump_debug(...)
- dev_err() inside #ifdef DEBUG with dev_dbg()
- printk(KERN_ERR ...) inside #ifdef DEBUG with dev_dbg()
Some parts of the driver use these functions already, so it is only
consequent to use the debug function consistently.
Signed-off-by: Sascha
caam_dump_sg() is only compiled in when DEBUG is defined, hence the
messages are debug messages. Remove the @level argument from
caam_dump_sg() and print all messages at debug level.
Signed-off-by: Sascha Hauer
---
drivers/crypto/caam/caamalg.c | 8
drivers/crypto/caam/caamalg_qi.c
The CAAM driver defines its own debug() macro, but it is unused. Remove
it.
Signed-off-by: Sascha Hauer
Reviewed-by: Horia Geantă
---
drivers/crypto/caam/caamalg.c | 7 ---
drivers/crypto/caam/caamhash.c | 8
2 files changed, 15 deletions(-)
diff --git a/drivers/crypto/caam
On Fri, May 17, 2019 at 11:29:04AM +0200, Sascha Hauer wrote:
> The CAAM driver used to put its debug messages inside #ifdef DEBUG and
> then prints the messages at KERN_ERR level. Replace this with proper
> functions printing at KERN_DEBUG level. The #ifdef DEBUG gets
> unnecessary wh
...) inside #ifdef DEBUG with
print_hex_dump_debug(...)
- dev_err() inside #ifdef DEBUG with dev_dbg()
- printk(KERN_ERR ...) inside #ifdef DEBUG with dev_dbg()
Some parts of the driver use these functions already, so it is only
consequent to use the debug function consistently.
Signed-off-by: Sascha
caam_dump_sg() is only compiled in when DEBUG is defined, hence the
messages are debug messages. Remove the @level argument from
caam_dump_sg() and print all messages at debug level.
Signed-off-by: Sascha Hauer
---
drivers/crypto/caam/caamalg.c | 8
drivers/crypto/caam/caamalg_qi.c
The CAAM driver defines its own debug() macro, but it is unused. Remove
it.
Signed-off-by: Sascha Hauer
---
drivers/crypto/caam/caamalg.c | 7 ---
drivers/crypto/caam/caamhash.c | 8
2 files changed, 15 deletions(-)
diff --git a/drivers/crypto/caam/caamalg.c b/drivers/crypto/caam
The CAAM driver has most of its debug messages inside #ifdef DEBUG and
then prints them at KERN_ERR level. Do this properly and print the
messages at DEBUG_LEVEL as they are supposed to. With this we can get
rid of a lot of ifdefs in the code.
Sascha
Sascha Hauer (3):
crypto: caam: remove
On Wed, May 15, 2019 at 01:35:16PM +, Horia Geanta wrote:
> On 5/15/2019 4:22 PM, Sascha Hauer wrote:
> > Hi Fabio,
> >
> > On Wed, May 15, 2019 at 10:17:19AM -0300, Fabio Estevam wrote:
> >> Hi Sascha,
> >>
> >> On Wed, May 15, 2019 at 10
hex dumps consistenly after the buffers have been unmapped and
in case of IV copied to their final destination.
Signed-off-by: Sascha Hauer
---
drivers/crypto/caam/caamalg.c | 21 +++--
1 file changed, 11 insertions(+), 10 deletions(-)
diff --git a/drivers/crypto/caam/caamalg.c b
On Wed, May 15, 2019 at 04:27:51PM +, Horia Geanta wrote:
> On 5/15/2019 4:13 PM, Sascha Hauer wrote:
> > The debugging hex dumps in skcipher_encrypt_done() and
> > skcipher_decrypt_done() are printed while the request is still DMA
> > mapped. This results in bogus hex d
Hi Fabio,
On Wed, May 15, 2019 at 10:17:19AM -0300, Fabio Estevam wrote:
> Hi Sascha,
>
> On Wed, May 15, 2019 at 10:09 AM Sascha Hauer wrote:
> >
> > Hi,
> >
> > ctr(aes) is broken in current kernel (v5.1+). It may have been broken
> > for longer, but t
The debugging hex dumps in skcipher_encrypt_done() and
skcipher_decrypt_done() are printed while the request is still DMA
mapped. This results in bogus hex dumps with things like mixtures
between plain text and cipher text. Unmap first before printing.
Signed-off-by: Sascha Hauer
---
drivers
Hi,
ctr(aes) is broken in current kernel (v5.1+). It may have been broken
for longer, but the crypto tests now check for a correct output IV. The
testmgr answers with:
alg: skcipher: ctr-aes-caam encryption test failed (wrong output IV) on test
vector 0, cfg="in-place"
output IV is this, which
Hi Horia,
On Mon, Feb 04, 2019 at 12:26:26PM +, Horia Geanta wrote:
> On 1/31/2019 8:12 AM, Sascha Hauer wrote:
> > In skcipher_decrypt() the IV passed in by the caller is overwritten and
> > the tcrypt module fails with:
> >
> > alg: aead: decryption failed on t
: 115957bb3e59 ("crypto: caam - fix IV DMA mapping and updating")
Signed-off-by: Sascha Hauer
---
drivers/crypto/caam/caamalg.c | 8
1 file changed, 8 deletions(-)
diff --git a/drivers/crypto/caam/caamalg.c b/drivers/crypto/caam/caamalg.c
index 80ae69f906fb..493fa4169382 10
Horia,
On Fri, Dec 07, 2018 at 12:31:23PM +0100, Sascha Hauer wrote:
> The crypto API wants the updated IV in req->info after decryption. The
> updated IV used to be copied correctly to req->info after running the
> decryption job. Since 115957bb3e59 this is done before runni
crypto API.
This was observed running the gcm(aes) selftest which internally uses
ctr(aes) implemented by the CAAM engine.
Fixes: 115957bb3e59 ("crypto: caam - fix IV DMA mapping and updating")
Signed-off-by: Sascha Hauer
Cc: sta...@vger.kernel.org
---
drivers/crypto/caa
On Fri, Aug 31, 2018 at 01:07:39PM +0200, Krzysztof Kozlowski wrote:
> On Fri, 31 Aug 2018 at 09:39, Sascha Hauer wrote:
> >
> > Hi Krzysztof,
> >
> > Some comments inline.
> >
> > On Thu, Aug 30, 2018 at 07:15:39PM +0200, Krzysztof Kozlowski wrote:
>
Hi Krzysztof,
Some comments inline.
On Thu, Aug 30, 2018 at 07:15:39PM +0200, Krzysztof Kozlowski wrote:
> Add driver for using the Freescale/NXP Vybrid processor CRC block for
> CRC16 and CRC32 offloading. The driver implements shash_alg and was
> tested using internal testmgr tests and libkcap
On Thu, Jul 30, 2015 at 11:32:44PM -0700, Victoria Milhoan wrote:
> Hi Sascha,
>
> Thank you for the responses. Comments inline. Changes will be
> in the next version of the patch set.
>
> -Victoria
>
> On Thu, 30 Jul 2015 08:02:14 +0200
> Sascha Hauer
On Wed, Jul 29, 2015 at 08:58:25PM -0700, Victoria Milhoan wrote:
> Add CAAM clock support to the i.MX6 clocking infrastructure.
>
> Signed-off-by: Victoria Milhoan
> ---
> drivers/clk/imx/clk-imx6q.c | 3 +++
> include/dt-bindings/clock/imx6qdl-clock.h | 5 -
> 2 files changed
On Wed, Jul 29, 2015 at 08:58:26PM -0700, Victoria Milhoan wrote:
> Add CAAM device node to the i.MX6 device tree.
>
> Signed-off-by: Victoria Milhoan
> ---
> arch/arm/boot/dts/imx6qdl.dtsi | 30 ++
> 1 file changed, 26 insertions(+), 4 deletions(-)
>
> diff --git a/
Hi Victoria,
comments inline.
On Wed, Jul 29, 2015 at 08:58:20PM -0700, Victoria Milhoan wrote:
> ARM-based systems may disable clocking to the CAAM device on the
> Freescale i.MX platform for power management purposes. This patch
> enables the required clocks when the CAAM module is initialized
On Mon, Mar 11, 2013 at 09:19:26AM +0800, Herbert Xu wrote:
> On Mon, Mar 11, 2013 at 12:08:56AM +0100, Sascha Hauer wrote:
> > On Sun, Mar 10, 2013 at 04:34:01PM +0800, Herbert Xu wrote:
> > > > >
> > > > > https://patchwork.kernel.org/patch/1817741/
On Sun, Mar 10, 2013 at 04:34:01PM +0800, Herbert Xu wrote:
> > >
> > > https://patchwork.kernel.org/patch/1817741/
> > >
> > > So the change above becomes unnecessary
> >
> > Very good. Then this patch can be safely dropped.
>
> So should I take this patch or not?
This clk patch, no. The sahara
On Fri, Mar 01, 2013 at 12:37:52PM +0100, Javier Martin wrote:
>
> Signed-off-by: Javier Martin
> ---
> arch/arm/mach-imx/clk-imx27.c |2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/arch/arm/mach-imx/clk-imx27.c b/arch/arm/mach-imx/clk-imx27.c
> index 4c1d1e4..0b9664a 100644
> ---
Hi Javier,
On Wed, Feb 27, 2013 at 11:41:51AM +0100, Javier Martin wrote:
>
> Signed-off-by: Javier Martin
> ---
> .../devicetree/bindings/crypto/fsl-imx-sahara.txt | 14 ++
> 1 file changed, 14 insertions(+)
> create mode 100644
> Documentation/devicetree/bindings/crypto/fsl-i
On Thu, Feb 21, 2013 at 02:40:59PM +, Arnd Bergmann wrote:
> On Thursday 21 February 2013, javier Martin wrote:
> > We know about the existence of DT and the constant migration process
> > that is taking place towards it.
> >
> > Moreover we are strongly interested in converting the Visstrim S
On Thu, Feb 21, 2013 at 03:18:36PM +0100, javier Martin wrote:
> Hi Arnd,
>
> On 21 February 2013 13:59, Arnd Bergmann wrote:
> > On Thursday 21 February 2013, Javier Martin wrote:
> >> This series of patches provide AES-ECB and AES-CBC support
> >> for the SAHARA2 cryptographic accelerator which
38 matches
Mail list logo