All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefan Agner <stefan@agner.ch>
To: Andy Duan <fugang.duan@nxp.com>, Andrew Lunn <andrew@lunn.ch>
Cc: festevam@gmail.com, netdev@vger.kernel.org, netdev-owner@vger.kernel.org
Subject: Re: FEC on i.MX 7 transmit queue timeout
Date: Mon, 08 May 2017 11:22:35 -0700	[thread overview]
Message-ID: <d48a6d17b05280331642ea683caabc81@agner.ch> (raw)
In-Reply-To: <AM4PR0401MB2260D9D293EE8A37B93554F6FFEE0@AM4PR0401MB2260.eurprd04.prod.outlook.com>

On 2017-05-07 19:13, Andy Duan wrote:
> From: Andrew Lunn <andrew@lunn.ch> Sent: Friday, May 05, 2017 8:24 PM
>>To: Andy Duan <fugang.duan@nxp.com>
>>Cc: Stefan Agner <stefan@agner.ch>; festevam@gmail.com;
>>netdev@vger.kernel.org; netdev-owner@vger.kernel.org
>>Subject: Re: FEC on i.MX 7 transmit queue timeout
>>
>>> No, it is not workaround. As i said, quque1 and queue2 are for AVB
>>> paths have higher priority in transmition.
>>
>>Does this higher priority result in the low priority queue being starved? Is that
>>why the timer goes off? What happens when somebody does use AVB. Are
>>we back to the same problem? This is what seems to make is sounds like a
>>work around, not a fix.
>>
>>     Andrew
> Yes, queue0 may be blocked by queue1 and queue2, then the queue0
> watchdog time maybe triggered.
> If somebody use AVB quque1 and queue2, the remaining bandwidth is for
> queue0, for example, in 100Mbps system, quque1 cost 50Mbps bandwidth
> and queue2 cost 50Mbps bandwidth for audio and video streaming, then
> queue0 (best effort) has 0 bandwidth that limit user case cannot have 
> asynchronous frames (IP(tcp/udp)) on networking. Of course these is
> extreme case.
> In essentially,  asynchronous frames (IP) go queue0 for the original
> design. To do these just implement .ndo_select_queue() callback in
> driver like fsl tree.

I guess you refer to this commit?

http://git.freescale.com/git/cgit.cgi/imx/linux-imx.git/commit/?h=imx_4.1.15_2.0.0_ga&id=b0d8fa989651baf847287f6888f4d7b723e2a207

It seems that by default there is a Credit-based scheme enabled
(ENETx_QOS[TX_SCHEME] = 000). The driver enables the queue1/2 and
assigns it each 50% of the bandwidth (IDLE_SLOPE_1/2 is set to 0x200,
which according to the register description of IDLE_SLOPE means BW
fraction of 0.5!). This actually violates even the note in register
ENETx_DMAnCFG:

"NOTE: For AVB applications, the BW fraction of class 1 and class 2
combined must not exceed .75."

Instead of using the credit based scheme we could switch to round robin,
but not sure if that is what we want.

What is the default criteria to select queues when .ndo_select_queue is
not provided? I guess it tries to balance individual streams/processes
for better SMP performance?

  reply	other threads:[~2017-05-08 18:23 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-18 19:46 FEC on i.MX 7 transmit queue timeout Stefan Agner
2017-04-19  2:24 ` Andy Duan
2017-04-19  5:01   ` Stefan Agner
2017-04-19  5:28     ` Andy Duan
2017-04-19  5:56       ` Stefan Agner
2017-04-19  8:45         ` Andy Duan
2017-04-19 23:15           ` Stefan Agner
2017-04-21  2:48             ` Andy Duan
2017-05-04  1:21               ` Stefan Agner
2017-05-04  3:08                 ` Andy Duan
2017-05-04 21:36                   ` Stefan Agner
2017-05-05  2:03                     ` Andy Duan
2017-05-05  2:09                       ` Stefan Agner
2017-05-05  2:44                         ` Andy Duan
2017-05-05 12:23                           ` Andrew Lunn
2017-05-08  2:13                             ` Andy Duan
2017-05-08 18:22                               ` Stefan Agner [this message]
2017-05-09 10:35                                 ` Andy Duan

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=d48a6d17b05280331642ea683caabc81@agner.ch \
    --to=stefan@agner.ch \
    --cc=andrew@lunn.ch \
    --cc=festevam@gmail.com \
    --cc=fugang.duan@nxp.com \
    --cc=netdev-owner@vger.kernel.org \
    --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 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.