Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp2981027rdg; Tue, 17 Oct 2023 00:13:47 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF/pkZkT3s1NrBjtefpwY1cHkpwOx2y0oZmCg0Rmvu1PzaWAg4H0v6JseboEa3k3UwvAE4h X-Received: by 2002:a17:902:d4ce:b0:1ca:de3:fcad with SMTP id o14-20020a170902d4ce00b001ca0de3fcadmr1626904plg.59.1697526826340; Tue, 17 Oct 2023 00:13:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697526826; cv=none; d=google.com; s=arc-20160816; b=TjUj1kCY+2F3LG3x1cOe3mO1ZE2Q10cN/3VDMKm2fk7KgroddYZBlx0aGZEDT08hOG 5cV2p/AmZBIIxCmfhEJYgXHvRFKP9nUTvB7ZDxptOB0PW1Y/Inx4cxsT5IIoguHiPEIH yvvvla1RJqiSv41pW6WamnlQHDgoo4NKADkOZHbXtLbV4ZoskXa2EdhmFBrmx9NFAyLg J78LSrHvaJha/zQnXDRVRSwD0uUfDtyfEno2XIlrjd7EFKRnyrEIurWTSkXgah8oL0mK QYb1zvxtC2Sv6QcIDQ6fKnwKbIGzmOgl7z+55pCkVIA6UNhP42lJDvdQNKOP1t6j80w3 xOhQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :organization:autocrypt:references:cc:to:content-language:subject :reply-to:from:user-agent:mime-version:date:message-id :dkim-signature; bh=jrizillEfaAgp0SRrsU3iFgwZ8wya1sI3h5VbmShlHs=; fh=oAaNsmrKM6mUsdanrOY47zkK8O3YPoK3gdLSROup+B0=; b=wgFduW/11tXI32keTIFzZbkGWLTCgmHqynF9iySL2j8p8O4veouP8ra7iQfGlDEtBe aeME6gC94KPfCfhZS1kpBE/rxDl5mOiCF/aUfOASz1JcYl0V+IHq9TrgUHUuA6+EYAHz pCCxMwfUxjilsphUlkK0SdpyUVZCMTq/wikNRO8YAquBbbt2//pqbtr7ogkEZqPGCI7P FjFOa+aRG77H+T/dk8s2Kk1aqiYT1JRRT2wldvx25mydb3RoeJU9kU1hmE49AbMMTA7q +JjLujREzGmCVsMh0Zl4DP8JS8KmrTEib5dc4qXmTz0Uk/na25Rpx06H1yzcEf7Hmv7X IOmg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=nckTyamF; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id q16-20020a170902789000b001bbcddc33dasi1112440pll.180.2023.10.17.00.13.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 00:13:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=nckTyamF; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 73AEC804024D; Tue, 17 Oct 2023 00:13:42 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234586AbjJQHNi (ORCPT + 99 others); Tue, 17 Oct 2023 03:13:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49690 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234695AbjJQHNh (ORCPT ); Tue, 17 Oct 2023 03:13:37 -0400 Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9C348F9 for ; Tue, 17 Oct 2023 00:13:33 -0700 (PDT) Received: by mail-lf1-x12f.google.com with SMTP id 2adb3069b0e04-5079f3f3d7aso4830696e87.1 for ; Tue, 17 Oct 2023 00:13:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1697526812; x=1698131612; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:organization:autocrypt :references:cc:to:content-language:subject:reply-to:from:user-agent :mime-version:date:message-id:from:to:cc:subject:date:message-id :reply-to; bh=jrizillEfaAgp0SRrsU3iFgwZ8wya1sI3h5VbmShlHs=; b=nckTyamFq2pRfLQUb3Lak2OEigBXpLVg780tvr/AwMiE1rVluu0oS9Wm2IpCQTbs07 eAlpLaTRHpd42bwZ2V/al2iDFxSG4i5s2/Fd3K76tY+o2Lu5v+4MMatXRVkmD0xdo0Mn DgyCGDkTtjXoXrQvY/2trHTDd0RrsH6Bm+A384X0eCNpNyXmQukfng8iffZ6xGoxdjWN nEE/Vruf+dyEvP722wx9UBXIfrhNlQrFTU2IReEoV8AoEyVhJnytVBIDcSZd6Li12LpA r1poX7kQfCgdVGae81ouRWC8VkoUU6yF/t/vfy0Ae5FM1fQBonwKgmNk1wu7JTMARl92 xLEw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697526812; x=1698131612; h=content-transfer-encoding:in-reply-to:organization:autocrypt :references:cc:to:content-language:subject:reply-to:from:user-agent :mime-version:date:message-id:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to; bh=jrizillEfaAgp0SRrsU3iFgwZ8wya1sI3h5VbmShlHs=; b=dIfMXEFMX636Y2Va1RT6HlPb/LLmlL4Oiel/3sz/GhD3md5SMyObI1IbZexaBNQ3NP V7FLteJqHG8sbGrw0oCevRZi/Q06kElXzdsR52v1U19MuV7cJjHwJQa6y+ZaiI+LyxL7 JiiPlMqfAI5EqxuGpVRMxLFYSckRNAFTrxZNeeI9fcl4Dx+De/0Kn0QsO26hbX+JqvL+ /ww+bYjOBLw1YAtZTGEzeHxNcV5n2dGtUhMQKQHfuNLEw4unZ/0N1Ny+eNXX15uDc/CP KIEvT8O37pbC4sMbHpcIsxEYHVbcb6ND7Z4pn8J3FqB+9O0UQBJMBDBAJm0adH26DhQ1 kvgg== X-Gm-Message-State: AOJu0YyH8nCcie9OpU2axfz3mPRFFa+uqDg5HynRCi0tCU1SrUH0xhvr KMD6HmJh6N8Wf8qY8ZXWaKUV3bbDgI1zkC7TkSTyKzpc X-Received: by 2002:a05:6512:b96:b0:504:2d54:b4d0 with SMTP id b22-20020a0565120b9600b005042d54b4d0mr1482003lfv.19.1697526811804; Tue, 17 Oct 2023 00:13:31 -0700 (PDT) Received: from ?IPV6:2a01:e0a:982:cbb0:97ef:6513:8029:4596? ([2a01:e0a:982:cbb0:97ef:6513:8029:4596]) by smtp.gmail.com with ESMTPSA id n7-20020a05600c4f8700b00406408dc788sm9180427wmq.44.2023.10.17.00.13.31 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 17 Oct 2023 00:13:31 -0700 (PDT) Message-ID: <6118cb58-cdfa-458d-a034-d0422d79ae45@linaro.org> Date: Tue, 17 Oct 2023 09:13:30 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird From: Neil Armstrong Reply-To: neil.armstrong@linaro.org Subject: Re: [PATCH] crypto: qcom: add HW_RANDOM dependency Content-Language: en-US, fr To: Arnd Bergmann , Herbert Xu , "David S. Miller" , Om Prakash Singh , Bjorn Andersson Cc: Arnd Bergmann , linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org References: <20231016200324.757455-1-arnd@kernel.org> Autocr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JE13zeNFoeY3ggrKY+IzbFomIZY 4yG6xI99NIPEVE9lNBXBKIlewIyVlkOaYvJWSV+p5gdJXOvScNN1epm5YHmf9aE2ZjnqZGoM Mtsyw18YoX9BqMFInxqYQQ3j/HpVgTSvmo5ea5qQDDUaCsaTf8UeDcwYOtgI8iL4oHcsGtUX oUk33HEAEQEAAcLAXwQYAQIACQUCTVkGzwIbDAAKCRAWmrexpM/4rrXiB/sGbkQ6itMrAIfn M7IbRuiSZS1unlySUVYu3SD6YBYnNi3G5EpbwfBNuT3H8//rVvtOFK4OD8cRYkxXRQmTvqa3 3eDIHu/zr1HMKErm+2SD6PO9umRef8V82o2oaCLvf4WeIssFjwB0b6a12opuRP7yo3E3gTCS KmbUuLv1CtxKQF+fUV1cVaTPMyT25Od+RC1K+iOR0F54oUJvJeq7fUzbn/KdlhA8XPGzwGRy 4zcsPWvwnXgfe5tk680fEKZVwOZKIEuJC3v+/yZpQzDvGYJvbyix0lHnrCzq43WefRHI5XTT QbM0WUIBIcGmq38+OgUsMYu4NzLu7uZFAcmp6h8g Organization: Linaro Developer Services In-Reply-To: <20231016200324.757455-1-arnd@kernel.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Tue, 17 Oct 2023 00:13:42 -0700 (PDT) On 16/10/2023 22:02, Arnd Bergmann wrote: > From: Arnd Bergmann > > The driver now calls into the hwrng subsystem and causes a link failure if that > is not reachable: > > x86_64-linux-ld: vmlinux.o: in function `qcom_rng_probe': > qcom-rng.c:(.text+0xfefc7e): undefined reference to `devm_hwrng_register' > > Add a Kconfig dependency as we have for the pure hw_random drivers. I see > that there are some other crypto drivers that instead use 'select HW_RANDOM', > but those seem to be mistakes as that may lead to circular dependencies, > and a simple driver should not force-enable an entire subsytem. > > Fixes: f29cd5bb64c25 ("crypto: qcom-rng - Add hw_random interface support") > Signed-off-by: Arnd Bergmann > --- > drivers/crypto/Kconfig | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/crypto/Kconfig b/drivers/crypto/Kconfig > index c761952f0dc6d..79c3bb9c99c3b 100644 > --- a/drivers/crypto/Kconfig > +++ b/drivers/crypto/Kconfig > @@ -601,6 +601,7 @@ config CRYPTO_DEV_QCE_SW_MAX_LEN > config CRYPTO_DEV_QCOM_RNG > tristate "Qualcomm Random Number Generator Driver" > depends on ARCH_QCOM || COMPILE_TEST > + depends on HW_RANDOM > select CRYPTO_RNG > help > This driver provides support for the Random Number Reviewed-by: Neil Armstrong