From: Stephen Boyd <sboyd@codeaurora.org>
To: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Cc: linux-clk@vger.kernel.org, x86@kernel.org,
platform-driver-x86@vger.kernel.org, alsa-devel@alsa-project.org,
Michael Turquette <mturquette@baylibre.com>,
Takashi Iwai <tiwai@suse.com>, Mark Brown <broonie@kernel.org>,
Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Vinod Koul <vinod.koul@intel.com>
Subject: Re: [PATCH] clk: x86: add "mclk" alias for Baytrail/Cherrytrail
Date: Wed, 15 Feb 2017 16:56:23 -0800 [thread overview]
Message-ID: <20170216005623.GY25384@codeaurora.org> (raw)
In-Reply-To: <bc29984e-cc58-69ed-d6ca-b4808d6514dc@linux.intel.com>
On 02/14, Pierre-Louis Bossart wrote:
> On 2/14/17 1:04 PM, Stephen Boyd wrote:
> >
> >This leaks an alias when the driver is removed. Honestly,
> >clk_add_alias() doesn't work well because of that problem. Can
> >you just add another lookup with the pointer you already have
> >instead of passing a NULL device to do a global lookup?
>
> This is a builtin driver that cannot be configured as a module, is
> the leaked alias problematic?
Well we don't suppress driver unbinding via sysfs here, unless I
missed something, so the leak could be triggered that way.
> I don't mind trying something different but I am not familiar enough
> with the framework to understand what you are hinting at. Are you
> suggesting a change on the last parameter such as:
>
> clk_add_alias("mclk", dev_name(&pdev->dev), "pmc_plt_clk_3", &pdev->dev)
>
I mean:
lookup = clkdev_hw_create(data->clks[3].hw, "mclk", NULL);
and then freeing that lookup with clkdev_drop in the remove of
the driver. "mclk" is really generic for a connection name
without an associated device id, so you may want to pass some
device as the last argument here, but dev_name(&pdev->dev) seems
odd because that's the clock controller device, not whatever
device would be calling clk_get() with this created lookup in
mind.
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project
next prev parent reply other threads:[~2017-02-16 0:56 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-12 22:06 [PATCH] clk: x86: add "mclk" alias for Baytrail/Cherrytrail Pierre-Louis Bossart
2017-02-14 19:04 ` Stephen Boyd
2017-02-14 19:23 ` Pierre-Louis Bossart
2017-02-16 0:56 ` Stephen Boyd [this message]
2017-02-16 2:05 ` Andy Shevchenko
2017-02-16 10:31 ` Mark Brown
2017-02-16 10:31 ` Mark Brown
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=20170216005623.GY25384@codeaurora.org \
--to=sboyd@codeaurora.org \
--cc=alsa-devel@alsa-project.org \
--cc=andriy.shevchenko@linux.intel.com \
--cc=broonie@kernel.org \
--cc=linux-clk@vger.kernel.org \
--cc=mturquette@baylibre.com \
--cc=pierre-louis.bossart@linux.intel.com \
--cc=platform-driver-x86@vger.kernel.org \
--cc=tiwai@suse.com \
--cc=vinod.koul@intel.com \
--cc=x86@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.