netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ansuel Smith <ansuelsmth@gmail.com>
To: Andrew Lunn <andrew@lunn.ch>
Cc: Vivien Didelot <vivien.didelot@gmail.com>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Vladimir Oltean <olteanv@gmail.com>,
	"David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 2/2] drivers: net: dsa: qca8k: add support for multiple cpu port
Date: Tue, 6 Apr 2021 07:16:08 +0200	[thread overview]
Message-ID: <YGvumGtEJYYvTlc9@Ansuel-xps.localdomain> (raw)
In-Reply-To: <YGz/nu117LDEhsou@lunn.ch>

On Wed, Apr 07, 2021 at 02:41:02AM +0200, Andrew Lunn wrote:
> On Tue, Apr 06, 2021 at 06:50:40AM +0200, Ansuel Smith wrote:
> > qca8k 83xx switch have 2 cpu ports. Rework the driver to support
> > multiple cpu port. All ports can access both cpu ports by default as
> > they support the same features.
> 
> Do you have more information about how this actually works. How does
> the switch decide which port to use when sending a frame towards the
> CPU? Is there some sort of load balancing?
> 
> How does Linux decide which CPU port to use towards the switch?
> 
>     Andrew

I could be very wrong, but in the current dsa code, only the very first
cpu port is used and linux use only that to send data.
In theory the switch send the frame to both CPU, I'm currently testing a
multi-cpu patch for dsa and I can confirm that with the proposed code
the packets are transmitted correctly and the 2 cpu ports are used.
(The original code has one cpu dedicated to LAN ports and one cpu
dedicated to the unique WAN port.) Anyway in the current implementation
nothing will change. DSA code still supports one cpu and this change
would only allow packet to be received and trasmitted from the second
cpu.


  reply	other threads:[~2021-04-07  0:57 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-06  4:50 [PATCH v2 1/2] include: net: add dsa_cpu_ports function Ansuel Smith
2021-04-06  4:50 ` [PATCH v2 2/2] drivers: net: dsa: qca8k: add support for multiple cpu port Ansuel Smith
2021-04-07  0:41   ` Andrew Lunn
2021-04-06  5:16     ` Ansuel Smith [this message]
2021-04-09 18:15       ` Florian Fainelli
2021-04-09 10:25         ` Ansuel Smith

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=YGvumGtEJYYvTlc9@Ansuel-xps.localdomain \
    --to=ansuelsmth@gmail.com \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=vivien.didelot@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).