Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp3572537ybl; Mon, 12 Aug 2019 02:48:32 -0700 (PDT) X-Google-Smtp-Source: APXvYqzvh5zZwHXESm72q3A9MRUzQg/Tr+SPqhq9OHqSxtH5p3S6nIacbe6ZZBQEW5WVspSjP5N5 X-Received: by 2002:a63:c203:: with SMTP id b3mr313596pgd.450.1565603312658; Mon, 12 Aug 2019 02:48:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565603312; cv=none; d=google.com; s=arc-20160816; b=zFuDPeuOM8/QlQ30dJvzWojwh6DUSEstzvoB/8DzSUqCnUqQc/CM8TF1Y9Y+am8hJO LXT0sfrO9SHINZlz5/6stQL4qc52ET8Aw50k/g4PPn6I477ePun+YRp13695XQftnNcJ 09wESJS/4mOn2nQ5i5aXQY7WTWiUe+q1FNK/jIa5okdY2ev4RvF9WtPKnTIY49dnPA7n NDgnRDbXsRvlWhEXfL44Ha3aGlXWNXhrBXg7em4wjTxaf+XxvqG0tH1grnd4zlpwsNEa Qm4xHutV5c7Jo5++gOpcu0P2kWb+Stj8wPer4u3pQytMADZCvBaLX+N6GoLhTu1FkiUZ 932g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=P3Tt0hVFMeQO9WKnMLt0unZfnULQUSGm6Y8+KX1wABY=; b=L4hqvLS00rNzqnfqUKNyT/z07gfyszTj8GZlUW9gAx6oF5EZJJEFKFHP+rJ7VBLjpm i4sJ0aRMGyZ6nEff8eeq+rpb1WnfL5ljmwTIQuZKdQzB1XvBSkvoyQk2NO0Ph1ka+uka sIZZFinxnXG3oj1Vc0CYblk5FndlPDQ/aUpJOKoXBuSYNCHaW9edK6Yr8pBc2jr3rZqw yKjx6XDpcIWMNNPcG1AAZhUFQDT9OzWxELgZeQGXfmeY5rgjQkAB1pkJs4RE68JWGH+p JcR2DkriRtOEdzkG9KlQ/AUQpA5kH5ek5WOWgEZcPx9nLFdlmm8UMWwK7AWzErKFJLBZ GUug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=I1sE1d7E; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f186si32763775pgc.438.2019.08.12.02.48.16; Mon, 12 Aug 2019 02:48:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=I1sE1d7E; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727563AbfHLJri (ORCPT + 99 others); Mon, 12 Aug 2019 05:47:38 -0400 Received: from mail-wm1-f68.google.com ([209.85.128.68]:53480 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727323AbfHLJri (ORCPT ); Mon, 12 Aug 2019 05:47:38 -0400 Received: by mail-wm1-f68.google.com with SMTP id 10so11544383wmp.3; Mon, 12 Aug 2019 02:47:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=P3Tt0hVFMeQO9WKnMLt0unZfnULQUSGm6Y8+KX1wABY=; b=I1sE1d7EaGl/q7KxoFPph8dUQJL5MYq+TkA/7MKHlrpe5pTnqrRQ1Qyq/dyi6nqToG 6MDKfag1hIXu0R51glp/qPsKBJEqSfBlsp6qYqASxY8rNzk/+ZdFKEF6fIzXTW6yGAqz RTmBMzpNT6SCMpxR5GEcTJA2At8Mw+mrnZGrrJYlNEplTz060HdwlOyc7CizuAOH0y+p ucsMdOD2Vb0EwMMKYfYaILJqutj7CNfWqG0z7MYxQG93MwGH500Phhh+qr7wsUPRekMC wmdZY8gOb8UWP0A6/r90TYJvbiVT2V2e8UXX4xG3lwyaFw1MfmPXG/RxzT1oO5AZRrdt XDjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=P3Tt0hVFMeQO9WKnMLt0unZfnULQUSGm6Y8+KX1wABY=; b=EDXm55vQ8+SkobmTfqinOzoLVfBl32dhX5/uMLOHTNkuD/LZRaGUYrBo8nUN8ynf6D hWqUiXuDHFKd88IczPNABYa3MCYX+QxEKMvWF9bU9mrQovF/HgYHSSHZ8j0u5yp5AN88 0DuHdjKHHAEnsUvsoFcwJQawwJU16uh+bCnGuGBgGe7QVZFEFU9DUfpdXAAknlhSFup9 6D12bxEa2gch9gA1q3//oCyNKNU9Om1gRrfcULGMVB1DSmGoRO/FCl8429xgg1EI0G9P V/JhrEIcyEsmVvozpnXvZ6HiK6St68LazfCrpn0Au2xTOYnKvfXvB/0pYmz6XYZ3qROg XnTQ== X-Gm-Message-State: APjAAAWSmFtZrYAp5S8jQMIYkH76aU1DNn1RuGFmWOzlMntLoH+6FOY/ alC5JL05TNGB6R9npRnpJY+VtNw3 X-Received: by 2002:a7b:c758:: with SMTP id w24mr2100045wmk.143.1565603255334; Mon, 12 Aug 2019 02:47:35 -0700 (PDT) Received: from localhost (pD9E51890.dip0.t-ipconnect.de. [217.229.24.144]) by smtp.gmail.com with ESMTPSA id u186sm24647842wmu.26.2019.08.12.02.47.33 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 12 Aug 2019 02:47:33 -0700 (PDT) Date: Mon, 12 Aug 2019 11:47:32 +0200 From: Thierry Reding To: Sowjanya Komatineni Cc: jonathanh@nvidia.com, tglx@linutronix.de, jason@lakedaemon.net, marc.zyngier@arm.com, linus.walleij@linaro.org, stefan@agner.ch, mark.rutland@arm.com, pdeschrijver@nvidia.com, pgaikwad@nvidia.com, sboyd@kernel.org, linux-clk@vger.kernel.org, linux-gpio@vger.kernel.org, jckuo@nvidia.com, josephl@nvidia.com, talho@nvidia.com, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org, mperttunen@nvidia.com, spatra@nvidia.com, robh+dt@kernel.org, digetx@gmail.com, devicetree@vger.kernel.org, rjw@rjwysocki.net, viresh.kumar@linaro.org, linux-pm@vger.kernel.org Subject: Re: [PATCH v8 07/21] clk: Add API to get index of the clock parent Message-ID: <20190812094732.GF8903@ulmo> References: <1565308020-31952-1-git-send-email-skomatineni@nvidia.com> <1565308020-31952-8-git-send-email-skomatineni@nvidia.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="0hHDr/TIsw4o3iPK" Content-Disposition: inline In-Reply-To: <1565308020-31952-8-git-send-email-skomatineni@nvidia.com> User-Agent: Mutt/1.12.1 (2019-06-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --0hHDr/TIsw4o3iPK Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Aug 08, 2019 at 04:46:46PM -0700, Sowjanya Komatineni wrote: > This patch adds an API clk_hw_get_parent_index to get index of the > clock parent to use during the clock restore operations on system > resume. >=20 > Signed-off-by: Sowjanya Komatineni > --- > drivers/clk/clk.c | 17 +++++++++++++++++ > include/linux/clk-provider.h | 1 + > 2 files changed, 18 insertions(+) >=20 > diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c > index c0990703ce54..f26252e48f73 100644 > --- a/drivers/clk/clk.c > +++ b/drivers/clk/clk.c > @@ -1643,6 +1643,23 @@ static int clk_fetch_parent_index(struct clk_core = *core, > return i; > } > =20 > +/** > + * clk_hw_get_parent_index - return the index of parent clock > + * @hw: clk_hw associated with the clk being consumed > + * @parent_hw: clk_hw associated with the parent of clk > + * > + * Fetches and returns the index of parent clock. > + * if hw or parent_hw is NULL, returns -EINVAL. "If" because it's at the beginning of a sentence. You may also want to turn this into a "Return:" section as described in: Documentation/doc-guide/kernel-doc.rst That said, other functions in this file don't use that construct either, so I suppose this is fine as-is, for consistency. So with the capitalization of "If" fixed, this is: Reviewed-by: Thierry Reding --0hHDr/TIsw4o3iPK Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEiOrDCAFJzPfAjcif3SOs138+s6EFAl1RNbIACgkQ3SOs138+ s6FV1A//VN8FoQqHYUZDRFeTFLp0ScDoXoSuHZPsgTeHnWdfLuI6hjX0BwnBpuou xp0VC0KcQdVBw0mL+B/0aKRlYcTsXGB0Pk0qi786ZQ5HicqrF7ixVfWNns9TIbAC WQbjyPR0SoG0kBTfIXn36aSRfJh9ulnaPQjJ/SpoaT+pAsc4IUjCaGFVw+Eu2LNX Av3p5BKIcCIynHfmMFNgM4wh44PInWZ7KHqW8yVNk+yJV41rSYqzV0TO2ANg/a6b LaWziwn3XN+aPyuo5dB++g8xIATX2dQSfG6uYjZC4HDt08f3pCBkSEAfyup2xEIF epEcFzFYBuSqyrMZ587honAJ0a5AqzFDSGCxxZw2qd1MSiW5EaIIdQE1PEiY2zeC ldZGCn0iMPizacDQqkRrd96KwDsZ1s8oTGHyNya7z+6PHLRF36nb4EEg0OF1AJ95 aj9EI5IfJlfKSN1RSuR1K7DaZzIunI9Ji7Ip3WlkNc4LIBL9duQ0WQ0D6ttFLpZ4 cTcrkgo/uJ2DOaK84DCEt9w21jIkOoiSFstUKBCC/0+IPURVcHC+ByhHOJbjJMge oYq5uhB2pVscLpnzfjjy5XLBuVjYiapsuWy74tUm1YAyyRvJSLr9+6McvwLjQAHk hpiiENkRMsXAPGywAKTdlrIUK5JYRyXTR7rVHW2xI5M47aMJOdo= =fkP5 -----END PGP SIGNATURE----- --0hHDr/TIsw4o3iPK--