From: Alain Volmat <alain.volmat@st.com>
To: Wolfram Sang <wsa@the-dreams.de>
Cc: mark.rutland@arm.com, devicetree@vger.kernel.org,
alexandre.torgue@st.com, linux-kernel@vger.kernel.org,
pierre-yves.mordret@st.com, robh+dt@kernel.org,
linux-i2c@vger.kernel.org, mcoquelin.stm32@gmail.com,
fabrice.gasnier@st.com, linux-stm32@st-md-mailman.stormreply.com,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v2 2/2] i2c: i2c-stm32f7: allows for any bus frequency
Date: Mon, 20 Apr 2020 17:00:29 +0200 [thread overview]
Message-ID: <20200420150029.GA6945@gnbcxd0016.gnb.st.com> (raw)
In-Reply-To: <20200415110916.GO1141@ninjato>
Hi Wolfram,
On Wed, Apr 15, 2020 at 01:09:16PM +0200, Wolfram Sang wrote:
> Hi Alain,
>
> On Thu, Mar 26, 2020 at 01:44:21PM +0100, Alain Volmat wrote:
> > Do not limitate to the 3 (100KHz, 400KHz, 1MHz) bus frequency but
> > instead allows any frequency (if it matches timing requirements).
> > Depending on the requested frequency, use the spec data from either
> > Standard, Fast or Fast Plus mode.
> >
> > Hardcoding of min/max bus frequencies is removed and is instead computed.
> >
> > The driver do not use anymore speed identifier but instead handle
> > directly the frequency and figure out the spec data (necessary
> > for the computation of the timing register) based on the frequency.
>
> Useful improvement!
>
> > +static struct stm32f7_i2c_spec *get_specs(u32 rate)
>
> This is quite a generic namespace. Can we prefix stm32f7_<sth> here?
Done in v3
>
> > + if (rate <= i2c_specs[i].rate)
> > + return &i2c_specs[i];
>
> Same for i2c_specs here?
Done in v3
>
> > +static u32 get_lower_rate(u32 rate)
>
> Here, too.
Done in v3
>
> Rest looks good to me.
>
> Regards,
>
> Wolfram
>
Regards,
Alain
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
prev parent reply other threads:[~2020-04-20 15:00 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-26 12:44 [PATCH v2 0/2] i2c: i2c-stm32f7: allow range of I2C bus frequency Alain Volmat
2020-03-26 12:44 ` [PATCH v2 1/2] dt-bindings: i2c: i2c-stm32f7: allow clock-frequency range Alain Volmat
2020-04-04 17:18 ` Rob Herring
2020-03-26 12:44 ` [PATCH v2 2/2] i2c: i2c-stm32f7: allows for any bus frequency Alain Volmat
2020-03-30 8:48 ` Pierre Yves MORDRET
2020-04-15 11:09 ` Wolfram Sang
2020-04-20 15:00 ` Alain Volmat [this message]
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=20200420150029.GA6945@gnbcxd0016.gnb.st.com \
--to=alain.volmat@st.com \
--cc=alexandre.torgue@st.com \
--cc=devicetree@vger.kernel.org \
--cc=fabrice.gasnier@st.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=mark.rutland@arm.com \
--cc=mcoquelin.stm32@gmail.com \
--cc=pierre-yves.mordret@st.com \
--cc=robh+dt@kernel.org \
--cc=wsa@the-dreams.de \
/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).