Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp3058134imm; Mon, 10 Sep 2018 10:19:17 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYcUD8Oc/tdmMK8QK9jLoShmHCpve4p8SKZFCsM3tQYTUw1RCRI4W2iJljFjO82jf7ag/cR X-Received: by 2002:a17:902:3a2:: with SMTP id d31-v6mr22960662pld.287.1536599957497; Mon, 10 Sep 2018 10:19:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536599957; cv=none; d=google.com; s=arc-20160816; b=YnPE0zJC6KWdLHcsZiuFDqiSRtoswEXsmK97J43yE8QoTAkkyBu++pTNrwMl0IfluD rmzGQTDgkrbmdbaE9wRF8MJ5AZp2HjGcSZu4xRzIAOfIbn/skupY+E6zVuQ7EVvsQAAH V+YnG+RfJkTbpZFTCTQItUmYVLPmv6jpP7bT7RORQ95AfHpRXcIWRC/APvhWfpW2Dad7 12M7ikiAWORAPf+qOS7tWA9qxi2tFzJ8W+4c9oisZMoU+ojxkJ2W0bdLNeXK3sctrM6z cylcY+jEZkfJjo8HOoF7cQIJpYll4iMTBsUuj3GS9iY7c7UkzThdgZjKgC1zSsAOnFQZ xIrQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=3T+RFKUwqGm193wP2AxcbAKv8MqAbTWdgGXY/N5idpw=; b=Kw3oSs39vj0ICA7gGOEP7Rf4CqzGfmk7rmJKl9DaYvqMRmKPAOSw3SDZ17XHyHzfi/ ofk7MeCswMV3qLCvQiJowiLDIOMYAsAzFcWDLOCvWYX3LQP1w/hQ85XFGuuBzAFx8KKV dJauawqdsuN9SZhT8qdv3K5/NR5VGOpvthyPbQ2yCs+6W6gwUGl5Xg0hxd8NfpOn5rPm g0SEKb8BpHnspOzN98A+hQATagGpt2q1SmW7smklYd4nRV4RZ7eYEk6eIzWfxd+a2nty FB31Is1Zw88Gp2N98dNX+9RNw5bHn70a5obVIqkP3koY0clJxyVwa2B8TdhYfB99kPup y1gA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z21-v6si16382151pgu.163.2018.09.10.10.19.02; Mon, 10 Sep 2018 10:19:17 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728436AbeIJWLd (ORCPT + 99 others); Mon, 10 Sep 2018 18:11:33 -0400 Received: from inva020.nxp.com ([92.121.34.13]:59474 "EHLO inva020.nxp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726783AbeIJWLc (ORCPT ); Mon, 10 Sep 2018 18:11:32 -0400 Received: from inva020.nxp.com (localhost [127.0.0.1]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 1ECDA1A00BB; Mon, 10 Sep 2018 19:16:26 +0200 (CEST) Received: from inva024.eu-rdc02.nxp.com (inva024.eu-rdc02.nxp.com [134.27.226.22]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 126121A003C; Mon, 10 Sep 2018 19:16:26 +0200 (CEST) Received: from enigma.ea.freescale.net (enigma.ea.freescale.net [10.171.81.110]) by inva024.eu-rdc02.nxp.com (Postfix) with ESMTP id 87A192060B; Mon, 10 Sep 2018 19:16:25 +0200 (CEST) From: =?UTF-8?q?Horia=20Geant=C4=83?= To: Herbert Xu , Stuart Yoder , Laurentiu Tudor , Li Yang , Roy Pledge , Catalin Marinas , Will Deacon Cc: "David S . Miller" , Aymen Sghaier , linux-crypto@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 00/11] crypto: caam - add DPAA2 (DPSECI) driver Date: Mon, 10 Sep 2018 20:15:39 +0300 Message-Id: <20180910171550.5659-1-horia.geanta@nxp.com> X-Mailer: git-send-email 2.16.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Virus-Scanned: ClamAV using ClamSMTP Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, This patch set adds the CAAM crypto engine driver for DPAA2 (Data Path Acceleration Architecture v2) found on ARMv8-based SoCs like LS1088A, LS2088A, LX2160A. Previously sent RFC can be found here: https://www.mail-archive.com/linux-crypto@vger.kernel.org/msg27290.html Driver consists of: -DPSECI (Data Path SEC Interface) backend - low-level API that allows to manage DPSECI devices (DPAA2 objects) that sit on the Management Complex (MC) fsl-mc bus -algorithms frontend - AEAD, skcipher and ahash algorithms implementation Patches 1-4 are fsl-mc bus and DPIO dependencies. Stuart, Laurentiu, Leo, Roy, please review the patches and let me know if you have anything against going with them through the cryptodev tree. Patches 5-10 are the core of the patch set, adding the driver. For symmetric encryption the new skcipher interface is used. Patch 11 enables driver on arm64. It will be built only if dependency on DPIO (CONFIG_FSL_MC_DPIO) is satisfied. Note: multiple modprobe/rmmod won't work without the following patches [5/7,v7] bus/fsl-mc: support dma configure for devices on fsl-mc bus https://patchwork.kernel.org/patch/10594179 [7/7,v7] arm64: dts: ls208xa: comply with the iommu map binding for fsl_mc https://patchwork.kernel.org/patch/10594171 (for LS1088A a similar DT update is needed) Thanks, Horia Horia Geantă (11): bus: fsl-mc: add support for dpseci device type Revert "staging: fsl-mc/dpio: remove couple of unused functions" soc: fsl: dpio: add frame list format support soc: fsl: dpio: add congestion notification support crypto: caam - add DPAA2-CAAM (DPSECI) backend API crypto: caam - add Queue Interface v2 error codes crypto: caam/qi2 - add DPAA2-CAAM driver crypto: caam/qi2 - add skcipher algorithms crypto: caam - export ahash shared descriptor generation crypto: caam/qi2 - add support for ahash algorithms arm64: defconfig: enable CAAM crypto engine on QorIQ DPAA2 SoCs arch/arm64/configs/defconfig | 1 + drivers/bus/fsl-mc/fsl-mc-bus.c | 5 + drivers/crypto/Makefile | 2 +- drivers/crypto/caam/Kconfig | 55 +- drivers/crypto/caam/Makefile | 10 +- drivers/crypto/caam/caamalg_qi2.c | 5165 +++++++++++++++++++++++++++++++++++ drivers/crypto/caam/caamalg_qi2.h | 223 ++ drivers/crypto/caam/caamhash.c | 79 +- drivers/crypto/caam/caamhash_desc.c | 80 + drivers/crypto/caam/caamhash_desc.h | 21 + drivers/crypto/caam/compat.h | 1 + drivers/crypto/caam/dpseci.c | 426 +++ drivers/crypto/caam/dpseci.h | 333 +++ drivers/crypto/caam/dpseci_cmd.h | 149 + drivers/crypto/caam/error.c | 79 +- drivers/crypto/caam/error.h | 6 +- drivers/crypto/caam/regs.h | 2 + drivers/soc/fsl/dpio/dpio-service.c | 58 + include/linux/fsl/mc.h | 6 + include/soc/fsl/dpaa2-fd.h | 242 ++ include/soc/fsl/dpaa2-global.h | 15 + include/soc/fsl/dpaa2-io.h | 4 + 22 files changed, 6871 insertions(+), 91 deletions(-) create mode 100644 drivers/crypto/caam/caamalg_qi2.c create mode 100644 drivers/crypto/caam/caamalg_qi2.h create mode 100644 drivers/crypto/caam/caamhash_desc.c create mode 100644 drivers/crypto/caam/caamhash_desc.h create mode 100644 drivers/crypto/caam/dpseci.c create mode 100644 drivers/crypto/caam/dpseci.h create mode 100644 drivers/crypto/caam/dpseci_cmd.h -- 2.16.2