mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Yong Wang <yong.y.wang@linux.intel.com>
To: Grant Likely <grant.likely@secretlab.ca>
Cc: David Brownell <dbrownell@users.sourceforge.net>,
	Feng Tang <feng.tang@intel.com>,
	George Shore <george@georgeshore.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Jean-Hugues Deschenes <jean-hugues.deschenes@octasic.com>,
	spi-devel-general@lists.sourceforge.net,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] dw_spi: Allow interrupt sharing
Date: Thu, 9 Sep 2010 13:08:58 +0800	[thread overview]
Message-ID: <20100909050858.GA8003@ywang-moblin2.bj.intel.com> (raw)
In-Reply-To: <20100908165341.GJ3686@angua.secretlab.ca>

On Wed, Sep 08, 2010 at 10:53:41AM -0600, Grant Likely wrote:
> On Tue, Sep 07, 2010 at 03:27:27PM +0800, Yong Wang wrote:
> > Allow interrupt sharing since exclusive interrupt line for
> > DW SPI controller is not provided on every platform.
> > 
> > Signed-off-by: Yong Wang <yong.y.wang@intel.com>
> > ---
> >  drivers/spi/dw_spi.c |    7 ++++++-
> >  1 files changed, 6 insertions(+), 1 deletions(-)
> > 
> > diff --git a/drivers/spi/dw_spi.c b/drivers/spi/dw_spi.c
> > index d256cb0..11fbbf6 100644
> > --- a/drivers/spi/dw_spi.c
> > +++ b/drivers/spi/dw_spi.c
> > @@ -396,6 +396,11 @@ static irqreturn_t interrupt_transfer(struct dw_spi *dws)
> >  static irqreturn_t dw_spi_irq(int irq, void *dev_id)
> >  {
> >  	struct dw_spi *dws = dev_id;
> > +	u16 irq_status, irq_mask = 0x3f;
> > +
> > +	irq_status = dw_readw(dws, isr) & irq_mask;
> > +	if (!irq_status)
> > +		return IRQ_NONE;
> 
> To be more concise, this could have simply been:
> 
> if (!dw_readw(dws, isr) & 0x3f)
> 	return IRQ_NONE;
> 
> ... but I'm nitpicking here.  If I don't get an updated version of
> this patch from you in the next few days then I'll apply this one.
> 

Thanks for your comments, Grant. Could you please apply the patch as is?
I think it is more readable. In addition, it is consistent with other
parts of the driver in terms of how isr register is manipulated.

Thanks
-Yong


      reply	other threads:[~2010-09-09  5:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-07  7:27 Yong Wang
2010-09-08 16:53 ` Grant Likely
2010-09-09  5:08   ` Yong Wang [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=20100909050858.GA8003@ywang-moblin2.bj.intel.com \
    --to=yong.y.wang@linux.intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=dbrownell@users.sourceforge.net \
    --cc=feng.tang@intel.com \
    --cc=george@georgeshore.com \
    --cc=grant.likely@secretlab.ca \
    --cc=jean-hugues.deschenes@octasic.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=spi-devel-general@lists.sourceforge.net \
    /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

Powered by JetHome