Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp4132928rwl; Mon, 10 Apr 2023 06:43:14 -0700 (PDT) X-Google-Smtp-Source: AKy350ZwdnCPK5P2xR6GzZBS/L8gsf6Ssm5ycpzQ+1zsVg5EYtzevjEAE30uDsDickBjrelbVw6Z X-Received: by 2002:a17:906:208a:b0:92c:fc0:b229 with SMTP id 10-20020a170906208a00b0092c0fc0b229mr6926201ejq.0.1681134193859; Mon, 10 Apr 2023 06:43:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681134193; cv=none; d=google.com; s=arc-20160816; b=Mh0OYjASZqyxOig2mJTckKzz7CYznan0mHZ+4GbuCS2emm2Jdv+lsCWTDlMFeyHVin FYdmKHVwoqzUwCOAl9G5pkShHlemglesXKkDdIedlep/K3y0+pwSXmjTxJbdv4Xp32Ww Id3ACbCmLpT/xu0qjwixlyAF4Cd8A3+KjSBP9OGzYcspyzw00W1zZWNN6H3Z+tUge7v5 2KY6jITqc9f7v50cNdUpIQGefoMchwKDjHnsHGsidz9niOkBnYkhTrk4vBh9lTW4Jp8f t4YTCaemMbiwayC3TlDGpdjSkghrY1M/VOk28OFD3aVRblcBj2yOV2PllX98EMiTReTE BzsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from; bh=04kqj3tg47YjR6yLnLdTvzngcN3L0J6PaN5tOCH9qu4=; b=qqoWtjdkfRJJ1JfbCbQjV1x/tQVVqOibeESGIQMtf+i4gcDb5Y468D1qUp+W4lLqj4 Xmrj+XYdVlwq0U1t2FLCvURq7HA+gqRQafj/CnWj+62Ab29sEywlTMtCQadYwfrk9p1B e1q28jrM8KyfOZ35uCJQFhU24p7PrscsCP95yXpQcUR0YoRb5nG1yg2uud8P/MJzky40 3ZZ8uqr9uYeBtdOqKOn7YMPZ9p3g21Oqzrd+OGIQj1YwCgVhYTrAkeexC9D3Wc4xPusO /SP2IhVmzsNq1WKnzMXDqAfdiq0vDgGSHuU5JXDQa1cx1ndKLPmSPJ+x8XX+PZXb2rbI PCLg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z2-20020a170906270200b00946f79be789si8112500ejc.985.2023.04.10.06.42.48; Mon, 10 Apr 2023 06:43:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229697AbjDJNf7 convert rfc822-to-8bit (ORCPT + 99 others); Mon, 10 Apr 2023 09:35:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58140 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229536AbjDJNf6 (ORCPT ); Mon, 10 Apr 2023 09:35:58 -0400 Received: from fd01.gateway.ufhost.com (fd01.gateway.ufhost.com [61.152.239.71]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BBE624C09; Mon, 10 Apr 2023 06:35:54 -0700 (PDT) Received: from EXMBX165.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX165", Issuer "EXMBX165" (not verified)) by fd01.gateway.ufhost.com (Postfix) with ESMTP id EF6EC24E171; Mon, 10 Apr 2023 21:35:44 +0800 (CST) Received: from EXMBX164.cuchost.com (172.16.7.74) by EXMBX165.cuchost.com (172.16.6.75) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 10 Apr 2023 21:35:45 +0800 Received: from EXMBX168.cuchost.com (172.16.6.78) by EXMBX164.cuchost.com (172.16.6.74) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 10 Apr 2023 21:35:44 +0800 Received: from EXMBX168.cuchost.com ([fe80::3c2d:dee5:4938:3fc4]) by EXMBX168.cuchost.com ([fe80::3c2d:dee5:4938:3fc4%16]) with mapi id 15.00.1497.044; Mon, 10 Apr 2023 21:35:44 +0800 From: JiaJie Ho To: Herbert Xu CC: "David S . Miller" , Rob Herring , Krzysztof Kozlowski , Palmer Dabbelt , Emil Renner Berthing , Conor Dooley , "linux-crypto@vger.kernel.org" , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-riscv@lists.infradead.org" Subject: RE: [PATCH v4 4/4] crypto: starfive - Add hash and HMAC support Thread-Topic: [PATCH v4 4/4] crypto: starfive - Add hash and HMAC support Thread-Index: AQHZa3+jdYvISdTjqUmPzN0mADxyja8jpS2AgACU6YD//5HogIAAsqtQ//+FIACAAIes4A== Date: Mon, 10 Apr 2023 13:35:44 +0000 Message-ID: <2b33000067d54d9e83d5a81ef102d2a9@EXMBX168.cuchost.com> References: <20230410073752.39506-1-jiajie.ho@starfivetech.com> <20230410073752.39506-5-jiajie.ho@starfivetech.com> <6df549e9-d0f6-23ca-882f-527c4e40b553@starfivetech.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [161.142.156.149] x-yovoleruleagent: yovoleflag Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-Spam-Status: No, score=-0.0 required=5.0 tests=RCVD_IN_MSPIKE_H2, SPF_HELO_PASS,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org > > The sequence of event would be: > > 1. Wait for DMA transfer to complete. > > 2. Set bit in device CSR to indicate final block has been transferred. > > OK, 2 should be done in the DMA callback function. > > > 3. Device will send IRQ once result is ready. > > 4. Read out final digest value from device. > > 4 should be done from a tasklet scheduled from the IRQ handler. > I'll update the driver accordingly. Thanks again for the advice. Regards, Jia Jie