From: Wolfram Sang <wsa@the-dreams.de>
To: Michal Simek <michal.simek@xilinx.com>
Cc: linux-kernel@vger.kernel.org, monstr@monstr.eu,
Kedareswara rao Appana <appana.durga.rao@xilinx.com>,
Kedareswara rao Appana <appanad@xilinx.com>,
Jean Delvare <khali@linux-fr.org>,
Peter Korsgaard <jacmet@sunsite.dk>,
linux-i2c@vger.kernel.org
Subject: Re: [PATCH 2/3] i2c: xilinx: Set tx direction in write operation
Date: Mon, 30 Sep 2013 12:22:42 +0200 [thread overview]
Message-ID: <20130930102242.GB3222@katana> (raw)
In-Reply-To: <5d234cfc8d23cfc7e8d750f103344cf4e8e398d4.1380532113.git.michal.simek@xilinx.com>
[-- Attachment #1: Type: text/plain, Size: 1467 bytes --]
On Mon, Sep 30, 2013 at 11:08:51AM +0200, Michal Simek wrote:
> From: Kedareswara rao Appana <appana.durga.rao@xilinx.com>
>
> In write operation, after filling address byte to tx fifo,
> set the direction of transfer to tx using control register.
You describe WHAT you do, yet you should describe WHY the change is
needed. For example, I can't tell if this is an urgent bugfix or not.
Please rephrase.
>
> Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com>
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
> ---
> drivers/i2c/busses/i2c-xiic.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/i2c/busses/i2c-xiic.c b/drivers/i2c/busses/i2c-xiic.c
> index 5eb0a8b..44e6ae7 100644
> --- a/drivers/i2c/busses/i2c-xiic.c
> +++ b/drivers/i2c/busses/i2c-xiic.c
> @@ -536,6 +536,7 @@ static void xiic_start_recv(struct xiic_i2c *i2c)
> static void xiic_start_send(struct xiic_i2c *i2c)
> {
> struct i2c_msg *msg = i2c->tx_msg;
> + u32 cr;
>
> xiic_irq_clr(i2c, XIIC_INTR_TX_ERROR_MASK);
>
> @@ -556,6 +557,10 @@ static void xiic_start_send(struct xiic_i2c *i2c)
> xiic_setreg16(i2c, XIIC_DTR_REG_OFFSET, data);
> }
>
> + cr = xiic_getreg32(i2c, XIIC_CR_REG_OFFSET);
> + cr |= XIIC_CR_DIR_IS_TX_MASK;
> + xiic_setreg32(i2c, XIIC_CR_REG_OFFSET, cr);
> +
> xiic_fill_tx_fifo(i2c);
>
> /* Clear any pending Tx empty, Tx Error and then enable them. */
> --
> 1.8.2.3
>
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2013-09-30 10:22 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-30 9:08 [PATCH 1/3] i2c: xilinx: Fix i2c sparse warnings Michal Simek
[not found] ` <c122ad49b27406ee495ef0d6cac191968d64f09f.1380532113.git.michal.simek-gjFFaj9aHVfQT0dZR+AlfA@public.gmane.org>
2013-09-30 9:08 ` [PATCH 2/3] i2c: xilinx: Set tx direction in write operation Michal Simek
2013-09-30 10:22 ` Wolfram Sang [this message]
2013-09-30 13:25 ` Michal Simek
2013-09-30 9:08 ` [PATCH 3/3] i2c: xilinx: Use devm_* functions Michal Simek
2013-09-30 10:23 ` [PATCH 1/3] i2c: xilinx: Fix i2c sparse warnings Wolfram Sang
2013-09-30 13:24 ` Michal Simek
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=20130930102242.GB3222@katana \
--to=wsa@the-dreams.de \
--cc=appana.durga.rao@xilinx.com \
--cc=appanad@xilinx.com \
--cc=jacmet@sunsite.dk \
--cc=khali@linux-fr.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.simek@xilinx.com \
--cc=monstr@monstr.eu \
/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