From: Wolfram Sang <wsa-z923LK4zBo2bacvFa/9K2g@public.gmane.org>
To: Renaud Cerrato
<r.cerrato-6YL8BHNr0ZqHdZQakrT3ElaPQRlvutdw@public.gmane.org>
Cc: linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] i2c-gpio: added support for I2C_M_STOP flag
Date: Thu, 20 Jun 2013 21:39:16 +0200 [thread overview]
Message-ID: <20130620193915.GD2961@katana> (raw)
In-Reply-To: <1371731837-1476-1-git-send-email-r.cerrato-6YL8BHNr0ZqHdZQakrT3ElaPQRlvutdw@public.gmane.org>
[-- Attachment #1: Type: text/plain, Size: 1108 bytes --]
On Thu, Jun 20, 2013 at 02:37:17PM +0200, Renaud Cerrato wrote:
> Current i2c bit algo implementation doesn't actually support I2C_M_STOP flag despite I2C_FUNC_PROTOCOL_MANGLING functionnality.
Signed-Off is missing :( Please run checkpatch.pl before sending
patches!
What was your testcase?
> ---
> drivers/i2c/algos/i2c-algo-bit.c | 6 ++++++
> 1 files changed, 6 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/i2c/algos/i2c-algo-bit.c b/drivers/i2c/algos/i2c-algo-bit.c
> index fad22b0..00446a6 100644
> --- a/drivers/i2c/algos/i2c-algo-bit.c
> +++ b/drivers/i2c/algos/i2c-algo-bit.c
> @@ -557,6 +557,12 @@ static int bit_xfer(struct i2c_adapter *i2c_adap,
> for (i = 0; i < num; i++) {
> pmsg = &msgs[i];
> nak_ok = pmsg->flags & I2C_M_IGNORE_NAK;
> + if (pmsg->flags & I2C_M_STOP) {
> + if (i) {
Why 'if (i)'?
> + bit_dbg(3, &i2c_adap->dev, "emitting stop condition\n");
> + i2c_stop(adap);
> + }
> + }
> if (!(pmsg->flags & I2C_M_NOSTART)) {
> if (i) {
> bit_dbg(3, &i2c_adap->dev, "emitting "
> --
> 1.7.2.5
>
>
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2013-06-20 19:39 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-20 12:37 [PATCH] i2c-gpio: added support for I2C_M_STOP flag Renaud Cerrato
[not found] ` <1371731837-1476-1-git-send-email-r.cerrato-6YL8BHNr0ZqHdZQakrT3ElaPQRlvutdw@public.gmane.org>
2013-06-20 19:39 ` Wolfram Sang [this message]
2013-06-24 6:37 ` Cerrato Renaud
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=20130620193915.GD2961@katana \
--to=wsa-z923lk4zbo2bacvfa/9k2g@public.gmane.org \
--cc=linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=r.cerrato-6YL8BHNr0ZqHdZQakrT3ElaPQRlvutdw@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 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.