From: sboyd@codeaurora.org (Stephen Boyd)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/2] tty: amba-pl011: add support for clock frequency setting via dt
Date: Fri, 8 Jul 2016 17:43:03 -0700 [thread overview]
Message-ID: <57804897.1080101@codeaurora.org> (raw)
In-Reply-To: <146802378337.73491.10770797315435166004@resonance>
On 07/08/2016 05:23 PM, Michael Turquette wrote:
> Quoting Jorge Ramirez (2016-07-08 14:39:50)
>> On 07/08/2016 07:14 PM, Michael Turquette wrote:
>>> Quoting Jorge Ramirez-Ortiz (2016-07-08 01:11:06)
>>>> Allow to specify the clock frequency for any given port via the
>>>> assigned-clock-rates device tree property.
>>>>
>>>> Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org>
>>>> Tested-by: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org>
>>>> ---
>>>> drivers/tty/serial/amba-pl011.c | 5 +++++
>>>> 1 file changed, 5 insertions(+)
>>>>
>>>> diff --git a/drivers/tty/serial/amba-pl011.c b/drivers/tty/serial/amba-pl011.c
>>>> index 1b7331e..51867ab 100644
>>>> --- a/drivers/tty/serial/amba-pl011.c
>>>> +++ b/drivers/tty/serial/amba-pl011.c
>>>> @@ -55,6 +55,7 @@
>>>> #include <linux/types.h>
>>>> #include <linux/of.h>
>>>> #include <linux/of_device.h>
>>>> +#include <linux/clk/clk-conf.h>
>>>> #include <linux/pinctrl/consumer.h>
>>>> #include <linux/sizes.h>
>>>> #include <linux/io.h>
>>>> @@ -2472,6 +2473,10 @@ static int pl011_probe(struct amba_device *dev, const struct amba_id *id)
>>>> if (IS_ERR(uap->clk))
>>>> return PTR_ERR(uap->clk);
>>>>
>>>> + ret = of_clk_set_defaults(dev->dev.of_node, false);
>>> Change looks good to me, but with one question: should this change be
>>> put into more generic code instead of in this specific driver? For
>>> instance, we call of_clk_set_defaults from the following files:
>>>
>>> drivers/base/platform.c
>>> drivers/i2c/i2c-core.c
>>> drivers/spi/spi.c
>>>
>>> And Stephen posted a patch to do this for devices on the AMBA bus:
>>>
>>> https://patchwork.kernel.org/patch/6501691/
>>>
>>> Does Stephen's patch mean that you do not need patch #1?
>> I did a quick test (replaced my changes with the patch above) and the
>> console broke and the BT stack couldn't communicate to the device over
>> the uart...I guess something else needs doing on top of Stephen's change.
>>
> Let's give Stephen a chance to respond. If he doesn't soon then I'm OK
> to merge your two patches.
>
Yeah we need to restart that patch. It's been in my "pending" list for a
year now it seems.
Curious why it broke things, perhaps device probe is failing when it
didn't fail before?
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project
WARNING: multiple messages have this Message-ID (diff)
From: Stephen Boyd <sboyd@codeaurora.org>
To: Michael Turquette <mturquette@baylibre.com>,
Jorge Ramirez <jorge.ramirez-ortiz@linaro.org>,
linux@armlinux.org.uk, xuwei5@hisilicon.com
Cc: guodong.xu@linaro.org, xinliang.liu@linaro.org,
john.stultz@linaro.org, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] tty: amba-pl011: add support for clock frequency setting via dt
Date: Fri, 8 Jul 2016 17:43:03 -0700 [thread overview]
Message-ID: <57804897.1080101@codeaurora.org> (raw)
In-Reply-To: <146802378337.73491.10770797315435166004@resonance>
On 07/08/2016 05:23 PM, Michael Turquette wrote:
> Quoting Jorge Ramirez (2016-07-08 14:39:50)
>> On 07/08/2016 07:14 PM, Michael Turquette wrote:
>>> Quoting Jorge Ramirez-Ortiz (2016-07-08 01:11:06)
>>>> Allow to specify the clock frequency for any given port via the
>>>> assigned-clock-rates device tree property.
>>>>
>>>> Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org>
>>>> Tested-by: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org>
>>>> ---
>>>> drivers/tty/serial/amba-pl011.c | 5 +++++
>>>> 1 file changed, 5 insertions(+)
>>>>
>>>> diff --git a/drivers/tty/serial/amba-pl011.c b/drivers/tty/serial/amba-pl011.c
>>>> index 1b7331e..51867ab 100644
>>>> --- a/drivers/tty/serial/amba-pl011.c
>>>> +++ b/drivers/tty/serial/amba-pl011.c
>>>> @@ -55,6 +55,7 @@
>>>> #include <linux/types.h>
>>>> #include <linux/of.h>
>>>> #include <linux/of_device.h>
>>>> +#include <linux/clk/clk-conf.h>
>>>> #include <linux/pinctrl/consumer.h>
>>>> #include <linux/sizes.h>
>>>> #include <linux/io.h>
>>>> @@ -2472,6 +2473,10 @@ static int pl011_probe(struct amba_device *dev, const struct amba_id *id)
>>>> if (IS_ERR(uap->clk))
>>>> return PTR_ERR(uap->clk);
>>>>
>>>> + ret = of_clk_set_defaults(dev->dev.of_node, false);
>>> Change looks good to me, but with one question: should this change be
>>> put into more generic code instead of in this specific driver? For
>>> instance, we call of_clk_set_defaults from the following files:
>>>
>>> drivers/base/platform.c
>>> drivers/i2c/i2c-core.c
>>> drivers/spi/spi.c
>>>
>>> And Stephen posted a patch to do this for devices on the AMBA bus:
>>>
>>> https://patchwork.kernel.org/patch/6501691/
>>>
>>> Does Stephen's patch mean that you do not need patch #1?
>> I did a quick test (replaced my changes with the patch above) and the
>> console broke and the BT stack couldn't communicate to the device over
>> the uart...I guess something else needs doing on top of Stephen's change.
>>
> Let's give Stephen a chance to respond. If he doesn't soon then I'm OK
> to merge your two patches.
>
Yeah we need to restart that patch. It's been in my "pending" list for a
year now it seems.
Curious why it broke things, perhaps device probe is failing when it
didn't fail before?
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project
next prev parent reply other threads:[~2016-07-09 0:43 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-08 8:11 [PATCH 1/2] tty: amba-pl011: add support for clock frequency setting via dt Jorge Ramirez-Ortiz
2016-07-08 8:11 ` Jorge Ramirez-Ortiz
2016-07-08 8:11 ` [PATCH 2/2] arm64: dts: set UART1 clock frequency to 150MHz Jorge Ramirez-Ortiz
2016-07-08 8:11 ` Jorge Ramirez-Ortiz
2016-07-08 17:23 ` Michael Turquette
2016-07-08 17:23 ` Michael Turquette
2016-07-11 9:53 ` Wei Xu
2016-07-11 9:53 ` Wei Xu
2016-08-19 6:57 ` Jorge Ramirez
2016-08-19 6:57 ` Jorge Ramirez
2016-08-19 8:29 ` Wei Xu
2016-08-19 8:29 ` Wei Xu
2016-08-19 9:30 ` Jorge Ramirez-Ortiz
2016-08-19 9:30 ` Jorge Ramirez-Ortiz
2016-08-24 15:24 ` Wei Xu
2016-08-24 15:24 ` Wei Xu
2016-07-08 17:14 ` [PATCH 1/2] tty: amba-pl011: add support for clock frequency setting via dt Michael Turquette
2016-07-08 17:14 ` Michael Turquette
2016-07-08 21:39 ` Jorge Ramirez
2016-07-08 21:39 ` Jorge Ramirez
2016-07-09 0:23 ` Michael Turquette
2016-07-09 0:23 ` Michael Turquette
2016-07-09 0:43 ` Stephen Boyd [this message]
2016-07-09 0:43 ` Stephen Boyd
2016-07-09 6:42 ` Jorge Ramirez
2016-07-09 6:42 ` Jorge Ramirez
[not found] ` <CAPPM39Zy2ii4-9ABTr+WtN5zdBjTFomQjzJfdSfrvYC9vhqd1w@mail.gmail.com>
2016-07-11 21:03 ` Stephen Boyd
2016-07-11 21:03 ` Stephen Boyd
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=57804897.1080101@codeaurora.org \
--to=sboyd@codeaurora.org \
--cc=linux-arm-kernel@lists.infradead.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.