Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1463648pxb; Thu, 4 Feb 2021 13:45:19 -0800 (PST) X-Google-Smtp-Source: ABdhPJwNT4OMupfK+bKAx6u4n5/HIC6I1HXLBMazSOX/JbKd4sZQ6U0QeL2Ms12FTO+X91HDZp8c X-Received: by 2002:a17:906:7f06:: with SMTP id d6mr1027231ejr.169.1612475119166; Thu, 04 Feb 2021 13:45:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1612475119; cv=none; d=google.com; s=arc-20160816; b=QjUxTbJgMi/ZRjXamP++t3du8LohXIx3DI4f3+u0e1Y7/pIv14Tlh6Jar2izgB4ZV8 rkwJAaIJL/TtDFl01j41xV1nCTSqyztVKdS82hfF3dFGOGwhjc5/8ZUtVUWKx/kHU/DR LT9fjcPelKi7/IUZX7DPXeAegPiGQSS0LII+HZPgBiXusB3AGMrwRZKmHDOkn3ryLIUm 9BXwsvy+k7urSCnLeFTn9oBT00vm0ygz5kiCUuSErd7QIvf6ewfZG1P4HZ8JlFxlUMJg 0SUYQMAk0uOzWPJ12r7vZ+AqoCBTInpd977Yyw13/Z/HwW7SJPAn1w+baHiO9ndGk8LH snUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=G6n3XQ08yWZ9lzKICVX9QM9j4Y+beb5V9nQwAwfR7q4=; b=MHV5rxHd3BWghgMi4mr84FoxIsOuEciUBstPUmKtEsQbRwgo3zVEcr8moDTTtYyggC e8A390leYCmMGiIbqnKS7ULplKYf2Kq4ahsanti7KZik1N+4LwxFcyMxETt5aENO8AuA fbbcegGK0ly60OZEv8cVdLkZDm2BkUWGccKoqd/V8sr1+yIbp48ulH/9QJVDU/OYplue U8+zA/Pa9t4m60drZ376VH2fD4ZpRZ0IErNbbhx5Jk1xF/tEZ5wt7K7Qj8SDfOqasjBb WXceiI2TbTNyMlQvfs52h668ViVHbJcXK2sqXRdozDCY+Y6s/1oErKZcD+V9opPGZycU m3AA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="ezB6M2/Q"; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e13si3826887edz.214.2021.02.04.13.44.46; Thu, 04 Feb 2021 13:45:19 -0800 (PST) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="ezB6M2/Q"; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229623AbhBDVoo (ORCPT + 99 others); Thu, 4 Feb 2021 16:44:44 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35206 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229534AbhBDVol (ORCPT ); Thu, 4 Feb 2021 16:44:41 -0500 Received: from mail-qk1-x734.google.com (mail-qk1-x734.google.com [IPv6:2607:f8b0:4864:20::734]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 92DB5C061786 for ; Thu, 4 Feb 2021 13:44:01 -0800 (PST) Received: by mail-qk1-x734.google.com with SMTP id x81so4969764qkb.0 for ; Thu, 04 Feb 2021 13:44:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=G6n3XQ08yWZ9lzKICVX9QM9j4Y+beb5V9nQwAwfR7q4=; b=ezB6M2/QlZUpa1ox9B4HIAOSvCFe8I6qZwJcMTf0enbjJeQreVhgCnVQ1x9DwECQea 5Zo7pvBL8XcjfKNEhZoF18Zcfb1Jw25eI68YktzRsnqiHhJ2UslLMsmDSa1jUwo9wciS UuA5TaVjnnnsna4uPNeqAeCiP0kRVaWnIb8mw78UJc8a+rZYW/LOruL7fk/xTXJc8VPl 2hNaO/oYs0jIAGubvMjJljmrmJ390GNjTZcQ+ADnds58FQuBkuw+waAdoDg6XGr2hTXO 71aayzIbWeCSud8u5pOSwgLqPQWiGBErlgBO1WfwHBl4bZIT5pRRDkxqUIFEk7B55OQM FgpA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=G6n3XQ08yWZ9lzKICVX9QM9j4Y+beb5V9nQwAwfR7q4=; b=Qa5giT2e0HFzZgTZPt0EcbAwrBvOqDDCy1RC9yYEoMZ/xV8YzSVcNbrvuEOwWJ2IjE I7ltslu3GKQAus5gwqMHcS9F9PGgqEfK4rMqh5/GXkn86yXpVI1EbRFyf79hGo5VIC9N LYabgDZRU5xb+emFEO5PaDM63hqOhyUjNXgM/zTBsXr3GbvMM3DbvGIpHwxlig14SpWG hDd50uJtUs9UZsJ4L8QXjCPR1hOzW4WGNbvb78XpJ9zC3tohGgv8q4f0xI0DrOWkyWXN A8zpanXxSFmLUYxDWMHOBs9fjfNCO2Q5WlYbeN3/qmp1rgB42D4Vln16uqbRmRqiaiFx QtDA== X-Gm-Message-State: AOAM531BTX6dps9AiCtPtkZo9OOPnhn3Ew7GAhURhY8ILac+jRf5CXC6 HGl9SXhFpufwhbayIaSP/7idTQ== X-Received: by 2002:a37:68f:: with SMTP id 137mr1207526qkg.420.1612475040654; Thu, 04 Feb 2021 13:44:00 -0800 (PST) Received: from pop-os.fios-router.home (pool-71-163-245-5.washdc.fios.verizon.net. [71.163.245.5]) by smtp.googlemail.com with ESMTPSA id h185sm6353858qkd.122.2021.02.04.13.43.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 04 Feb 2021 13:44:00 -0800 (PST) From: Thara Gopinath To: herbert@gondor.apana.org.au, davem@davemloft.net, bjorn.andersson@linaro.org Cc: ebiggers@google.com, ardb@kernel.org, sivaprak@codeaurora.org, linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v5 00/11] Regression fixes/clean ups in the Qualcomm crypto engine driver Date: Thu, 4 Feb 2021 16:43:48 -0500 Message-Id: <20210204214359.1993065-1-thara.gopinath@linaro.org> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org This patch series is a result of running kernel crypto fuzz tests (by enabling CONFIG_CRYPTO_MANAGER_EXTRA_TESTS) on the transformations currently supported via the Qualcomm crypto engine on sdm845. The first nine patches are fixes for various regressions found during testing. The last two patches are minor clean ups of unused variable and parameters. v4->v5: - Fixed build warning/error in patch for wrong assignment of const pointer as reported by kernel test robot . - Rebased to 5.11-rc6. v3->v4: - Fixed the bug where only two bytes of byte_count were getting saved and restored instead of all eight bytes. Thanks Bjorn for catching this. - Split patch 3 "Fix regressions found during fuzz testing" into 6 patches as requested by Bjorn. - Dropped crypto from all subject headers. - Rebased to 5.11-rc5 v2->v3: - Made the comparison between keys to check if any two keys are same for triple des algorithms constant-time as per Nym Seddon's suggestion. - Rebased to 5.11-rc4. v1->v2: - Introduced custom struct qce_sha_saved_state to store and restore partial sha transformation. - Rebased to 5.11-rc3. Thara Gopinath (11): crypto: qce: sha: Restore/save ahash state with custom struct in export/import crypto: qce: sha: Hold back a block of data to be transferred as part of final crypto: qce: skcipher: Return unsupported if key1 and key 2 are same for AES XTS algorithm crypto: qce: skcipher: Return unsupported if any three keys are same for DES3 algorithms crypto: qce: skcipher: Return error for zero length messages crypto: qce: skcipher: Return error for non-blocksize data(ECB/CBC algorithms) crypto: qce: skcipher: Set ivsize to 0 for ecb(aes) crypto: qce: skcipher: Improve the conditions for requesting AES fallback cipher crypto: qce: common: Set data unit size to message length for AES XTS transformation crypto: qce: Remover src_tbl from qce_cipher_reqctx crypto: qce: Remove totallen and offset in qce_start drivers/crypto/qce/cipher.h | 1 - drivers/crypto/qce/common.c | 25 +++--- drivers/crypto/qce/common.h | 3 +- drivers/crypto/qce/sha.c | 143 +++++++++++++--------------------- drivers/crypto/qce/skcipher.c | 72 ++++++++++++++--- 5 files changed, 129 insertions(+), 115 deletions(-) -- 2.25.1