Received: by 2002:a05:6a10:d5a5:0:0:0:0 with SMTP id gn37csp2310065pxb; Fri, 8 Oct 2021 05:25:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwu4FYdgLG4Bz9WPyXtuUvfXtQE7Pri1CWv10wvust41hCIuA7QVAhHZpE2ts1xJu4tFVn+ X-Received: by 2002:a17:906:ce2c:: with SMTP id sd12mr3948434ejb.488.1633695943222; Fri, 08 Oct 2021 05:25:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1633695943; cv=none; d=google.com; s=arc-20160816; b=aZUPmC0skHeGY2A3XwNvZNV8vt1vq28YX3dKyESVBa47wGAQbrZGTieP2jWn0pY0b1 b/Ht58IC1MctBa2Ns6lQY3zWkp44a8TaFwtnATJSG3Pxk8+nQ418SCVyiwlf7MU/Fj/Q FSrEQLfe/Y8nbCABIA84uyZLjyDVdu15s2zFv6HROsACX3mRQ5YXKdtl0POusiIX+qJj a0fgFRLPr8oLfG6DdJI+TVCjWpPDS8TJalJ8iZyLSTVpzYXJdkGCMqJW4XRuqbLpG5Gi QdUmWbFfw0lOd0AYxrTDhd805kjaj+ynCv1Zni/m0Gs5xqzuW3HFWyqtLO6dK3L8kDEY BdkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=tuEgLlThtcjoWkGUN0xUBKnJssDcjv54pODltP7Vyog=; b=fyyAiJXj59phgNr/SbR/5OwHciL+ORLOrqmi5Fgw7nW4Yrbz+9ojhBB36nt8rrnQAq TpPR4mr1oLI3rT7utaoMhWGKLk6eyJcA7HpCpLsH7lKyJakvY4t1te5sRVaz6ygK1m5g laJEPlRwM1JebovZt/fPlx7E8ax0+Hcqop4s7p8cz/GqNOJ3u1/Uaxhvli9sdfSrdZlp L6iDPe1zHz6LfCyX83/QnWyI5tufwPLMd+4qNcKMFRcguyZm0Lece0nr5soqtwjk/E74 oTvVdV62O8YamEd+rjavKgW+he+EG7zdriZ5NmAZ54g9KXzbR9TEqE09FCIGIdWzg+1/ 55Kg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e8si2865662edj.359.2021.10.08.05.25.19; Fri, 08 Oct 2021 05:25:43 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230187AbhJHM0W (ORCPT + 99 others); Fri, 8 Oct 2021 08:26:22 -0400 Received: from helcar.hmeau.com ([216.24.177.18]:55920 "EHLO deadmen.hmeau.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241199AbhJHM0W (ORCPT ); Fri, 8 Oct 2021 08:26:22 -0400 Received: from gondobar.mordor.me.apana.org.au ([192.168.128.4] helo=gondobar) by deadmen.hmeau.com with esmtp (Exim 4.92 #5 (Debian)) id 1mYovH-0003dn-28; Fri, 08 Oct 2021 20:24:23 +0800 Received: from herbert by gondobar with local (Exim 4.92) (envelope-from ) id 1mYovD-00086s-P6; Fri, 08 Oct 2021 20:24:19 +0800 Date: Fri, 8 Oct 2021 20:24:19 +0800 From: Herbert Xu To: Markus Schneider-Pargmann Cc: Sean Wang , Matt Mackall , linux-mediatek@lists.infradead.org, linux-crypto@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH] hwrng: mediatek - Force runtime pm ops for sleep ops Message-ID: <20211008122419.GE31060@gondor.apana.org.au> References: <20210930191242.2542315-1-msp@baylibre.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210930191242.2542315-1-msp@baylibre.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Thu, Sep 30, 2021 at 09:12:42PM +0200, Markus Schneider-Pargmann wrote: > Currently mtk_rng_runtime_suspend/resume is called for both runtime pm > and system sleep operations. > > This is wrong as these should only be runtime ops as the name already > suggests. Currently freezing the system will lead to a call to > mtk_rng_runtime_suspend even if the device currently isn't active. This > leads to a clock warning because it is disabled/unprepared although it > isn't enabled/prepared currently. > > This patch fixes this by only setting the runtime pm ops and forces to > call the runtime pm ops from the system sleep ops as well if active but > not otherwise. > > Signed-off-by: Markus Schneider-Pargmann > --- > drivers/char/hw_random/mtk-rng.c | 9 +++++++-- > 1 file changed, 7 insertions(+), 2 deletions(-) Patch applied. Thanks. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt