From: Ben Dooks <ben-i2c-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org>
To: matej.kupljen-nWYkTt+LGLL1KXRcyAk9cg@public.gmane.org
Cc: Ben Dooks <ben-i2c-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org>,
Kevin Wells <kevin.wells-3arQi8VN3Tc@public.gmane.org>,
Jean Delvare <khali-PUYAD+kWke1g9hUCZPvPmw@public.gmane.org>,
Vitaly Wool <vitalywool-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: Add restart support to i2c-pnx
Date: Sat, 5 Feb 2011 16:07:01 +0000 [thread overview]
Message-ID: <20110205160701.GC15795@trinity.fluff.org> (raw)
In-Reply-To: <f72f4b6ef01079e2ecd41b39041b4082-Z5eBVJDltO98b/lofMYZ3A@public.gmane.org>
On Thu, Feb 03, 2011 at 08:54:30AM +0100, matej.kupljen-nWYkTt+LGLL1KXRcyAk9cg@public.gmane.org wrote:
> Ben,
>
> >> - struct i2c_pnx_algo_data *alg_data)
> >> + struct i2c_pnx_algo_data *alg_data, int repeated)
> >
> > bool repeated.
>
> I don't agree.
> Since this is C and C++, we do not have a bool keyword.
> And, there is no variable declared as bool in the source file this
> is why and defined this as int and not as bool.
the kernel has this.
> >> + if ((!repeated) && (wait_timeout(I2C_PNX_TIMEOUT, alg_data))) {
> >
> > no need for () around !repeated.
>
> Agreed, but for the clarity sake.
Makes it less clear, there's more on each line.
> >> + if((i > 0) && !(pmsg->flags & I2C_M_NOSTART))
> >
> > no need for () around i > 0
>
> Same as above. I my opinion it is better to use more parentheses then
> fewer, since you do not rely on compiler implementation.
>
> Regards,
> Matej
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
> the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
Ben Dooks, ben-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org, http://www.fluff.org/ben/
Large Hadron Colada: A large Pina Colada that makes the universe disappear.
prev parent reply other threads:[~2011-02-05 16:07 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-02 10:41 Add restart support to i2c-pnx matej.kupljen-nWYkTt+LGLL1KXRcyAk9cg
[not found] ` <acc33abdeea1fb1dd33f6919e7a4c4e4-Z5eBVJDltO98b/lofMYZ3A@public.gmane.org>
2011-02-02 11:19 ` Vitaly Wool
[not found] ` <AANLkTimrs02v70OMkExsfBKhdOU1pxoFoAEn780qj_v--JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-02-02 11:43 ` matej.kupljen-nWYkTt+LGLL1KXRcyAk9cg
[not found] ` <aeed818a0cfb7836e7599aad4ffb9874-Z5eBVJDltO98b/lofMYZ3A@public.gmane.org>
2011-02-02 12:41 ` Jean Delvare
[not found] ` <20110202134102.1fd5b68d-R0o5gVi9kd7kN2dkZ6Wm7A@public.gmane.org>
2011-02-02 12:59 ` matej.kupljen-nWYkTt+LGLL1KXRcyAk9cg
[not found] ` <cd08bef3d940dd8ede1abc5bee93b190-Z5eBVJDltO98b/lofMYZ3A@public.gmane.org>
2011-02-02 19:47 ` Kevin Wells
[not found] ` <083DF309106F364B939360100EC290F80B0E17D10F-SIPbe8o7cfX8DdpCu65jn8FrZmdRls4ZQQ4Iyu8u01E@public.gmane.org>
2011-02-02 21:23 ` Matej Kupljen
2011-02-02 22:24 ` Ben Dooks
[not found] ` <20110202222404.GW15795-SMNkleLxa3Z6Wcw2j4pizdi2O/JbrIOy@public.gmane.org>
2011-02-03 7:54 ` matej.kupljen-nWYkTt+LGLL1KXRcyAk9cg
[not found] ` <f72f4b6ef01079e2ecd41b39041b4082-Z5eBVJDltO98b/lofMYZ3A@public.gmane.org>
2011-02-03 8:03 ` Vitaly Wool
2011-02-05 16:07 ` Ben Dooks [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=20110205160701.GC15795@trinity.fluff.org \
--to=ben-i2c-elnmno+kys3ytjvyw6ydsg@public.gmane.org \
--cc=kevin.wells-3arQi8VN3Tc@public.gmane.org \
--cc=khali-PUYAD+kWke1g9hUCZPvPmw@public.gmane.org \
--cc=linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=matej.kupljen-nWYkTt+LGLL1KXRcyAk9cg@public.gmane.org \
--cc=vitalywool-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.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 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).