From: Matti Vaittinen <mazziesaccount@gmail.com>
To: Michael Trimarchi <michael@amarulasolutions.com>,
Michael Turquette <mturquette@baylibre.com>,
Stephen Boyd <sboyd@kernel.org>,
"open list:COMMON CLK FRAMEWORK" <linux-clk@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>
Cc: Dario Binacchi <dario.binacchi@amarulasolutions.com>,
linux-amarula@amarulasolutions.com
Subject: Re: [RFC PATCH 1/3] clk: bd718x7: Clean up the code, no functional changes
Date: Mon, 6 Jun 2022 08:49:05 +0300 [thread overview]
Message-ID: <96a66eab-cb20-71a4-baec-aff80f4cd93e@gmail.com> (raw)
In-Reply-To: <20220605165703.1565234-2-michael@amarulasolutions.com>
On 6/5/22 19:57, Michael Trimarchi wrote:
> Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
> ---
> drivers/clk/clk-bd718x7.c | 19 ++++++++++---------
> 1 file changed, 10 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/clk/clk-bd718x7.c b/drivers/clk/clk-bd718x7.c
> index ac40b669d60b..04cc0beb67df 100644
> --- a/drivers/clk/clk-bd718x7.c
> +++ b/drivers/clk/clk-bd718x7.c
> @@ -81,27 +81,28 @@ static int bd71837_clk_probe(struct platform_device *pdev)
> struct bd718xx_clk *c;
> int rval = -ENOMEM;
> const char *parent_clk;
> + struct device *dev = &pdev->dev;
I am not a fan of assigning pointers to struct members to local
variables unless they're shortening lines to fit on one row instead of
using two. Whenever we add such a variable we hide information. After
that being said - in this particular case the device 'dev' points to is
quite obvious so I am not completely against the change if other see the
value.
> struct device *parent = pdev->dev.parent;
> struct clk_init_data init = {
> .name = "bd718xx-32k-out",
> .ops = &bd71837_clk_ops,
> + .num_parents = 1,
I like this. Thanks.
> };
Reviewed-by: Matti Vaittinen <mazziesaccount@gmail.com>
Best Regards
-- Matti
--
Matti Vaittinen
Linux kernel developer at ROHM Semiconductors
Oulu Finland
~~ When things go utterly wrong vim users can always type :help! ~~
Discuss - Estimate - Plan - Report and finally accomplish this:
void do_work(int time) __attribute__ ((const));
next prev parent reply other threads:[~2022-06-06 5:49 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20220605165703.1565234-1-michael@amarulasolutions.com>
2022-06-05 16:57 ` [RFC PATCH 1/3] clk: bd718x7: Clean up the code, no functional changes Michael Trimarchi
2022-06-06 5:49 ` Matti Vaittinen [this message]
2022-06-05 16:57 ` [RFC PATCH 2/3] clk: bd718x7: Enable the possibility to mark the clock as critical Michael Trimarchi
2022-06-06 5:25 ` Matti Vaittinen
2022-06-06 6:08 ` Michael Nazzareno Trimarchi
2024-08-14 16:00 ` Michael Nazzareno Trimarchi
2024-08-15 6:07 ` Matti Vaittinen
2022-06-05 16:57 ` [RFC PATCH 3/3] arm64: dts: imx8mn-bsh-smm-s2/pro: Add pmic clock connection Michael Trimarchi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=96a66eab-cb20-71a4-baec-aff80f4cd93e@gmail.com \
--to=mazziesaccount@gmail.com \
--cc=dario.binacchi@amarulasolutions.com \
--cc=linux-amarula@amarulasolutions.com \
--cc=linux-clk@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michael@amarulasolutions.com \
--cc=mturquette@baylibre.com \
--cc=sboyd@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox