Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp1259039rwe; Thu, 25 Aug 2022 20:08:53 -0700 (PDT) X-Google-Smtp-Source: AA6agR7IKM1/5SF17fJ82pvhpMH6g5vP3zHsFVYkvZqUjWOQ81YUtENH9eXTV/vtZvPt7Kxp9eM3 X-Received: by 2002:a17:906:cc16:b0:73d:d16c:609f with SMTP id ml22-20020a170906cc1600b0073dd16c609fmr3543844ejb.691.1661483333263; Thu, 25 Aug 2022 20:08:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661483333; cv=none; d=google.com; s=arc-20160816; b=D9Ime/jlJXXr57L/Uy6oifu0HYclAlriYL21Gm7XF6CaZiZT0XQ0PRckVAFRKuG+fD TFBWohKmxm9b/B8dKudDtmYzPRymLEU1anPLCNjMW+vQqqq6TuSMHWjHz+X946RlbP66 qH/CLgSs6jwHKpU0tdjppTJUzEO3eY6H368IbXV/HDCI+7osisRIuytH387crnuO/B7p OA3JNQximkEjmtE0TIc4sSfRCnCybqsdO8L+cRz1g90epj8Cz0DsI7YDqJ3mtz9+IItp xc+r2L1xwrwlPnpXP0zO7xoKeIu0ycPn61lsP6LhtkhGGmO1oa4BQR3aHxETfsTpGGgm CyDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=kLa4w3V1pPXu4+MVAh+HONKm20Az4oVt6VNAUyh+XgA=; b=AruRZmIK7tieSvF1arbnHnA5dQQhJM/ervmn29eZDFxg/BXdtZtJ9r9q+2QbGF7fd1 KJ6Q90/kuS9MIbZJtCdabX8+Y05uoRZkVGdut/ORNTTAcbvXxcXHcjZ9MuAp7Dxmhx++ j3ia2rMr5fFkAITppNVOsEkZ5fS2Y8LFvhiGJI7v4yd0jleXZ3SuigqWOF4fn0I05MS6 5J1bRXWye5jS0cHJ3WlZXvgpihQZ/Ukf48duFNSNiKvVZoNkH2WY+SEcK3FL+ydwvPE5 bl0hajVjah5Vghj4F6mxoD18/4zX3uIEkoKkHi8+j1uSuT1UaoSc8rYagJniwWHD1FG2 PAwQ== 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 hg6-20020a1709072cc600b00733b061e7bdsi421606ejc.637.2022.08.25.20.08.09; Thu, 25 Aug 2022 20:08:52 -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 S244899AbiHZCwz (ORCPT + 99 others); Thu, 25 Aug 2022 22:52:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38100 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229536AbiHZCwz (ORCPT ); Thu, 25 Aug 2022 22:52:55 -0400 Received: from fornost.hmeau.com (helcar.hmeau.com [216.24.177.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4440FCCE3B for ; Thu, 25 Aug 2022 19:52:52 -0700 (PDT) Received: from gwarestrin.arnor.me.apana.org.au ([192.168.103.7]) by fornost.hmeau.com with smtp (Exim 4.94.2 #2 (Debian)) id 1oRPSf-00FHsU-1c; Fri, 26 Aug 2022 12:52:46 +1000 Received: by gwarestrin.arnor.me.apana.org.au (sSMTP sendmail emulation); Fri, 26 Aug 2022 10:52:44 +0800 Date: Fri, 26 Aug 2022 10:52:44 +0800 From: Herbert Xu To: "Elliott, Robert (Servers)" Cc: "tim.c.chen@linux.intel.com" , Taehee Yoo , "davem@davemloft.net" , "linux-crypto@vger.kernel.org" , "mingo@redhat.com" , "bp@alien8.de" , "dave.hansen@linux.intel.com" , "x86@kernel.org" , "Kani, Toshi" , "Wright, Randy (HPE Servers Linux)" Subject: Re: [PATCH] crypto: x86/sha512 - load based on CPU features Message-ID: References: <20220813230431.2666-1-elliott@hpe.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,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 Fri, Aug 26, 2022 at 02:40:58AM +0000, Elliott, Robert (Servers) wrote: > > Suggestion: please revert the sha512-x86 patch for a while. This problem would have existed anyway if the module was built into the kernel. > Do these functions need to break up their processing into smaller chunks > (e.g., a few Megabytes), calling kernel_fpu_end() periodically to > allow the scheduler to take over the CPUs if needed? If so, what > chunk size would be appropriate? Yes these should be limited to 4K each. It appears that all the sha* helpers in arch/x86/crypto have the same problem. Cheers, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt