From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3F493C33CB2 for ; Tue, 14 Jan 2020 17:44:43 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1751E24672 for ; Tue, 14 Jan 2020 17:44:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="WQn1DywC"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="k+3H4akS" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1751E24672 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=tjeMiFn8A6jXF69bTpJPiagb7nvAq2XPZLY9MPSl9vg=; b=WQn1DywCY/z8TH cUggwiLNfPrfQFPeHDT/2OMNSe7Z1Leb88CjbH5KuIqpuRYOpERPPqsfloiMCJGUIl1ufVjsW7+te ZYl/Mbs1/azQjoBDu2yxtrW7Wx1NROXubGD+MKOqeupGmrhM5DfzuXwv8YdCsU+P5fdnfFuzD7cmv gamQ+VEy2kcu65BmBG4pICtp8xfQrECdpa7y8tYsHpL2IJrl0A9cUuYx/CRYs6Zhc4pDeKpkKK9/O S/9dxhJU6c/Ue4RglB2/mKwL517DeEeYaB5tuItURUzSBQpbrTuFcJ5VMHPEhH3lxsn4Qw12ag6Jy H/C2TibgznnDz3NFtgeQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1irQF8-0004Yu-MU; Tue, 14 Jan 2020 17:44:42 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1irQF3-0004YZ-LY for linux-arm-kernel@lists.infradead.org; Tue, 14 Jan 2020 17:44:41 +0000 Received: from willie-the-truck (236.31.169.217.in-addr.arpa [217.169.31.236]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 1DEB624672; Tue, 14 Jan 2020 17:44:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1579023877; bh=olZ5Cv5PTLVj2njm9+EeD4d9/vlfVQmwt2xeqaU+yik=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=k+3H4akSEiQNEXTEwjxub0hwdddVYk4OTlqZYP019fOXScML/ajigPRepoe9B9lGW J5NrCmkq3mE/Z+Ad/4DRRfbPtXHRy/0j2K9JWywPkEjBJ9UtFGI4qABIE0d5gwWdaf DVbc37sDxUxxH6cbSby+ix+1+gh3KeeSFdb22kS8= Date: Tue, 14 Jan 2020 17:44:32 +0000 From: Will Deacon To: Mark Brown Subject: Re: [PATCH v10 1/3] arm64: Implement archrandom.h for ARMv8.5-RNG Message-ID: <20200114174432.GG2579@willie-the-truck> References: <20200110122341.8445-1-broonie@kernel.org> <20200110122341.8445-2-broonie@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20200110122341.8445-2-broonie@kernel.org> User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200114_094437_732656_911296D9 X-CRM114-Status: GOOD ( 13.90 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Catalin Marinas , Richard Henderson , linux-arm-kernel@lists.infradead.org, Ard Biesheuvel Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Jan 10, 2020 at 12:23:39PM +0000, Mark Brown wrote: > From: Richard Henderson > > Expose the ID_AA64ISAR0.RNDR field to userspace, as the RNG system > registers are always available at EL0. > > Implement arch_get_random_seed_long using RNDR. Given that the > TRNG is likely to be a shared resource between cores, and VMs, > do not explicitly force re-seeding with RNDRRS. In order to avoid > code complexity and potential issues with hetrogenous systems only > provide values after cpufeature has finalized the system capabilities. > > Signed-off-by: Richard Henderson > [Modified to only function after cpufeature has finalized the system > capabilities and move all the code into the header -- broonie] > Signed-off-by: Mark Brown > Reviewed-by: Mark Rutland > --- > Documentation/arm64/cpu-feature-registers.rst | 2 + > arch/arm64/Kconfig | 12 ++++ > arch/arm64/include/asm/archrandom.h | 67 +++++++++++++++++++ > arch/arm64/include/asm/cpucaps.h | 3 +- > arch/arm64/include/asm/sysreg.h | 4 ++ > arch/arm64/kernel/cpufeature.c | 13 ++++ > 6 files changed, 100 insertions(+), 1 deletion(-) > create mode 100644 arch/arm64/include/asm/archrandom.h In which case, should we also add an HWCAP for this? Will _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel