linux-tegra.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Thierry Reding <thierry.reding@gmail.com>
To: Shardar Mohammed <smohammed@nvidia.com>
Cc: Laxman Dewangan <ldewangan@nvidia.com>,
	"swarren@wwwdotorg.org" <swarren@wwwdotorg.org>,
	"linux-i2c@vger.kernel.org" <linux-i2c@vger.kernel.org>,
	"linux-tegra@vger.kernel.org" <linux-tegra@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"wsa@the-dreams.de" <wsa@the-dreams.de>,
	"gnurou@gmail.com" <gnurou@gmail.com>
Subject: Re: [PATCH] i2c: tegra: proper handling of error cases
Date: Mon, 18 Apr 2016 09:26:06 +0200	[thread overview]
Message-ID: <20160418072606.GB13078@ulmo.ba.sec> (raw)
In-Reply-To: <73535dcc422441d3a981208dae1a2bad@bgmail102.nvidia.com>

[-- Attachment #1: Type: text/plain, Size: 953 bytes --]

On Sat, Apr 16, 2016 at 08:08:50AM +0000, Shardar Mohammed wrote:
[...]
> > >  	if (!(msg->flags & I2C_M_RD))
> > >  		tegra_i2c_fill_tx_fifo(i2c_dev);
> > >
> > > -	int_mask = I2C_INT_NO_ACK | I2C_INT_ARBITRATION_LOST;
> > >  	if (i2c_dev->hw->has_per_pkt_xfer_complete_irq)
> > >  		int_mask |= I2C_INT_PACKET_XFER_COMPLETE;
> > >  	if (msg->flags & I2C_M_RD)
> > >  		int_mask |= I2C_INT_RX_FIFO_DATA_REQ;
> > >  	else if (i2c_dev->msg_buf_remaining)
> > >  		int_mask |= I2C_INT_TX_FIFO_DATA_REQ;
> > > +
> > >  	tegra_i2c_unmask_irq(i2c_dev, int_mask);
> > 
> > Can this line be removed? The NO_ACK and ARBITRATION_LOST interrupts
> > are already unmasked earlier.
> 
> [Shardar] unmask_irq() here is enabling other interrupts
> (PACKET_XFER_COMPLETE/TX_FIFO_DATA_REQ/RX_FIFO_DATA_REQ). please let
> me know if my understanding is wrong from your comment.

You're right, I obviously wasn't looking closely enough.

Thierry

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  reply	other threads:[~2016-04-18  7:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1460726507-9170-1-git-send-email-smohammed@nvdiia.com>
     [not found] ` <1460726507-9170-1-git-send-email-smohammed-85njD5c96MTQT0dZR+AlfA@public.gmane.org>
2016-04-15 14:15   ` [PATCH] i2c: tegra: proper handling of error cases Thierry Reding
2016-04-16  8:08     ` Shardar Mohammed
2016-04-18  7:26       ` Thierry Reding [this message]
2016-04-18  7:31       ` Thierry Reding

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=20160418072606.GB13078@ulmo.ba.sec \
    --to=thierry.reding@gmail.com \
    --cc=gnurou@gmail.com \
    --cc=ldewangan@nvidia.com \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=smohammed@nvidia.com \
    --cc=swarren@wwwdotorg.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).