From: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>
To: Russell King - ARM Linux <linux@armlinux.org.uk>
Cc: david.brown@linaro.org, rafael.j.wysocki@intel.com,
linux-clk@vger.kernel.org, b.zolnierkie@samsung.com,
sboyd@kernel.org, mturquette@baylibre.com,
mazziesaccount@gmail.com, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org, krzk@kernel.org,
akshu.agrawal@amd.com, cw00.choi@samsung.com,
djkurtz@chromium.org, pavel@ucw.cz, pombredanne@nexb.com,
andy.gross@linaro.org, andrew.smirnov@gmail.com,
sjhuang@iluvatar.ai, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v5 1/9] clkdev: add managed clkdev lookup registration
Date: Tue, 4 Dec 2018 10:03:38 +0200 [thread overview]
Message-ID: <20181204080338.GB31204@localhost.localdomain> (raw)
In-Reply-To: <20181203180612.GM30658@n2100.armlinux.org.uk>
Hello Russell,
Thanks for the review. I do appreciate this. I'll send out v6 where I'll
have these fixed =)
On Mon, Dec 03, 2018 at 06:06:12PM +0000, Russell King - ARM Linux wrote:
> > +static int devm_clk_match_clkdev(struct device *dev, void *res, void *data)
> > +{
> > + struct clk_lookup **l = res;
> > +
> > + if (!l || !*l) {
> > + WARN_ON(!l || !*l);
>
> How can "l" be NULL here? How can *l be NULL?
I really don't know if there is any "sane" way to end up having the
devres data NULLed. I admit I looked an example on how others had
implemented the match. These checks were present in devm_clk_match
and devm_regmap_irq_chip_match so I assumed there is a way to end up
having NULL there. Thus I played safe. OTOH it seems that for example
devm_hwmon_match does omit these checks and I really don't see right
away why the dr->data would be NULL. So I'll remove the check.
Br,
Matti Vaittinen
>
> --
> RMK's Patch system: http://www.armlinux.org.uk/developer/patches/
> FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up
> According to speedtest.net: 11.9Mbps down 500kbps up
--
Matti Vaittinen
ROHM Semiconductors
~~~ "I don't think so," said Rene Descartes. Just then, he vanished ~~~
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2018-12-04 8:04 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-03 12:17 [PATCH v5 0/9] clk: clkdev: managed clk lookup and provider registrations Matti Vaittinen
2018-12-03 12:17 ` [PATCH v5 1/9] clkdev: add managed clkdev lookup registration Matti Vaittinen
2018-12-03 18:06 ` Russell King - ARM Linux
2018-12-04 8:03 ` Matti Vaittinen [this message]
2018-12-03 12:18 ` [PATCH v5 2/9] clk: of_clk - add managed provider registrations Matti Vaittinen
2018-12-03 12:19 ` [PATCH v5 3/9] clk: clk-max77686: Clean clkdev lookup leak and use devm Matti Vaittinen
2018-12-03 12:19 ` [PATCH v5 0/9] clk: clkdev: managed clk lookup and provider registrations Lee Jones
2018-12-03 12:35 ` Matti Vaittinen
2018-12-03 12:56 ` Lee Jones
2018-12-03 12:20 ` [PATCH v5 4/9] clk: clk-st: avoid clkdev lookup leak at remove Matti Vaittinen
2018-12-03 12:20 ` [PATCH v5 5/9] clk: clk-hi655x: Free of_provider " Matti Vaittinen
2018-12-03 12:21 ` [PATCH v5 6/9] clk: rk808: use managed version of of_provider registration Matti Vaittinen
2018-12-03 12:22 ` [PATCH v5 7/9] clk: clk-twl6040: Free of_provider at remove Matti Vaittinen
2018-12-03 12:23 ` [PATCH v5 8/9] clk: apcs-msm8916: simplify probe cleanup by using devm Matti Vaittinen
2018-12-03 12:23 ` [PATCH v5 9/9] clk: bd718x7: Initial support for ROHM bd71837/bd71847 PMIC clock Matti Vaittinen
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=20181204080338.GB31204@localhost.localdomain \
--to=matti.vaittinen@fi.rohmeurope.com \
--cc=akshu.agrawal@amd.com \
--cc=andrew.smirnov@gmail.com \
--cc=andy.gross@linaro.org \
--cc=b.zolnierkie@samsung.com \
--cc=cw00.choi@samsung.com \
--cc=david.brown@linaro.org \
--cc=djkurtz@chromium.org \
--cc=krzk@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-clk@vger.kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=mazziesaccount@gmail.com \
--cc=mturquette@baylibre.com \
--cc=pavel@ucw.cz \
--cc=pombredanne@nexb.com \
--cc=rafael.j.wysocki@intel.com \
--cc=sboyd@kernel.org \
--cc=sjhuang@iluvatar.ai \
/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;
as well as URLs for NNTP newsgroup(s).