* [PATCH v2 0/3] Update for ux500 CRYP and HASH
@ 2012-05-10 8:14 Andreas Westin
2012-05-10 8:14 ` [PATCH v2 1/3] mach-ux500: Crypto: core support for CRYP/HASH module Andreas Westin
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: Andreas Westin @ 2012-05-10 8:14 UTC (permalink / raw)
To: Herbert Xu, David S. Miller
Cc: linux-crypto, arnd, sfr, lee.jones, linus.walleij, Andreas Westin
Hi,
V2 of the patches.
* Removed symbol export
* Removed usage of SOC specific functions in the drivers.
* Readded overlooked config for DMA in mach-ux500.
After some internal discussion we felt that the now implemented
hardware identification solution is cleaner than the suggested
solution.
The hardware identification patch applies cleanly to
the cryptodev tree.
Regards
Andreas
Andreas Westin (3):
mach-ux500: Crypto: core support for CRYP/HASH module.
crypto: ux500: Update DMA handling for 3.4
crypto: ux500: Cleanup hardware identification
arch/arm/mach-ux500/board-mop500.c | 48 ++++++++++++++++++++
arch/arm/mach-ux500/clock.c | 18 ++++----
arch/arm/mach-ux500/devices-common.h | 54 +++++++++++++++++++++++
arch/arm/mach-ux500/devices-db8500.c | 3 ++
arch/arm/mach-ux500/devices-db8500.h | 4 ++
arch/arm/mach-ux500/include/mach/crypto-ux500.h | 1 +
arch/arm/mach-ux500/include/mach/devices.h | 3 ++
arch/arm/mach-ux500/include/mach/hardware.h | 3 ++
drivers/crypto/ux500/cryp/cryp.c | 10 ++---
drivers/crypto/ux500/cryp/cryp_core.c | 5 +--
drivers/crypto/ux500/cryp/cryp_p.h | 1 -
drivers/crypto/ux500/hash/hash_core.c | 12 +----
12 files changed, 133 insertions(+), 29 deletions(-)
--
1.7.10
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v2 1/3] mach-ux500: Crypto: core support for CRYP/HASH module.
2012-05-10 8:14 [PATCH v2 0/3] Update for ux500 CRYP and HASH Andreas Westin
@ 2012-05-10 8:14 ` Andreas Westin
2012-05-10 8:14 ` [PATCH v2 2/3] crypto: ux500: Update DMA handling for 3.4 Andreas Westin
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: Andreas Westin @ 2012-05-10 8:14 UTC (permalink / raw)
To: Herbert Xu, David S. Miller
Cc: linux-crypto, arnd, sfr, lee.jones, linus.walleij, Andreas Westin
This adds the required platform data and calls to enable
the CRYP/HASH driver.
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Andreas Westin <andreas.westin@stericsson.com>
---
arch/arm/mach-ux500/board-mop500.c | 48 ++++++++++++++++++++
arch/arm/mach-ux500/clock.c | 18 ++++----
arch/arm/mach-ux500/devices-common.h | 54 +++++++++++++++++++++++
arch/arm/mach-ux500/devices-db8500.c | 3 ++
arch/arm/mach-ux500/devices-db8500.h | 4 ++
arch/arm/mach-ux500/include/mach/crypto-ux500.h | 1 +
arch/arm/mach-ux500/include/mach/devices.h | 3 ++
arch/arm/mach-ux500/include/mach/hardware.h | 3 ++
8 files changed, 126 insertions(+), 8 deletions(-)
diff --git a/arch/arm/mach-ux500/board-mop500.c b/arch/arm/mach-ux500/board-mop500.c
index 77d03c1..d622606 100644
--- a/arch/arm/mach-ux500/board-mop500.c
+++ b/arch/arm/mach-ux500/board-mop500.c
@@ -47,6 +47,7 @@
#include <mach/setup.h>
#include <mach/devices.h>
#include <mach/irqs.h>
+#include <mach/crypto-ux500.h>
#include "pins-db8500.h"
#include "ste-dma40-db8500.h"
@@ -417,6 +418,45 @@ static void mop500_prox_deactivate(struct device *dev)
regulator_put(prox_regulator);
}
+static struct cryp_platform_data u8500_cryp1_platform_data = {
+ .mem_to_engine = {
+ .dir = STEDMA40_MEM_TO_PERIPH,
+ .src_dev_type = STEDMA40_DEV_SRC_MEMORY,
+ .dst_dev_type = DB8500_DMA_DEV48_CAC1_TX,
+ .src_info.data_width = STEDMA40_WORD_WIDTH,
+ .dst_info.data_width = STEDMA40_WORD_WIDTH,
+ .mode = STEDMA40_MODE_LOGICAL,
+ .src_info.psize = STEDMA40_PSIZE_LOG_4,
+ .dst_info.psize = STEDMA40_PSIZE_LOG_4,
+ },
+ .engine_to_mem = {
+ .dir = STEDMA40_PERIPH_TO_MEM,
+ .src_dev_type = DB8500_DMA_DEV48_CAC1_RX,
+ .dst_dev_type = STEDMA40_DEV_DST_MEMORY,
+ .src_info.data_width = STEDMA40_WORD_WIDTH,
+ .dst_info.data_width = STEDMA40_WORD_WIDTH,
+ .mode = STEDMA40_MODE_LOGICAL,
+ .src_info.psize = STEDMA40_PSIZE_LOG_4,
+ .dst_info.psize = STEDMA40_PSIZE_LOG_4,
+ }
+};
+
+static struct stedma40_chan_cfg u8500_hash_dma_cfg_tx = {
+ .dir = STEDMA40_MEM_TO_PERIPH,
+ .src_dev_type = STEDMA40_DEV_SRC_MEMORY,
+ .dst_dev_type = DB8500_DMA_DEV50_HAC1_TX,
+ .src_info.data_width = STEDMA40_WORD_WIDTH,
+ .dst_info.data_width = STEDMA40_WORD_WIDTH,
+ .mode = STEDMA40_MODE_LOGICAL,
+ .src_info.psize = STEDMA40_PSIZE_LOG_16,
+ .dst_info.psize = STEDMA40_PSIZE_LOG_16,
+};
+
+static struct hash_platform_data u8500_hash1_platform_data = {
+ .mem_to_engine = &u8500_hash_dma_cfg_tx,
+ .dma_filter = stedma40_filter,
+};
+
/* add any platform devices here - TODO */
static struct platform_device *mop500_platform_devs[] __initdata = {
&mop500_gpio_keys_device,
@@ -602,6 +642,12 @@ static void __init mop500_uart_init(struct device *parent)
db8500_add_uart2(parent, &uart2_plat);
}
+static void __init u8500_cryp1_hash1_init(struct device *parent)
+{
+ db8500_add_cryp1(parent, &u8500_cryp1_platform_data);
+ db8500_add_hash1(parent, &u8500_hash1_platform_data);
+}
+
static struct platform_device *snowball_platform_devs[] __initdata = {
&snowball_led_dev,
&snowball_key_dev,
@@ -633,6 +679,8 @@ static void __init mop500_init_machine(void)
mop500_spi_init(parent);
mop500_uart_init(parent);
+ u8500_cryp1_hash1_init(parent);
+
i2c0_devs = ARRAY_SIZE(mop500_i2c0_devices);
i2c_register_board_info(0, mop500_i2c0_devices, i2c0_devs);
diff --git a/arch/arm/mach-ux500/clock.c b/arch/arm/mach-ux500/clock.c
index ec35f0a..2efc1fe 100644
--- a/arch/arm/mach-ux500/clock.c
+++ b/arch/arm/mach-ux500/clock.c
@@ -382,14 +382,15 @@ static DEFINE_PRCC_CLK(5, usb, 0, 0, NULL);
/* Peripheral Cluster #6 */
/* MTU ID in data */
-static DEFINE_PRCC_CLK_CUSTOM(6, mtu1, 8, -1, NULL, clk_mtu_get_rate, 1);
-static DEFINE_PRCC_CLK_CUSTOM(6, mtu0, 7, -1, NULL, clk_mtu_get_rate, 0);
-static DEFINE_PRCC_CLK(6, cfgreg, 6, 6, NULL);
-static DEFINE_PRCC_CLK(6, hash1, 5, -1, NULL);
-static DEFINE_PRCC_CLK(6, unipro, 4, 1, &clk_uniproclk);
-static DEFINE_PRCC_CLK(6, pka, 3, -1, NULL);
-static DEFINE_PRCC_CLK(6, hash0, 2, -1, NULL);
-static DEFINE_PRCC_CLK(6, cryp0, 1, -1, NULL);
+static DEFINE_PRCC_CLK_CUSTOM(6, mtu1, 9, -1, NULL, clk_mtu_get_rate, 1);
+static DEFINE_PRCC_CLK_CUSTOM(6, mtu0, 8, -1, NULL, clk_mtu_get_rate, 0);
+static DEFINE_PRCC_CLK(6, cfgreg, 7, 7, NULL);
+static DEFINE_PRCC_CLK(6, hash1, 6, -1, NULL);
+static DEFINE_PRCC_CLK(6, unipro, 5, 1, &clk_uniproclk);
+static DEFINE_PRCC_CLK(6, pka, 4, -1, NULL);
+static DEFINE_PRCC_CLK(6, hash0, 3, -1, NULL);
+static DEFINE_PRCC_CLK(6, cryp0, 2, -1, NULL);
+static DEFINE_PRCC_CLK(6, cryp1, 1, -1, NULL);
static DEFINE_PRCC_CLK(6, rng, 0, 0, &clk_rngclk);
static struct clk clk_dummy_apb_pclk = {
@@ -431,6 +432,7 @@ static struct clk_lookup u8500_clks[] = {
CLK(pka, "pka", NULL),
CLK(hash0, "hash0", NULL),
CLK(cryp0, "cryp0", NULL),
+ CLK(cryp1, "cryp1", NULL),
/* PRCMU level clock gating */
diff --git a/arch/arm/mach-ux500/devices-common.h b/arch/arm/mach-ux500/devices-common.h
index 39c74ec..89c5a59 100644
--- a/arch/arm/mach-ux500/devices-common.h
+++ b/arch/arm/mach-ux500/devices-common.h
@@ -12,12 +12,17 @@
#include <linux/dma-mapping.h>
#include <linux/sys_soc.h>
#include <plat/i2c.h>
+#include <mach/crypto-ux500.h>
extern struct amba_device *
dbx500_add_amba_device(struct device *parent, const char *name,
resource_size_t base, int irq, void *pdata,
unsigned int periphid);
+extern struct platform_device *
+dbx500_add_platform_device_noirq(const char *name, int id,
+ resource_size_t base, void *pdata);
+
struct spi_master_cntlr;
static inline struct amba_device *
@@ -88,6 +93,55 @@ dbx500_add_rtc(struct device *parent, resource_size_t base, int irq)
return dbx500_add_amba_device(parent, "rtc-pl031", base, irq, NULL, 0);
}
+struct cryp_platform_data;
+
+static inline struct platform_device *
+dbx500_add_cryp1(struct device *parent, int id, resource_size_t base, int irq,
+ struct cryp_platform_data *pdata)
+{
+ struct resource res[] = {
+ DEFINE_RES_MEM(base, SZ_4K),
+ DEFINE_RES_IRQ(irq),
+ };
+
+ struct platform_device_info pdevinfo = {
+ .parent = parent,
+ .name = "cryp1",
+ .id = id,
+ .res = res,
+ .num_res = ARRAY_SIZE(res),
+ .data = pdata,
+ .size_data = sizeof(*pdata),
+ .dma_mask = DMA_BIT_MASK(32),
+ };
+
+ return platform_device_register_full(&pdevinfo);
+}
+
+struct hash_platform_data;
+
+static inline struct platform_device *
+dbx500_add_hash1(struct device *parent, int id, resource_size_t base,
+ struct hash_platform_data *pdata)
+{
+ struct resource res[] = {
+ DEFINE_RES_MEM(base, SZ_4K),
+ };
+
+ struct platform_device_info pdevinfo = {
+ .parent = parent,
+ .name = "hash1",
+ .id = id,
+ .res = res,
+ .num_res = ARRAY_SIZE(res),
+ .data = pdata,
+ .size_data = sizeof(*pdata),
+ .dma_mask = DMA_BIT_MASK(32),
+ };
+
+ return platform_device_register_full(&pdevinfo);
+}
+
struct nmk_gpio_platform_data;
void dbx500_add_gpios(struct device *parent, resource_size_t *base, int num,
diff --git a/arch/arm/mach-ux500/devices-db8500.c b/arch/arm/mach-ux500/devices-db8500.c
index 6e66d37..91754a8 100644
--- a/arch/arm/mach-ux500/devices-db8500.c
+++ b/arch/arm/mach-ux500/devices-db8500.c
@@ -104,6 +104,8 @@ static const dma_addr_t dma40_tx_map[DB8500_DMA_NR_DEV] = {
[DB8500_DMA_DEV14_MSP2_TX] = U8500_MSP2_BASE + MSP_TX_RX_REG_OFFSET,
[DB8500_DMA_DEV30_MSP1_TX] = U8500_MSP1_BASE + MSP_TX_RX_REG_OFFSET,
[DB8500_DMA_DEV31_MSP0_TX_SLIM0_CH0_TX] = U8500_MSP0_BASE + MSP_TX_RX_REG_OFFSET,
+ [DB8500_DMA_DEV48_CAC1_TX] = U8500_CRYP1_BASE + CRYP1_TX_REG_OFFSET,
+ [DB8500_DMA_DEV50_HAC1_TX] = U8500_HASH1_BASE + HASH1_TX_REG_OFFSET,
};
/* Mapping between source event lines and physical device address */
@@ -139,6 +141,7 @@ static const dma_addr_t dma40_rx_map[DB8500_DMA_NR_DEV] = {
[DB8500_DMA_DEV14_MSP2_RX] = U8500_MSP2_BASE + MSP_TX_RX_REG_OFFSET,
[DB8500_DMA_DEV30_MSP3_RX] = U8500_MSP3_BASE + MSP_TX_RX_REG_OFFSET,
[DB8500_DMA_DEV31_MSP0_RX_SLIM0_CH0_RX] = U8500_MSP0_BASE + MSP_TX_RX_REG_OFFSET,
+ [DB8500_DMA_DEV48_CAC1_RX] = U8500_CRYP1_BASE + CRYP1_RX_REG_OFFSET,
};
/* Reserved event lines for memcpy only */
diff --git a/arch/arm/mach-ux500/devices-db8500.h b/arch/arm/mach-ux500/devices-db8500.h
index 9fd93e9..cdf5ca8 100644
--- a/arch/arm/mach-ux500/devices-db8500.h
+++ b/arch/arm/mach-ux500/devices-db8500.h
@@ -124,4 +124,8 @@ db8500_add_ssp(struct device *parent, const char *name, resource_size_t base,
dbx500_add_uart(parent, "uart2", U8500_UART2_BASE, \
IRQ_DB8500_UART2, pdata)
+#define db8500_add_cryp1(parent, pdata) \
+ dbx500_add_cryp1(parent, -1, U8500_CRYP1_BASE, IRQ_DB8500_CRYP1, pdata)
+#define db8500_add_hash1(parent, pdata) \
+ dbx500_add_hash1(parent, -1, U8500_HASH1_BASE, pdata)
#endif
diff --git a/arch/arm/mach-ux500/include/mach/crypto-ux500.h b/arch/arm/mach-ux500/include/mach/crypto-ux500.h
index de40add..5b2d081 100644
--- a/arch/arm/mach-ux500/include/mach/crypto-ux500.h
+++ b/arch/arm/mach-ux500/include/mach/crypto-ux500.h
@@ -5,6 +5,7 @@
* License terms: GNU General Public License (GPL) version 2
*/
#ifndef _CRYPTO_UX500_H
+#define _CRYPTO_UX500_H
#include <linux/dmaengine.h>
#include <plat/ste_dma40.h>
diff --git a/arch/arm/mach-ux500/include/mach/devices.h b/arch/arm/mach-ux500/include/mach/devices.h
index 5f6cb71..a55454a 100644
--- a/arch/arm/mach-ux500/include/mach/devices.h
+++ b/arch/arm/mach-ux500/include/mach/devices.h
@@ -15,6 +15,9 @@ extern struct platform_device u8500_gpio_devs[];
extern struct amba_device ux500_pl031_device;
+extern struct platform_device ux500_hash1_device;
+extern struct platform_device ux500_cryp1_device;
+
extern struct platform_device u8500_dma40_device;
extern struct platform_device ux500_ske_keypad_device;
diff --git a/arch/arm/mach-ux500/include/mach/hardware.h b/arch/arm/mach-ux500/include/mach/hardware.h
index f846989..ac2353c 100644
--- a/arch/arm/mach-ux500/include/mach/hardware.h
+++ b/arch/arm/mach-ux500/include/mach/hardware.h
@@ -31,6 +31,9 @@
#include <mach/db5500-regs.h>
#define MSP_TX_RX_REG_OFFSET 0
+#define CRYP1_RX_REG_OFFSET 0x10
+#define CRYP1_TX_REG_OFFSET 0x8
+#define HASH1_TX_REG_OFFSET 0x4
#ifndef __ASSEMBLY__
--
1.7.10
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v2 2/3] crypto: ux500: Update DMA handling for 3.4
2012-05-10 8:14 [PATCH v2 0/3] Update for ux500 CRYP and HASH Andreas Westin
2012-05-10 8:14 ` [PATCH v2 1/3] mach-ux500: Crypto: core support for CRYP/HASH module Andreas Westin
@ 2012-05-10 8:14 ` Andreas Westin
2012-05-10 8:14 ` [PATCH v2 3/3] crypto: ux500: Cleanup hardware identification Andreas Westin
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: Andreas Westin @ 2012-05-10 8:14 UTC (permalink / raw)
To: Herbert Xu, David S. Miller
Cc: linux-crypto, arnd, sfr, lee.jones, linus.walleij, Andreas Westin
An update to the DMA framework added a new parameter to the
device_prep_slave_sg call.
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Andreas Westin <andreas.westin@stericsson.com>
---
drivers/crypto/ux500/cryp/cryp_core.c | 5 ++---
drivers/crypto/ux500/hash/hash_core.c | 2 +-
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/crypto/ux500/cryp/cryp_core.c b/drivers/crypto/ux500/cryp/cryp_core.c
index 7051e00..7cac127 100644
--- a/drivers/crypto/ux500/cryp/cryp_core.c
+++ b/drivers/crypto/ux500/cryp/cryp_core.c
@@ -542,8 +542,7 @@ static int cryp_set_dma_transfer(struct cryp_ctx *ctx,
desc = channel->device->device_prep_slave_sg(channel,
ctx->device->dma.sg_src,
ctx->device->dma.sg_src_len,
- direction,
- DMA_CTRL_ACK);
+ direction, DMA_CTRL_ACK, NULL);
break;
case DMA_FROM_DEVICE:
@@ -569,7 +568,7 @@ static int cryp_set_dma_transfer(struct cryp_ctx *ctx,
ctx->device->dma.sg_dst_len,
direction,
DMA_CTRL_ACK |
- DMA_PREP_INTERRUPT);
+ DMA_PREP_INTERRUPT, NULL);
desc->callback = cryp_dma_out_callback;
desc->callback_param = ctx;
diff --git a/drivers/crypto/ux500/hash/hash_core.c b/drivers/crypto/ux500/hash/hash_core.c
index cc6a371..77f7508 100644
--- a/drivers/crypto/ux500/hash/hash_core.c
+++ b/drivers/crypto/ux500/hash/hash_core.c
@@ -174,7 +174,7 @@ static int hash_set_dma_transfer(struct hash_ctx *ctx, struct scatterlist *sg,
"(TO_DEVICE)", __func__);
desc = channel->device->device_prep_slave_sg(channel,
ctx->device->dma.sg, ctx->device->dma.sg_len,
- direction, DMA_CTRL_ACK | DMA_PREP_INTERRUPT);
+ direction, DMA_CTRL_ACK | DMA_PREP_INTERRUPT, NULL);
if (!desc) {
dev_err(ctx->device->dev,
"[%s]: device_prep_slave_sg() failed!", __func__);
--
1.7.10
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v2 3/3] crypto: ux500: Cleanup hardware identification
2012-05-10 8:14 [PATCH v2 0/3] Update for ux500 CRYP and HASH Andreas Westin
2012-05-10 8:14 ` [PATCH v2 1/3] mach-ux500: Crypto: core support for CRYP/HASH module Andreas Westin
2012-05-10 8:14 ` [PATCH v2 2/3] crypto: ux500: Update DMA handling for 3.4 Andreas Westin
@ 2012-05-10 8:14 ` Andreas Westin
2012-05-10 10:55 ` [PATCH v2 0/3] Update for ux500 CRYP and HASH Arnd Bergmann
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: Andreas Westin @ 2012-05-10 8:14 UTC (permalink / raw)
To: Herbert Xu, David S. Miller
Cc: linux-crypto, arnd, sfr, lee.jones, linus.walleij, Andreas Westin
Don't use SOC specific functions to identify
which crypto hardware we are talking to and use
the ID provided in the module instead.
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Andreas Westin <andreas.westin@stericsson.com>
---
drivers/crypto/ux500/cryp/cryp.c | 10 ++++------
drivers/crypto/ux500/cryp/cryp_p.h | 1 -
drivers/crypto/ux500/hash/hash_core.c | 10 ----------
3 files changed, 4 insertions(+), 17 deletions(-)
diff --git a/drivers/crypto/ux500/cryp/cryp.c b/drivers/crypto/ux500/cryp/cryp.c
index bd206ff..e208cea 100644
--- a/drivers/crypto/ux500/cryp/cryp.c
+++ b/drivers/crypto/ux500/cryp/cryp.c
@@ -37,18 +37,16 @@ int cryp_check(struct cryp_device_data *device_data)
if (NULL == device_data)
return -EINVAL;
- if (cpu_is_u8500())
- peripheralid2 = CRYP_PERIPHERAL_ID2_DB8500;
- else if (cpu_is_u5500())
- peripheralid2 = CRYP_PERIPHERAL_ID2_DB5500;
+ peripheralid2 = readl_relaxed(&device_data->base->periphId2);
+
+ if (peripheralid2 != CRYP_PERIPHERAL_ID2_DB8500)
+ return -EPERM;
/* Check Peripheral and Pcell Id Register for CRYP */
if ((CRYP_PERIPHERAL_ID0 ==
readl_relaxed(&device_data->base->periphId0))
&& (CRYP_PERIPHERAL_ID1 ==
readl_relaxed(&device_data->base->periphId1))
- && (peripheralid2 ==
- readl_relaxed(&device_data->base->periphId2))
&& (CRYP_PERIPHERAL_ID3 ==
readl_relaxed(&device_data->base->periphId3))
&& (CRYP_PCELL_ID0 ==
diff --git a/drivers/crypto/ux500/cryp/cryp_p.h b/drivers/crypto/ux500/cryp/cryp_p.h
index 0e07082..6dcffe1 100644
--- a/drivers/crypto/ux500/cryp/cryp_p.h
+++ b/drivers/crypto/ux500/cryp/cryp_p.h
@@ -41,7 +41,6 @@
#define CRYP_PERIPHERAL_ID1 0x05
#define CRYP_PERIPHERAL_ID2_DB8500 0x28
-#define CRYP_PERIPHERAL_ID2_DB5500 0x29
#define CRYP_PERIPHERAL_ID3 0x00
#define CRYP_PCELL_ID0 0x0D
diff --git a/drivers/crypto/ux500/hash/hash_core.c b/drivers/crypto/ux500/hash/hash_core.c
index 77f7508..6dbb9ec 100644
--- a/drivers/crypto/ux500/hash/hash_core.c
+++ b/drivers/crypto/ux500/hash/hash_core.c
@@ -574,15 +574,6 @@ static int hash_init(struct ahash_request *req)
memset(&req_ctx->state, 0, sizeof(struct hash_state));
req_ctx->updated = 0;
if (hash_mode == HASH_MODE_DMA) {
- if ((ctx->config.oper_mode == HASH_OPER_MODE_HMAC) &&
- cpu_is_u5500()) {
- pr_debug(DEV_DBG_NAME " [%s] HMAC and DMA not working "
- "on u5500, directing to CPU mode.",
- __func__);
- req_ctx->dma_mode = false; /* Don't use DMA */
- goto out;
- }
-
if (req->nbytes < HASH_DMA_ALIGN_SIZE) {
req_ctx->dma_mode = false; /* Don't use DMA */
@@ -604,7 +595,6 @@ static int hash_init(struct ahash_request *req)
}
}
}
-out:
return 0;
}
--
1.7.10
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v2 0/3] Update for ux500 CRYP and HASH
2012-05-10 8:14 [PATCH v2 0/3] Update for ux500 CRYP and HASH Andreas Westin
` (2 preceding siblings ...)
2012-05-10 8:14 ` [PATCH v2 3/3] crypto: ux500: Cleanup hardware identification Andreas Westin
@ 2012-05-10 10:55 ` Arnd Bergmann
2012-05-10 13:18 ` Linus Walleij
2012-05-15 7:26 ` Herbert Xu
5 siblings, 0 replies; 7+ messages in thread
From: Arnd Bergmann @ 2012-05-10 10:55 UTC (permalink / raw)
To: Andreas Westin
Cc: Herbert Xu, David S. Miller, linux-crypto, sfr, lee.jones,
linus.walleij
On Thursday 10 May 2012, Andreas Westin wrote:
> Hi,
>
> V2 of the patches.
>
> * Removed symbol export
> * Removed usage of SOC specific functions in the drivers.
> * Readded overlooked config for DMA in mach-ux500.
>
> After some internal discussion we felt that the now implemented
> hardware identification solution is cleaner than the suggested
> solution.
>
> The hardware identification patch applies cleanly to
> the cryptodev tree.
Looks good to me,
Acked-by: Arnd Bergmann <arnd@arndb.de>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2 0/3] Update for ux500 CRYP and HASH
2012-05-10 8:14 [PATCH v2 0/3] Update for ux500 CRYP and HASH Andreas Westin
` (3 preceding siblings ...)
2012-05-10 10:55 ` [PATCH v2 0/3] Update for ux500 CRYP and HASH Arnd Bergmann
@ 2012-05-10 13:18 ` Linus Walleij
2012-05-15 7:26 ` Herbert Xu
5 siblings, 0 replies; 7+ messages in thread
From: Linus Walleij @ 2012-05-10 13:18 UTC (permalink / raw)
To: Andreas Westin
Cc: Herbert Xu, David S. Miller, linux-crypto, arnd, sfr, lee.jones
On Thu, May 10, 2012 at 10:14 AM, Andreas Westin
<andreas.westin@stericsson.com> wrote:
> * Removed symbol export
> * Removed usage of SOC specific functions in the drivers.
> * Readded overlooked config for DMA in mach-ux500.
>
> After some internal discussion we felt that the now implemented
> hardware identification solution is cleaner than the suggested
> solution.
>
> The hardware identification patch applies cleanly to
> the cryptodev tree.
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2 0/3] Update for ux500 CRYP and HASH
2012-05-10 8:14 [PATCH v2 0/3] Update for ux500 CRYP and HASH Andreas Westin
` (4 preceding siblings ...)
2012-05-10 13:18 ` Linus Walleij
@ 2012-05-15 7:26 ` Herbert Xu
5 siblings, 0 replies; 7+ messages in thread
From: Herbert Xu @ 2012-05-15 7:26 UTC (permalink / raw)
To: Andreas Westin
Cc: David S. Miller, linux-crypto, arnd, sfr, lee.jones,
linus.walleij
On Thu, May 10, 2012 at 10:14:05AM +0200, Andreas Westin wrote:
> Hi,
>
> V2 of the patches.
>
> * Removed symbol export
> * Removed usage of SOC specific functions in the drivers.
> * Readded overlooked config for DMA in mach-ux500.
>
> After some internal discussion we felt that the now implemented
> hardware identification solution is cleaner than the suggested
> solution.
>
> The hardware identification patch applies cleanly to
> the cryptodev tree.
>
> Regards
> Andreas
>
> Andreas Westin (3):
> mach-ux500: Crypto: core support for CRYP/HASH module.
> crypto: ux500: Update DMA handling for 3.4
> crypto: ux500: Cleanup hardware identification
All applied. Thanks a lot!
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2012-05-15 7:26 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-10 8:14 [PATCH v2 0/3] Update for ux500 CRYP and HASH Andreas Westin
2012-05-10 8:14 ` [PATCH v2 1/3] mach-ux500: Crypto: core support for CRYP/HASH module Andreas Westin
2012-05-10 8:14 ` [PATCH v2 2/3] crypto: ux500: Update DMA handling for 3.4 Andreas Westin
2012-05-10 8:14 ` [PATCH v2 3/3] crypto: ux500: Cleanup hardware identification Andreas Westin
2012-05-10 10:55 ` [PATCH v2 0/3] Update for ux500 CRYP and HASH Arnd Bergmann
2012-05-10 13:18 ` Linus Walleij
2012-05-15 7:26 ` Herbert Xu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).