Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp1097776pxp; Thu, 17 Mar 2022 02:47:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx8qUspfTCtBJl3UnyOjjjvqsJaP7wfK5lQ2hpTIq2xFBJ+9AnYdt5fLwvGZfDMwFOA6xyP X-Received: by 2002:a17:906:1e4c:b0:6cf:7429:cfea with SMTP id i12-20020a1709061e4c00b006cf7429cfeamr3682802ejj.158.1647510446107; Thu, 17 Mar 2022 02:47:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1647510446; cv=none; d=google.com; s=arc-20160816; b=yS9AcMXOc4UVIbEUMcyfG0CguSdriPfqNhWfa8gihMPQ3skEzdcwWyBafn4Di4Mpjv L9P3YckKofqA+2cTiaJv6NUiib1ZRWrzA01Prl8+i52UDvLj1KuiBUXs6kU2JiqkIOT5 EfsjzRm/pKypZUVpo4kQakiqoOnN3qXAYPeCJ4md+2ebx9zj+BMFP1xIC8tYgoFM6n6z lSdC7Oi8ExmerXnj9UopQgZx1BCA3Twmh52sEFnRHYABIEKdzCHFfXeRYeNT6j8viPKq OZasmIzLppKxObUM4bNrvqeMz7Cj3188GPEj6nMUvHwcxE7o//n8TB1TZpGFA5tTAAe7 Ajrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent :content-transfer-encoding:references:in-reply-to:date:cc:to:from :subject:message-id; bh=JL2x9T9Zahp9hJ+nN1OUS1efH8IeUsg19eDrOPKT8Q4=; b=XZRWtIOqFf8qNfqhnD40WVf4o1gB86DRLqXKBKRhwpbqdzjRcGxnHmqjYobCXbfHj+ 6JHWCWfys6ScKjlGfkGiDy8ARnFxKsEPGjvX9ibYUcNLM2vsaj6rKfoyhQVEQUu2OshS SXv5w6vyByseJKzaIEiVRvdlByiYNszx22A60gUf2oppIzW0KAgwMyT3X1+ZcBD86YC/ IOjTyiPhE9gC+1c86rd5k9aYsJo+Hj2iQzIG5NXw2FAgQPvRIV939VjheTn8h6tmsXMh /EqQ/84eklMmCnhLTNR/SqXfDB/8Vk8M88iHF1ecLlt7fMsTqnrTySHo/gRTqdWyOtR5 JLnA== 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 b17-20020a50b411000000b00418c2b5bf7bsi1154555edh.605.2022.03.17.02.46.52; Thu, 17 Mar 2022 02:47:26 -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 S229824AbiCQJCX convert rfc822-to-8bit (ORCPT + 99 others); Thu, 17 Mar 2022 05:02:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34490 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230514AbiCQJCX (ORCPT ); Thu, 17 Mar 2022 05:02:23 -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 38DFB1D08C3 for ; Thu, 17 Mar 2022 02:01:05 -0700 (PDT) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nUm0B-0002l7-6O; Thu, 17 Mar 2022 10:00:59 +0100 Received: from [2a0a:edc0:0:900:1d::4e] (helo=lupine) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1nUm0A-001DY9-Hf; Thu, 17 Mar 2022 10:00:57 +0100 Received: from pza by lupine with local (Exim 4.94.2) (envelope-from ) id 1nUm08-0002xO-1q; Thu, 17 Mar 2022 10:00:56 +0100 Message-ID: Subject: Re: [PATCH] crypto: algapi - Remove test larvals to fix error paths From: Philipp Zabel To: Herbert Xu , Ard Biesheuvel Cc: Linux Crypto Mailing List , kernel@pengutronix.de, "David S. Miller" Date: Thu, 17 Mar 2022 10:00:56 +0100 In-Reply-To: References: <20220126145322.646723-1-p.zabel@pengutronix.de> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT User-Agent: Evolution 3.38.3-1 MIME-Version: 1.0 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: p.zabel@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=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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 On Do, 2022-03-17 at 10:10 +1200, Herbert Xu wrote: > On Wed, Mar 16, 2022 at 08:23:24AM +0100, Ard Biesheuvel wrote: > > > > According to the bisect log in the other thread, > > adad556efcdd42a1d9e060cb is the culprit, which does not seem > > surprising, at is would result in the SIMD skcipher being > > encapsulated > > to not be available yet when the SIMD helper tries to take a > > reference > > to it. > > It's supposed to work because any use of an algorithm prior to > the tests starting will automatically trigger the test right away. > I confirmed this by booting the kernel in qemu with AES_ARM_BS=y > and it successfully registered those algorithms and passed the > self-tests. > > Someone else has already sent me a complete kconfig file which > hopefully should reproduce the crash for me. It seems you already did. I can confirm that [1] fixes the crash for me, as I had CRYPTO_CBC disabled. After enabling it, aes_init() doesn't hit the error path anymore, hiding the BUG() again. [1] https://lore.kernel.org/all/YjJq0RLIHvN7YWaT@gondor.apana.org.au/ regards Philipp