Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp4972336iob; Mon, 9 May 2022 06:05:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxEwalgdGecACwkoBFMenM4kdTK4OyWKUhVkXJACOmLeqGx80AwI2yvqOvM5fuZQjOWX7Sv X-Received: by 2002:a02:6d24:0:b0:32b:3685:c84e with SMTP id m36-20020a026d24000000b0032b3685c84emr6821312jac.51.1652101509559; Mon, 09 May 2022 06:05:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652101509; cv=none; d=google.com; s=arc-20160816; b=GtvHUXvPXAWypNXgk5F3qNb5sTz3LLqC5WtpT1bn4AmCR638JGtpLFToShFCh5jzsn EUuPdm4tW7yXYedvq2Zxefj2E1dQ7mGHBlvhwygar4K2h1XkJdv7d1JWTKorbV2SeM6M oQ/wukkX6ev5JPgqqz51ZkBA5DBpd1IoFpQbg4EaOrvUfsRfAiiX97/tY1LjvDgzUDXx c7AWLzTT13736ml8j2deKcyDaehKaVUC1XvvUxUH19PVrCtnM47Q2izFvljBzCFqEdYm RElY/QZQ/y1dSkGfidg/jjVKC9f5veC/X1xMeEdRzXQ7ZT54iGKSG5xhG4oh/8PJ/RBH jeng== 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 :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=bhSKcjoswVsNiFjtNlsd6ZANyGQyr7J9394VTpwLTp4=; b=w84FQxrM0NKY3caVGMSJ/3WhysGdHYIjG9GB4HZFNPRvThFFnj9Gwz3qtmm/fLFW6q /TqpA4HMHEmDj86FxqWCp0IzdGWP6d9MtszB7EEJvB+zyCmxurgg1xyhx9Miy8oiU6mL J6ghxAzEqwFKFVIua6zjEzKQHxBrl+ZGJ6YLNXyOqNPTwvKIgA9bnAfC6M0Q2L1g5DjF Wk0Lhth0PJYvL/KEBb+JZeIFoXE0ozKpU13WhWfMiw1iqB+SRDlrLPIVA8EOVVhEoDJu P5psRNqs2XW8TsCNXhyMKaYoGuNHr8yFr7bIPgLmJxVsnlIHCNMBiThkhrWurUZ1mqG9 E8og== 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:18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id l3-20020a056e021aa300b002cf2bd5a2c6si8797443ilv.149.2022.05.09.06.05.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 May 2022 06:05:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 30E2222A2E1; Mon, 9 May 2022 06:05:07 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235121AbiEINI6 (ORCPT + 99 others); Mon, 9 May 2022 09:08:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58396 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235111AbiEINI6 (ORCPT ); Mon, 9 May 2022 09:08:58 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 78AA523276A for ; Mon, 9 May 2022 06:05:04 -0700 (PDT) Received: from birne.office.stw.pengutronix.de ([2a0a:edc0:0:900:1d::51]) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1no33x-0005Ao-B0; Mon, 09 May 2022 15:04:33 +0200 Message-ID: <5e7c0b3c9bc285f1cf9f7b20f055aa376e1688cc.camel@pengutronix.de> Subject: Re: [EXT] [PATCH v9 3/7] crypto: caam - determine whether CAAM supports blob encap/decap From: Ahmad Fatoum To: Pankaj Gupta , Horia Geanta , Herbert Xu , "David S. Miller" Cc: "kernel@pengutronix.de" , Michael Walle , James Bottomley , Jarkko Sakkinen , Mimi Zohar , David Howells , James Morris , Eric Biggers , "Serge E. Hallyn" , Jan Luebbe , David Gstir , Richard Weinberger , Franck Lenormand , Matthias Schiffer , Sumit Garg , "linux-integrity@vger.kernel.org" , "keyrings@vger.kernel.org" , "linux-crypto@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-security-module@vger.kernel.org" Date: Mon, 09 May 2022 15:04:20 +0200 In-Reply-To: References: <20220506062553.1068296-1-a.fatoum@pengutronix.de> <20220506062553.1068296-4-a.fatoum@pengutronix.de> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.38.3-1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 2a0a:edc0:0:900:1d::51 X-SA-Exim-Mail-From: a.fatoum@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-crypto@vger.kernel.org X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Hello Pankaj, On Mon, 2022-05-09 at 12:39 +0000, Pankaj Gupta wrote: > > -       if (ctrlpriv->era < 10) > > +       comp_params = rd_reg32(&ctrl->perfmon.comp_parms_ls); > > +       ctrlpriv->blob_present = !!(comp_params & CTPR_LS_BLOB); > > + > > +       if (ctrlpriv->era < 10) { > >                 rng_vid = (rd_reg32(&ctrl->perfmon.cha_id_ls) & > >                            CHA_ID_LS_RNG_MASK) >> > > CHA_ID_LS_RNG_SHIFT; > > Check for AES CHAs for Era < 10, should be added. Do I need this? I only do this check for Era >= 10, because apparently there are Layerscape non-E processors that indicate BLOB support via CTPR_LS_BLOB, but fail at runtime. Are there any Era < 10 SoCs that are similarly broken? Cheers, Ahmad