From: maxime.coquelin@st.com (Maxime Coquelin)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v4 4/6] pinctrl: st: Use ARRAY_SIZE instead of raw value for number of delays
Date: Fri, 14 Mar 2014 10:44:39 +0100 [thread overview]
Message-ID: <5322CF87.5000301@st.com> (raw)
In-Reply-To: <CACRpkda0Z15zC=d8xe+KyHqgmTCHbnUjL14fBmtscpR-2kHtFQ@mail.gmail.com>
On 03/14/2014 10:20 AM, Linus Walleij wrote:
> On Wed, Mar 12, 2014 at 3:25 PM, Joe Perches <joe@perches.com> wrote:
>> On Wed, 2014-03-12 at 09:50 +0100, Maxime COQUELIN wrote:
>>> This patch replaces the raw values with ARRAY_SIZE for assigning the
>>> ninput_delays and noutput_delays fields of STiH416's st_pctl_data struct.
>>
>> trivial note:
>>
>>> diff --git a/drivers/pinctrl/pinctrl-st.c b/drivers/pinctrl/pinctrl-st.c
>> []
>>> @@ -384,9 +384,9 @@ static unsigned int stih416_delays[] = {0, 300, 500, 750, 1000, 1250, 1500,
>>> static const struct st_pctl_data stih416_data = {
>>> .rt_style = st_retime_style_dedicated,
>>> .input_delays = stih416_delays,
>>> - .ninput_delays = 14,
>>> + .ninput_delays = ARRAY_SIZE(stih416_delays),
>>> .output_delays = stih416_delays,
>>> - .noutput_delays = 14,
>>> + .noutput_delays = ARRAY_SIZE(stih416_delays),
>>> .alt = 0, .oe = 40, .pu = 50, .od = 60, .rt = 100,
>>> };
>>>
>>
>> drivers/pinctrl/pinctrl-st.c- unsigned int *input_delays;
>> drivers/pinctrl/pinctrl-st.c- unsigned int *output_delays;
>>
>> It may be better to change these to const unsigned int *
>> and change
>>
>> static unsigned int stih416_delays[] = {
>>
>> to static const
>
> Good point. Patches accepted :-)
Sorry Joe, I forgot to reply.
I added this to my todo list.
I will provide the change before end of next week.
Thanks,
Maxime
>
> Yours,
> Linus Walleij
>
WARNING: multiple messages have this Message-ID (diff)
From: Maxime Coquelin <maxime.coquelin@st.com>
To: Linus Walleij <linus.walleij@linaro.org>, Joe Perches <joe@perches.com>
Cc: Rob Landley <rob@landley.net>, Rob Herring <robh+dt@kernel.org>,
Pawel Moll <pawel.moll@arm.com>,
Mark Rutland <mark.rutland@arm.com>,
Ian Campbell <ijc+devicetree@hellion.org.uk>,
Kumar Gala <galak@codeaurora.org>,
Russell King <linux@arm.linux.org.uk>,
Srinivas Kandagatla <srinivas.kandagatla@st.com>,
Stuart Menefy <stuart.menefy@st.com>,
Giuseppe Cavallaro <peppe.cavallaro@st.com>,
"linux-doc@vger.kernel.org" <linux-doc@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
kernel@stlinux.com, Lee Jones <lee.jones@linaro.org>
Subject: Re: [PATCH v4 4/6] pinctrl: st: Use ARRAY_SIZE instead of raw value for number of delays
Date: Fri, 14 Mar 2014 10:44:39 +0100 [thread overview]
Message-ID: <5322CF87.5000301@st.com> (raw)
In-Reply-To: <CACRpkda0Z15zC=d8xe+KyHqgmTCHbnUjL14fBmtscpR-2kHtFQ@mail.gmail.com>
On 03/14/2014 10:20 AM, Linus Walleij wrote:
> On Wed, Mar 12, 2014 at 3:25 PM, Joe Perches <joe@perches.com> wrote:
>> On Wed, 2014-03-12 at 09:50 +0100, Maxime COQUELIN wrote:
>>> This patch replaces the raw values with ARRAY_SIZE for assigning the
>>> ninput_delays and noutput_delays fields of STiH416's st_pctl_data struct.
>>
>> trivial note:
>>
>>> diff --git a/drivers/pinctrl/pinctrl-st.c b/drivers/pinctrl/pinctrl-st.c
>> []
>>> @@ -384,9 +384,9 @@ static unsigned int stih416_delays[] = {0, 300, 500, 750, 1000, 1250, 1500,
>>> static const struct st_pctl_data stih416_data = {
>>> .rt_style = st_retime_style_dedicated,
>>> .input_delays = stih416_delays,
>>> - .ninput_delays = 14,
>>> + .ninput_delays = ARRAY_SIZE(stih416_delays),
>>> .output_delays = stih416_delays,
>>> - .noutput_delays = 14,
>>> + .noutput_delays = ARRAY_SIZE(stih416_delays),
>>> .alt = 0, .oe = 40, .pu = 50, .od = 60, .rt = 100,
>>> };
>>>
>>
>> drivers/pinctrl/pinctrl-st.c- unsigned int *input_delays;
>> drivers/pinctrl/pinctrl-st.c- unsigned int *output_delays;
>>
>> It may be better to change these to const unsigned int *
>> and change
>>
>> static unsigned int stih416_delays[] = {
>>
>> to static const
>
> Good point. Patches accepted :-)
Sorry Joe, I forgot to reply.
I added this to my todo list.
I will provide the change before end of next week.
Thanks,
Maxime
>
> Yours,
> Linus Walleij
>
WARNING: multiple messages have this Message-ID (diff)
From: Maxime Coquelin <maxime.coquelin@st.com>
To: Linus Walleij <linus.walleij@linaro.org>, Joe Perches <joe@perches.com>
Cc: Rob Landley <rob@landley.net>, Rob Herring <robh+dt@kernel.org>,
Pawel Moll <pawel.moll@arm.com>,
Mark Rutland <mark.rutland@arm.com>,
Ian Campbell <ijc+devicetree@hellion.org.uk>,
Kumar Gala <galak@codeaurora.org>,
Russell King <linux@arm.linux.org.uk>,
Srinivas Kandagatla <srinivas.kandagatla@st.com>,
Stuart Menefy <stuart.menefy@st.com>,
Giuseppe Cavallaro <peppe.cavallaro@st.com>,
"linux-doc@vger.kernel.org" <linux-doc@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>, <kernel@stlinux.com>,
Lee Jones <lee.jones@linaro.org>
Subject: Re: [PATCH v4 4/6] pinctrl: st: Use ARRAY_SIZE instead of raw value for number of delays
Date: Fri, 14 Mar 2014 10:44:39 +0100 [thread overview]
Message-ID: <5322CF87.5000301@st.com> (raw)
In-Reply-To: <CACRpkda0Z15zC=d8xe+KyHqgmTCHbnUjL14fBmtscpR-2kHtFQ@mail.gmail.com>
On 03/14/2014 10:20 AM, Linus Walleij wrote:
> On Wed, Mar 12, 2014 at 3:25 PM, Joe Perches <joe@perches.com> wrote:
>> On Wed, 2014-03-12 at 09:50 +0100, Maxime COQUELIN wrote:
>>> This patch replaces the raw values with ARRAY_SIZE for assigning the
>>> ninput_delays and noutput_delays fields of STiH416's st_pctl_data struct.
>>
>> trivial note:
>>
>>> diff --git a/drivers/pinctrl/pinctrl-st.c b/drivers/pinctrl/pinctrl-st.c
>> []
>>> @@ -384,9 +384,9 @@ static unsigned int stih416_delays[] = {0, 300, 500, 750, 1000, 1250, 1500,
>>> static const struct st_pctl_data stih416_data = {
>>> .rt_style = st_retime_style_dedicated,
>>> .input_delays = stih416_delays,
>>> - .ninput_delays = 14,
>>> + .ninput_delays = ARRAY_SIZE(stih416_delays),
>>> .output_delays = stih416_delays,
>>> - .noutput_delays = 14,
>>> + .noutput_delays = ARRAY_SIZE(stih416_delays),
>>> .alt = 0, .oe = 40, .pu = 50, .od = 60, .rt = 100,
>>> };
>>>
>>
>> drivers/pinctrl/pinctrl-st.c- unsigned int *input_delays;
>> drivers/pinctrl/pinctrl-st.c- unsigned int *output_delays;
>>
>> It may be better to change these to const unsigned int *
>> and change
>>
>> static unsigned int stih416_delays[] = {
>>
>> to static const
>
> Good point. Patches accepted :-)
Sorry Joe, I forgot to reply.
I added this to my todo list.
I will provide the change before end of next week.
Thanks,
Maxime
>
> Yours,
> Linus Walleij
>
next prev parent reply other threads:[~2014-03-14 9:44 UTC|newest]
Thread overview: 76+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-12 8:50 [PATCH v4 0/6] Add STiH407 SoC and reference board support Maxime COQUELIN
2014-03-12 8:50 ` Maxime COQUELIN
2014-03-12 8:50 ` [PATCH v4 1/6] ARM: STi: Add STiH407 SoC support Maxime COQUELIN
2014-03-12 8:50 ` Maxime COQUELIN
2014-03-12 9:37 ` Lee Jones
2014-03-12 9:37 ` Lee Jones
2014-03-12 8:50 ` [PATCH v4 2/6] pinctrl: st: Enhance the controller to manage unavailable registers Maxime COQUELIN
2014-03-12 8:50 ` Maxime COQUELIN
2014-03-12 9:38 ` Lee Jones
2014-03-12 9:38 ` Lee Jones
2014-03-12 14:16 ` Linus Walleij
2014-03-12 14:16 ` Linus Walleij
2014-03-12 14:16 ` Linus Walleij
2014-03-12 8:50 ` [PATCH v4 3/6] pinctrl: st: add pinctrl support for the STiH407 SoC Maxime COQUELIN
2014-03-12 8:50 ` Maxime COQUELIN
2014-03-12 14:17 ` Linus Walleij
2014-03-12 14:17 ` Linus Walleij
2014-03-12 14:17 ` Linus Walleij
2014-03-12 8:50 ` [PATCH v4 4/6] pinctrl: st: Use ARRAY_SIZE instead of raw value for number of delays Maxime COQUELIN
2014-03-12 8:50 ` Maxime COQUELIN
2014-03-12 9:39 ` Lee Jones
2014-03-12 9:39 ` Lee Jones
2014-03-12 14:19 ` Linus Walleij
2014-03-12 14:19 ` Linus Walleij
2014-03-12 14:25 ` Joe Perches
2014-03-12 14:25 ` Joe Perches
2014-03-14 9:20 ` Linus Walleij
2014-03-14 9:20 ` Linus Walleij
2014-03-14 9:44 ` Maxime Coquelin [this message]
2014-03-14 9:44 ` Maxime Coquelin
2014-03-14 9:44 ` Maxime Coquelin
2014-03-14 9:46 ` srinivas kandagatla
2014-03-14 9:46 ` srinivas kandagatla
2014-03-14 9:46 ` srinivas kandagatla
2014-03-12 8:50 ` [PATCH v4 5/6] ARM: dts: Add STiH407 SoC support Maxime COQUELIN
2014-03-12 8:50 ` Maxime COQUELIN
2014-05-13 12:04 ` [STLinux Kernel] " Patrice Chotard
2014-05-13 12:04 ` Patrice Chotard
2014-05-13 12:04 ` Patrice Chotard
2014-03-12 8:50 ` [PATCH v4 6/6] ARM: dts: STiH407: Add B2120 board support Maxime COQUELIN
2014-03-12 8:50 ` Maxime COQUELIN
2014-05-13 12:05 ` [STLinux Kernel] " Patrice Chotard
2014-05-13 12:05 ` Patrice Chotard
2014-05-13 12:05 ` Patrice Chotard
2014-05-20 6:18 ` Olof Johansson
2014-05-20 6:18 ` Olof Johansson
2014-05-20 6:18 ` Olof Johansson
2014-05-20 7:20 ` Lee Jones
2014-05-20 7:20 ` Lee Jones
2014-05-20 7:20 ` Lee Jones
2014-05-20 7:24 ` Olof Johansson
2014-05-20 7:24 ` Olof Johansson
2014-05-20 7:43 ` Lee Jones
2014-05-20 7:43 ` Lee Jones
2014-05-20 7:43 ` Lee Jones
2014-05-20 7:53 ` Maxime Coquelin
2014-05-20 7:53 ` Maxime Coquelin
2014-05-20 7:53 ` Maxime Coquelin
2014-05-20 22:10 ` Olof Johansson
2014-05-20 22:10 ` Olof Johansson
2014-05-21 10:02 ` Lee Jones
2014-05-21 10:02 ` Lee Jones
2014-05-20 8:27 ` Maxime Coquelin
2014-05-20 8:27 ` Maxime Coquelin
2014-05-20 8:27 ` Maxime Coquelin
2014-03-12 14:20 ` [PATCH v4 0/6] Add STiH407 SoC and reference " Linus Walleij
2014-03-12 14:20 ` Linus Walleij
2014-03-12 15:26 ` Maxime Coquelin
2014-03-12 15:26 ` Maxime Coquelin
2014-03-12 15:26 ` Maxime Coquelin
2014-03-14 10:14 ` Linus Walleij
2014-03-14 10:14 ` Linus Walleij
2014-03-14 10:14 ` Linus Walleij
2014-04-22 12:17 ` Maxime Coquelin
2014-04-22 12:17 ` Maxime Coquelin
2014-04-22 12:17 ` Maxime Coquelin
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=5322CF87.5000301@st.com \
--to=maxime.coquelin@st.com \
--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.