All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marc Gonzalez <marc_gonzalez@sigmadesigns.com>
To: Mans Rullgard <mans@mansr.com>
Cc: David Miller <davem@davemloft.net>,
	netdev <netdev@vger.kernel.org>,
	"Linux ARM" <linux-arm-kernel@lists.infradead.org>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Thibaud Cornic <thibaud_cornic@sigmadesigns.com>,
	Mason <slash.tmp@free.fr>
Subject: Re: [PATCH v3 3/4] net: nb8800: Move HW init to ndo_open()
Date: Tue, 14 Nov 2017 14:26:29 +0100	[thread overview]
Message-ID: <4e22ef54-d823-fc29-fedc-d447fa3d9c88@sigmadesigns.com> (raw)
In-Reply-To: <yw1xwp2t11ap.fsf@mansr.com>

On 14/11/2017 13:40, Måns Rullgård wrote:

> Marc Gonzalez wrote:
> 
>> Power entire ethernet block down in ndo_stop().
>> Power it back up in ndo_open() and perform HW init.
>> Delete nb8800_dma_stop.
> 
> Leave it alone, please.  Not all chips might have a separate power
> domain for this.  Also, it works just fine on the older chips.

There is no need for separate power domains. The ethernet block is
clock-gated when it is held in reset. The reset register is implemented
on all tango3, tango4, tango5 chips.

nb8800_dma_stop() is a hack. The HW dev has stated that it is not supported.
One cannot conclude that it "works fine" just because you've never triggered
the error condition. (On tango5, the error condition triggers systematically.)

We have several customer bug reports on tango3 and tango4 chips complaining
about "broken" ethernet after a link down / link up cycle. They are using a
different driver, but it implements the same hack in enet_stop_rx().
There is a high probability that the DMA hack is responsible, and wedged the
RX DMA state machine.

Since older chips do support the reset register, this patch implements
the same method for all tango chips.

WARNING: multiple messages have this Message-ID (diff)
From: marc_gonzalez@sigmadesigns.com (Marc Gonzalez)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v3 3/4] net: nb8800: Move HW init to ndo_open()
Date: Tue, 14 Nov 2017 14:26:29 +0100	[thread overview]
Message-ID: <4e22ef54-d823-fc29-fedc-d447fa3d9c88@sigmadesigns.com> (raw)
In-Reply-To: <yw1xwp2t11ap.fsf@mansr.com>

On 14/11/2017 13:40, M?ns Rullg?rd wrote:

> Marc Gonzalez wrote:
> 
>> Power entire ethernet block down in ndo_stop().
>> Power it back up in ndo_open() and perform HW init.
>> Delete nb8800_dma_stop.
> 
> Leave it alone, please.  Not all chips might have a separate power
> domain for this.  Also, it works just fine on the older chips.

There is no need for separate power domains. The ethernet block is
clock-gated when it is held in reset. The reset register is implemented
on all tango3, tango4, tango5 chips.

nb8800_dma_stop() is a hack. The HW dev has stated that it is not supported.
One cannot conclude that it "works fine" just because you've never triggered
the error condition. (On tango5, the error condition triggers systematically.)

We have several customer bug reports on tango3 and tango4 chips complaining
about "broken" ethernet after a link down / link up cycle. They are using a
different driver, but it implements the same hack in enet_stop_rx().
There is a high probability that the DMA hack is responsible, and wedged the
RX DMA state machine.

Since older chips do support the reset register, this patch implements
the same method for all tango chips.

  reply	other threads:[~2017-11-14 13:26 UTC|newest]

Thread overview: 70+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-14 10:53 [PATCH v3 0/4] Various nb8800 tweaks Marc Gonzalez
2017-11-14 10:53 ` Marc Gonzalez
2017-11-14 10:54 ` [PATCH v3 1/4] net: nb8800: Drop generic support Marc Gonzalez
2017-11-14 10:54   ` Marc Gonzalez
2017-11-14 12:37   ` Måns Rullgård
2017-11-14 12:37     ` Måns Rullgård
2017-11-14 12:47     ` Marc Gonzalez
2017-11-14 12:47       ` Marc Gonzalez
2017-11-14 13:03       ` Måns Rullgård
2017-11-14 13:03         ` Måns Rullgård
2017-11-14 10:55 ` [PATCH v3 2/4] net: nb8800: Simplify nb8800_pause_config() Marc Gonzalez
2017-11-14 10:55   ` Marc Gonzalez
2017-11-14 12:38   ` Måns Rullgård
2017-11-14 12:38     ` Måns Rullgård
2017-11-14 12:56     ` Marc Gonzalez
2017-11-14 12:56       ` Marc Gonzalez
2017-11-14 13:22       ` Måns Rullgård
2017-11-14 13:22         ` Måns Rullgård
2017-11-15 10:53         ` Marc Gonzalez
2017-11-15 10:53           ` Marc Gonzalez
2017-11-15 14:17           ` Andrew Lunn
2017-11-15 14:17             ` Andrew Lunn
2017-11-15 14:33             ` Marc Gonzalez
2017-11-15 14:33               ` Marc Gonzalez
2017-11-15 15:03               ` Andrew Lunn
2017-11-15 15:03                 ` Andrew Lunn
2017-11-15 15:19                 ` Marc Gonzalez
2017-11-15 15:19                   ` Marc Gonzalez
2017-11-15 15:36                   ` Måns Rullgård
2017-11-15 15:36                     ` Måns Rullgård
2017-11-15 21:12                   ` Andrew Lunn
2017-11-15 21:12                     ` Andrew Lunn
2017-11-14 10:56 ` [PATCH v3 3/4] net: nb8800: Move HW init to ndo_open() Marc Gonzalez
2017-11-14 10:56   ` Marc Gonzalez
2017-11-14 12:40   ` Måns Rullgård
2017-11-14 12:40     ` Måns Rullgård
2017-11-14 13:26     ` Marc Gonzalez [this message]
2017-11-14 13:26       ` Marc Gonzalez
2017-11-14 13:54       ` Måns Rullgård
2017-11-14 13:54         ` Måns Rullgård
2017-11-14 16:41         ` Marc Gonzalez
2017-11-14 16:41           ` Marc Gonzalez
2017-11-14 16:55           ` Måns Rullgård
2017-11-14 16:55             ` Måns Rullgård
2017-11-14 17:07             ` Marc Gonzalez
2017-11-14 17:07               ` Marc Gonzalez
2017-11-15 14:58             ` Marc Gonzalez
2017-11-15 14:58               ` Marc Gonzalez
2017-11-15 15:11               ` Måns Rullgård
2017-11-15 15:11                 ` Måns Rullgård
2017-11-15 16:15                 ` Marc Gonzalez
2017-11-15 16:15                   ` Marc Gonzalez
2017-11-16 12:21                   ` Marc Gonzalez
2017-11-16 12:21                     ` Marc Gonzalez
2017-11-16 16:23                     ` Andrew Lunn
2017-11-16 16:23                       ` Andrew Lunn
2017-11-16 16:52                       ` Marc Gonzalez
2017-11-16 16:52                         ` Marc Gonzalez
2017-11-14 12:04 ` [PATCH v3 4/4] net: nb8800: Add support for suspend/resume Marc Gonzalez
2017-11-14 12:04   ` Marc Gonzalez
2017-11-14 13:02   ` Måns Rullgård
2017-11-14 13:02     ` Måns Rullgård
2017-11-14 14:22     ` Marc Gonzalez
2017-11-14 14:22       ` Marc Gonzalez
2017-11-14 16:31       ` Andrew Lunn
2017-11-14 16:31         ` Andrew Lunn
2017-11-14 17:08         ` Marc Gonzalez
2017-11-14 17:08           ` Marc Gonzalez
2017-11-14 17:33           ` Andrew Lunn
2017-11-14 17:33             ` Andrew Lunn

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=4e22ef54-d823-fc29-fedc-d447fa3d9c88@sigmadesigns.com \
    --to=marc_gonzalez@sigmadesigns.com \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=mans@mansr.com \
    --cc=netdev@vger.kernel.org \
    --cc=slash.tmp@free.fr \
    --cc=thibaud_cornic@sigmadesigns.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.