All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Brandt <Chris.Brandt@renesas.com>
To: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>,
	Geert Uytterhoeven <geert@linux-m68k.org>
Cc: David Miller <davem@davemloft.net>,
	Simon Horman <horms+renesas@verge.net.au>,
	Geert Uytterhoeven <geert+renesas@glider.be>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	Linux-Renesas <linux-renesas-soc@vger.kernel.org>
Subject: RE: [PATCH v2] sh_eth: remove unchecked interrupts
Date: Thu, 1 Dec 2016 18:53:22 +0000	[thread overview]
Message-ID: <SG2PR06MB1165C7D7B7DFBAC4B5BAB09A8A8F0@SG2PR06MB1165.apcprd06.prod.outlook.com> (raw)
In-Reply-To: <25b92de0-806b-342b-7556-06b96b948b2c@cogentembedded.com>

Hi Geert,

On 12/1/2016, Sergei Shtylyov wrote:
> 
> On 12/01/2016 05:42 PM, Geert Uytterhoeven wrote:
> 
> >> --- a/drivers/net/ethernet/renesas/sh_eth.c
> >> +++ b/drivers/net/ethernet/renesas/sh_eth.c
> >> @@ -518,7 +518,7 @@ static struct sh_eth_cpu_data r7s72100_data = {
> >>
> >>         .ecsr_value     = ECSR_ICD,
> >>         .ecsipr_value   = ECSIPR_ICDIP,
> >> -       .eesipr_value   = 0xff7f009f,
> >> +       .eesipr_value   = 0xe77f009f,
> >
> > Comment not directly related to the merits of this patch: the EESIPR
> > bit definitions seem to be identical to those for EESR, so we can get
> > rid of the hardcoded values here?
> 
>     Do you mean using the @define's? We have EESIPR bits also declared,
> see enum DMAC_IM_BIT,


Is your idea to get rid of .eesipr_value for devices that have values
that are the same as .eesr_err_check?


For example in sh_eth_dev_init():

	sh_eth_modify(ndev, EESR, 0, 0);
	mdp->irq_enabled = true;
-	sh_eth_write(ndev, mdp->cd->eesipr_value, EESIPR);
+	if (mdp->cd->eesipr_value)
+		sh_eth_write(ndev, mdp->cd->eesipr_value, EESIPR);
+	else
+		sh_eth_write(ndev, mdp->cd->eesr_err_check, EESIPR);


Chris


  reply	other threads:[~2016-12-01 18:53 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-01 14:06 [PATCH v2] sh_eth: remove unchecked interrupts Chris Brandt
2016-12-01 14:42 ` Geert Uytterhoeven
2016-12-01 17:37   ` Sergei Shtylyov
2016-12-01 18:53     ` Chris Brandt [this message]
2016-12-02 12:18       ` Geert Uytterhoeven
2016-12-01 17:36 ` Sergei Shtylyov
2016-12-01 17:40   ` Sergei Shtylyov
2016-12-01 18:24     ` Chris Brandt
2016-12-01 18:28       ` Sergei Shtylyov

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=SG2PR06MB1165C7D7B7DFBAC4B5BAB09A8A8F0@SG2PR06MB1165.apcprd06.prod.outlook.com \
    --to=chris.brandt@renesas.com \
    --cc=davem@davemloft.net \
    --cc=geert+renesas@glider.be \
    --cc=geert@linux-m68k.org \
    --cc=horms+renesas@verge.net.au \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=sergei.shtylyov@cogentembedded.com \
    /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.