Netdev List
 help / color / mirror / Atom feed
From: <Claudiu.Beznea@microchip.com>
To: <harinik@xilinx.com>
Cc: <harini.katakam@xilinx.com>, <Nicolas.Ferre@microchip.com>,
	<davem@davemloft.net>, <netdev@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>, <michal.simek@xilinx.com>
Subject: Re: [RFC PATCH] net: macb: Apply RXUBR workaround only to versions with errata
Date: Thu, 29 Nov 2018 10:43:41 +0000	[thread overview]
Message-ID: <fbd59625-b36b-76f3-6f88-78efe901f67a@microchip.com> (raw)
In-Reply-To: <CAFcVECKw0utBH6-owf-0C1M07Tr2tH3Gu=X7cp04XuvXWHoJiA@mail.gmail.com>



On 29.11.2018 12:38, Harini Katakam wrote:
> Hi Claudiu,
> On Thu, Nov 29, 2018 at 3:51 PM <Claudiu.Beznea@microchip.com> wrote:
>>
>>
>>
>> On 23.11.2018 11:59, Harini Katakam wrote:
> <snip>
>>> -             if (status & MACB_BIT(RXUBR)) {
>>> +             if ((bp->errata & MACB_ERRATA_RXLOCKUP) &&
>>> +                 (status & MACB_BIT(RXUBR))) {
>>
>> Just asking, did you manage to test this on other platforms that haven't
>> this issue?
>> SAMA5D2 datasheet [1] states this:
>> "When in packet buffer full store and forward mode, only good received
>> frames are written out of the DMA, so no
>>  fragments will exist in the AHB buffers due to MAC receiver errors. There
>> is still the possibility of fragments due to
>>  DMA errors, for example used bit read on the second buffer of a
>> multibuffer frame."
>>
>> But it is true that nowhere is presented that this must be special treated.
>>
> 
> Yes, I tested it on ZynqMP which does NOT have this errata - did perf and
> ping flood and dint see any issues.

Great! Thank you, Harini!

> Just FYI, the errata in the IP version in Zynq causes an RX lock up under
> high stress (when there is obviously multiple RXUBR interrupts). The RX reset
> is a pre-emptive workaround to *mostly* avoid the issue.
> Please see Answer record 52028 in
> https://www.xilinx.com/support/documentation/errata/en247.pdf
> 
>> Moreover, if you do this only for MACB_ERRATA_RXLOCKUP and still have RXUBR
>> interrupt enabled every time it would not make sense to still enable it.
>> Or, if you want it enabled every time, you should clear it no matter the
>> MACB_ERRATA_RXLOCKUP is set or not, with something like this:
>>
>>                         if (bp->caps & MACB_CAPS_ISR_CLEAR_ON_WRITE)
>>
>>                                 queue_writel(queue, ISR, MACB_BIT(RXUBR));
>>
>>
> Thanks for pointing this out - yes i'll move the WTC code outside the check.
> 
> Regards,
> Harini
> 

      reply	other threads:[~2018-11-29 10:43 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-23  9:59 [RFC PATCH] net: macb: Apply RXUBR workaround only to versions with errata Harini Katakam
2018-11-28 21:09 ` Brandon Streiff
2018-11-29  5:13   ` Harini Katakam
2018-11-29 10:00   ` Claudiu.Beznea
2018-11-29 10:21 ` Claudiu.Beznea
2018-11-29 10:38   ` Harini Katakam
2018-11-29 10:43     ` Claudiu.Beznea [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=fbd59625-b36b-76f3-6f88-78efe901f67a@microchip.com \
    --to=claudiu.beznea@microchip.com \
    --cc=Nicolas.Ferre@microchip.com \
    --cc=davem@davemloft.net \
    --cc=harini.katakam@xilinx.com \
    --cc=harinik@xilinx.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michal.simek@xilinx.com \
    --cc=netdev@vger.kernel.org \
    /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