Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3071604pxk; Sun, 4 Oct 2020 23:47:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwThqOgyW9s2rCRSn3WBIAEDgQExatf5qhd4MhPdaeYfOLo4r5t1+UxrJ6mGB9uP9hPRGFk X-Received: by 2002:a05:6402:5:: with SMTP id d5mr15013589edu.376.1601880466693; Sun, 04 Oct 2020 23:47:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601880466; cv=none; d=google.com; s=arc-20160816; b=RjsZc79Rql44Po6Wf/Mmt5uVi2l1hMLXRVwS8rhY5ziy12SMTjGwxtHm7EOdi/t95+ iE83UDSnpU9XWAh5w64YrHEsamJh0Z0HoV02cJPalWN1SazvUb+UUSpDlWeb0WrZiz90 jmDDliJqfev0JyOKDvFG1/5uFJ0u5nNrmBnP+vWAsuJj2ft6Iz+thaIzCWbXzSixywNi fxGPz9EgSjYagCHmRAcNzsPKJ0ffK22HFIMJ4QsL2qhe4JtxM1D7xAN1EMOU4jp0sQIt XuFIcl601euP1PIJGrdFGAExuekGigOD+dYSiiKg4uJCZZfBFvb1KC9fMLATeX8bvvrt uRlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=wsAVEaV1+h1cDZGoNWJx95GIyKoJhBW7f/aAlsRaZi0=; b=k+aCWmyDmrRcHgFumQVKKNWTwBjzjloUPpM7GrylOpYYyKCK1T9y8BWhGFoV3dMg6v xP30vhZOfSJED9y30jDqbgJGk7k9F/m3XEvdbBuF1Yy9ljoyUmxe1mtdGbPjnwKSSCmH ax8gZ+xukfU4C+zlEiH9ciRNi4AQRpoOHVoJHJ34W2D0HEvdeaJQAITwmtWat+SMTxiC 0I+JiPxIF+1NMawqnFrzQOBUbw/ZHvAq9GZQBUkKS2QHSMIPf6LNyCuorDzXWdYLMSkP DKyxdvrk12Gx2DnlUffzWJ8EvjAICM3MAmwGskaSyjHbnMLyEuipOeqEEgmuACfdGt+A kVMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=i8rGxo6J; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g16si6306191edm.68.2020.10.04.23.47.22; Sun, 04 Oct 2020 23:47:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=i8rGxo6J; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725885AbgJEGov (ORCPT + 99 others); Mon, 5 Oct 2020 02:44:51 -0400 Received: from mail.kernel.org ([198.145.29.99]:35520 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725881AbgJEGov (ORCPT ); Mon, 5 Oct 2020 02:44:51 -0400 Received: from mail-oi1-f180.google.com (mail-oi1-f180.google.com [209.85.167.180]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D8B162083B; Mon, 5 Oct 2020 06:44:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601880291; bh=wsAVEaV1+h1cDZGoNWJx95GIyKoJhBW7f/aAlsRaZi0=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=i8rGxo6JPfgAgmgQZLNkgC4n7PLiYYbnTKY/fMM8grr7zqt7WfvBskF/auZcnUYLp Lr20+zeyZ3g7xCTbOdEwbqxVo67XfcUT2iuncGiJ8fm4z4r846eH988apXeGGmHxLX o/SuOxWdx+53ExQovJWw5yYVDs0pwP8+ve5nTTqM= Received: by mail-oi1-f180.google.com with SMTP id z26so7755266oih.12; Sun, 04 Oct 2020 23:44:50 -0700 (PDT) X-Gm-Message-State: AOAM530CdnNO2FYqXThAs4nBiS22Ehf9YxsbhMiNohf1xeDGnZY0oJNb Un+CcFtRNxOsDdD2JnYtsDvn8GyQboKJz/BH0Ww= X-Received: by 2002:aca:d845:: with SMTP id p66mr7393683oig.47.1601880290247; Sun, 04 Oct 2020 23:44:50 -0700 (PDT) MIME-Version: 1.0 References: <20200930065617.934638-1-palmerdabbelt@google.com> <20201005061918.GB1856@infradead.org> <2588700.mWSkj6HvKX@tauon.chronox.de> In-Reply-To: <2588700.mWSkj6HvKX@tauon.chronox.de> From: Ard Biesheuvel Date: Mon, 5 Oct 2020 08:44:39 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] crypto: jitterentropy - bind statically into kernel To: Stephan Mueller Cc: Christoph Hellwig , Palmer Dabbelt , linux-riscv , Android Kernel Team , kernel test robot , Linux Crypto Mailing List , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Mon, 5 Oct 2020 at 08:40, Stephan Mueller wrote: > > Am Montag, 5. Oktober 2020, 08:24:46 CEST schrieb Ard Biesheuvel: > > Hi Ard, > > > If jitterentropy is a special case, we could put a alternate > > non-'static inline' version of random_get_entropy() in the core > > kernel, and only export it if JITTER_ENTROPY is built as a module in > > the first place. But I'd prefer it if jitterentropy switches to an API > > that is suitable for driver consumption. > > Which API do you have in mind? In user space, I use > clock_gettime(CLOCK_REALTIME) which also considers the clock source. > AFAICT, that call is backed by ktime_get_real_ts64(), which is already being exported to modules. Could you please check whether that works for your driver?