RE: [PATCH] crypto: tegra: remove driver

2014-02-18 Thread Varun Wadekar
; Stephen Warren; Varun Wadekar Subject: [PATCH] crypto: tegra: remove driver From: Stephen Warren This driver has never been hooked up in any board file, and cannot be instantiated via device tree. I've been told that, at least on Tegra20, the HW is slower at crypto than the main CPU. I ha

RE: [PATCH 4/4] crypto: tegra-aes - Use devm_ioremap_resource()

2014-02-11 Thread Varun Wadekar
Looks good. Please add my ACK. Thanks. -Original Message- From: Jingoo Han [mailto:jg1@samsung.com] Sent: Wednesday, February 12, 2014 9:57 AM To: 'Herbert Xu' Cc: 'David Miller'; linux-crypto@vger.kernel.org; 'Jingoo Han'; 'Stephen Warren';

Re: [PATCH v8 0/2] crypto: driver for Tegra AES hardware

2012-01-12 Thread Varun Wadekar
On Friday 13 January 2012 11:05 AM, Herbert Xu wrote: On Fri, Dec 16, 2011 at 11:25:53AM +, Varun Wadekar wrote: The tegra crypto driver uses the tegra_chip_uid API for the RNG calculation. If one wants to build tegra-aes as a module, then tegra_chip_uid needs to be exported. Both patches

Re: [PATCH v8 2/2] crypto: driver for Tegra AES hardware

2012-01-12 Thread Varun Wadekar
Add Herbert and David On Friday 16 December 2011 04:55 PM, Varun Wadekar wrote: driver supports ecb/cbc/ofb/ansi_x9.31rng modes, 128, 192 and 256-bit key sizes Signed-off-by: Varun Wadekar --- drivers/crypto/Kconfig | 11 + drivers/crypto/Makefile|1 + drivers/crypto/tegra

Re: [PATCH v8 1/2] arm: tegra: export tegra_chip_uid

2012-01-12 Thread Varun Wadekar
Add Herbert and David On Friday 16 December 2011 04:55 PM, Varun Wadekar wrote: From: Henning Heinold The crypto driver will need this api to use it in the RNG calculations. In order to build the crypto driver as a module, tegra_chip_uid has to be exported. Acked-by: Olof Johansson Signed-off

Re: [PATCH v8 2/2] crypto: driver for Tegra AES hardware

2012-01-08 Thread Varun Wadekar
ay 16 December 2011 04:55 PM, Varun Wadekar wrote: driver supports ecb/cbc/ofb/ansi_x9.31rng modes, 128, 192 and 256-bit key sizes Signed-off-by: Varun Wadekar --- drivers/crypto/Kconfig | 11 + drivers/crypto/Makefile|1 + drivers/crypto/tegra-aes.c |

[PATCH v8 2/2] crypto: driver for Tegra AES hardware

2011-12-16 Thread Varun Wadekar
driver supports ecb/cbc/ofb/ansi_x9.31rng modes, 128, 192 and 256-bit key sizes Signed-off-by: Varun Wadekar --- drivers/crypto/Kconfig | 11 + drivers/crypto/Makefile|1 + drivers/crypto/tegra-aes.c | 1096 drivers/crypto/tegra-aes.h

[PATCH v8 1/2] arm: tegra: export tegra_chip_uid

2011-12-16 Thread Varun Wadekar
From: Henning Heinold The crypto driver will need this api to use it in the RNG calculations. In order to build the crypto driver as a module, tegra_chip_uid has to be exported. Acked-by: Olof Johansson Signed-off-by: Henning Heinold Signed-off-by: Varun Wadekar --- arch/arm/mach-tegra

[PATCH v8 0/2] crypto: driver for Tegra AES hardware

2011-12-16 Thread Varun Wadekar
--- Fixed the compilation issues that Henning reported. The driver now builds as a module. Use devm_* apis. Fixed other comments from StephenW and KimP. Henning Heinold (1): arm: tegra: export tegra_chip_uid Varun Wadekar (1): crypto: driver for Tegra AES hardware arch/arm/mach-tegra

[PATCH v7 2/2] crypto: driver for Tegra AES hardware

2011-11-17 Thread Varun Wadekar
driver supports ecb/cbc/ofb/ansi_x9.31rng modes, 128, 192 and 256-bit key sizes Signed-off-by: Varun Wadekar --- drivers/crypto/Kconfig | 11 + drivers/crypto/Makefile|1 + drivers/crypto/tegra-aes.c | 1102 drivers/crypto/tegra-aes.h

[PATCH v7 1/2] arm: tegra: export tegra_chip_uid

2011-11-17 Thread Varun Wadekar
From: Henning Heinold The crypto driver will need this api to use it in the RNG calculations. In order to build the crypto driver as a module, tegra_chip_uid has to be exported. Signed-off-by: Henning Heinold Signed-off-by: Varun Wadekar --- arch/arm/mach-tegra/fuse.c |2 ++ 1 files

[PATCH v6 0/2] crypto: driver for Tegra AES hardware

2011-11-17 Thread Varun Wadekar
reported. The driver now builds as a module. Use devm_* apis. Fixed other comments from StephenW and KimP. Henning Heinold (1): arm: tegra: export tegra_chip_uid Varun Wadekar (1): crypto: driver for Tegra AES hardware arch/arm/mach-tegra/fuse.c |2 + drivers/crypto/Kconfig | 11

Re: [PATCH v1] crypto: driver for tegra AES hardware

2011-11-17 Thread Varun Wadekar
>> you're losing free performance. > I am really not comfortable having garbage in the keytable. Kim, do you have any other solution in mind? -- To unsubscribe from this list: send the line "unsubscribe linux-crypto" in the body of a message to majord...@vger.kernel.org More majordomo info at h

Re: [PATCH v1] crypto: driver for tegra AES hardware

2011-11-16 Thread Varun Wadekar
>>> why do you need to clear the entire key table if it will be >>> overwritten anyway? >> If you set a > 128-bit key and then set a 128-bit key, the remaining >> bits still remain in the key table. Similarly, if we use updated IV in >> one operation and want to use the initial IV for the next, th

Re: [PATCH v1] crypto: driver for tegra AES hardware

2011-11-16 Thread Varun Wadekar
> it's not - it saves writes. Are you ok with this solution? Either way I wan to start with a clear key table before programming the hardware. > why do you need to clear the entire key table if it will be > overwritten anyway? If you set a > 128-bit key and then set a 128-bit key, the remaining

[PATCH v6 2/2] crypto: driver for Tegra AES hardware

2011-11-16 Thread Varun Wadekar
driver supports ecb/cbc/ofb/ansi_x9.31rng modes, 128, 192 and 256-bit key sizes Signed-off-by: Varun Wadekar --- drivers/crypto/Kconfig | 11 + drivers/crypto/Makefile|1 + drivers/crypto/tegra-aes.c | 1102 drivers/crypto/tegra-aes.h

[PATCH v6 1/2] arm: tegra: export tegra_chip_uid

2011-11-16 Thread Varun Wadekar
From: Henning Heinold The crypto driver will need this api to use it in the RNG calculations. In order to build the crypto driver as a module, tegra_chip_uid has to be exported. Signed-off-by: Henning Heinold Signed-off-by: Varun Wadekar --- arch/arm/mach-tegra/fuse.c |2 ++ 1 files

[PATCH v6 0/2] crypto: driver for Tegra AES hardware

2011-11-16 Thread Varun Wadekar
pilation issues that Henning reported. The driver now builds as a module. Use devm_* apis. Fixed other comments from StephenW and KimP. Henning Heinold (1): arm: tegra: export tegra_chip_uid Varun Wadekar (1): crypto: driver for Tegra AES hardware arch/arm/mach-tegra/fuse.c |2 + drivers

[PATCH v5 2/2] crypto: driver for Tegra AES hardware

2011-11-16 Thread Varun Wadekar
driver supports ecb/cbc/ofb/ansi_x9.31rng modes, 128, 192 and 256-bit key sizes Change-Id: I3f923576ac80894cdd35b2db8e214e7d18e19c21 Signed-off-by: Varun Wadekar --- drivers/crypto/Kconfig | 11 + drivers/crypto/Makefile|1 + drivers/crypto/tegra-aes.c | 1102

[PATCH v5 1/2] arm: tegra: export tegra_chip_uid

2011-11-16 Thread Varun Wadekar
From: Henning Heinold The crypto driver will need this api to use it in the RNG calculations. In order to build the crypto driver as a module, tegra_chip_uid has to be exported. Change-Id: I1372c06b8cfef74699ea9cd5cfca92648bcd982b Signed-off-by: Henning Heinold Signed-off-by: Varun Wadekar

[PATCH v5 0/2] *** SUBJECT HERE ***

2011-11-16 Thread Varun Wadekar
rytpo driver patch sending the tegra_chip_uid as well. Henning Heinold (1): arm: tegra: export tegra_chip_uid Varun Wadekar (1): crypto: driver for Tegra AES hardware arch/arm/mach-tegra/fuse.c |2 + drivers/crypto/Kconfig | 11 + drivers/crypto/Makefile|1 + dri

Re: [PATCH v1] crypto: driver for tegra AES hardware

2011-11-15 Thread Varun Wadekar
> That doesn't make the duplicate memset/copy cease to be redundant. > > Why not copy the key to where it goes, then memset the rest of the data; > wouldn't that be as simple as: > > memcpy(dd->ivkey_base, ctx->key, ctx->keylen); > memset(dd->ivkey_base + ctx->keylen, 0, AES_HW_KEY_TABLE_LENGTH_BY

[PATCH v4] crypto: driver for Tegra AES hardware

2011-11-15 Thread Varun Wadekar
Driver supports ecb/cbc/ofb/ansi_x9.31rng modes, 128, 192 and 256-bit key sizes Signed-off-by: Varun Wadekar --- v4: Depends on "[PATCH v1] arm: tegra: export tegra_chip_uid" in order to build tegra-aes as a module drivers/crypto/Kconfig | 11 + drivers/crypto/Makefile

[PATCH v1] arm: tegra: export tegra_chip_uid

2011-11-14 Thread Varun Wadekar
The crypto driver will need this api to use it in the RNG calculations. In order to build the crypto driver as a module, tegra_chip_uid has to be exported. Original author: Henning Heinold Signed-off-by: Henning Heinold Signed-off-by: Varun Wadekar --- arch/arm/mach-tegra/fuse.c |2 ++ 1

Re: [PATCH v1] crypto: driver for tegra AES hardware

2011-11-14 Thread Varun Wadekar
>> Why? > To avoid redundant work; there's little point memset()ing a region that's > going to be copied over the top of immediately afterwards. > The length used for memset is different from the length being copied over. I am initially memsetting the entire key struct (which contains the key + o

Re: [PATCH v1] crypto: driver for tegra AES hardware

2011-11-12 Thread Varun Wadekar
>> +/* assign new context to device */ >> +ctx->dd = dd; >> +dd->ctx = ctx; >> + >> +if (ctx->flags & FLAGS_NEW_KEY) { >> +/* copy the key */ >> +memset(dd->ivkey_base, 0, AES_HW_KEY_TABLE_LENGTH_BYTES); >> +memcpy(dd->ivkey_base, ctx->key, ctx->

Re: [PATCH] crypto: driver for tegra AES hardware

2011-11-05 Thread Varun Wadekar
>>> + /* Initialize the vde clock */ >>> + dd->aes_clk = clk_get(dev, "vde"); >> That clock doesn't exist in the mainline kernel; "bsev" exists for device >> "tegra-aes"... >> > We need to use the "vde" clock. I will submit a patch to add the "vde" > clock. "bsev" might not be needed at the mo

Re: [PATCH] crypto: driver for tegra AES hardware

2011-11-05 Thread Varun Wadekar
>> +cmdq[1] = (u32)dd->ivkey_phys_base; >> + >> +for (i = 0; i < ARRAY_SIZE(cmdq); i++) >> +aes_writel(dd, cmdq[i], ICMDQUE_WR); > ARRAY_SIZE is 2 here - why not use a single temporary variable and > two individual aes_writel()s? Removed 'i' and kept cmdq as it is. Adding 2 mo

Re: [PATCH] crypto: driver for tegra AES hardware

2011-11-05 Thread Varun Wadekar
>> +res = platform_get_resource(pdev, IORESOURCE_MEM, 0); > Don't you need to call request_mem_region() between get_resource() and > ioremap()? I am remapping the module register space. Used IORESOURCE_IO instead. > > >> +/* Initialize the vde clock */ >> +dd->aes_clk = clk_get(dev, "

Re: [PATCH] crypto: driver for tegra AES hardware

2011-11-05 Thread Varun Wadekar
On Friday 04 November 2011 07:24 PM, Henning Heinold wrote: > Hi Varun, > > thanks that you come up with an "official" patch for the aes-stuff. > > Against which tree you did test the patch? I tested it against Linus's master branch but unfortunately, some other changes crept inside this patch due