From: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
To: netdev@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com,
"David S. Miller" <davem@davemloft.net>,
Florian Fainelli <f.fainelli@gmail.com>,
Andrew Lunn <andrew@lunn.ch>,
Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Subject: [PATCH net-next v2 0/4] net: dsa: remove .set_addr
Date: Thu, 12 Oct 2017 21:41:09 -0400 [thread overview]
Message-ID: <20171013014113.29561-1-vivien.didelot@savoirfairelinux.com> (raw)
An Ethernet switch may support having a MAC address, which can be used
as the switch's source address in transmitted full-duplex Pause frames.
If a DSA switch supports the related .set_addr operation, the DSA core
sets the master's MAC address on the switch.
This won't make sense anymore in a multi-CPU ports system, because there
won't be a unique master device assigned to a switch tree.
Moreover this operation is confusing because it makes the user think
that it could be used to program the switch with the MAC address of the
CPU/management port such that MAC address learning can be disabled on
said port, but in fact, that's not how it is currently used.
To fix this, assign a random MAC address at setup time in the mv88e6060
and mv88e6xxx drivers before removing .set_addr completely from DSA.
Changes in v2:
- remove .set_addr implementation from drivers and use a random MAC.
Vivien Didelot (4):
net: dsa: mv88e6xxx: setup random mac address
net: dsa: mv88e6060: setup random mac address
net: dsa: dsa_loop: remove .set_addr
net: dsa: remove .set_addr
drivers/net/dsa/dsa_loop.c | 8 --------
drivers/net/dsa/mv88e6060.c | 30 +++++++++++++++++++-----------
drivers/net/dsa/mv88e6xxx/chip.c | 33 +++++++++++++++++----------------
include/net/dsa.h | 1 -
net/dsa/dsa2.c | 6 ------
net/dsa/legacy.c | 6 ------
6 files changed, 36 insertions(+), 48 deletions(-)
--
2.14.2
next reply other threads:[~2017-10-13 1:41 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-13 1:41 Vivien Didelot [this message]
2017-10-13 1:41 ` [PATCH net-next v2 1/4] net: dsa: mv88e6xxx: setup random mac address Vivien Didelot
2017-10-13 1:41 ` [PATCH net-next v2 2/4] net: dsa: mv88e6060: " Vivien Didelot
2017-10-13 15:30 ` David Laight
2017-10-13 16:02 ` Woojung.Huh
2017-10-13 16:44 ` Vivien Didelot
2017-10-13 17:59 ` Woojung.Huh
2017-10-16 9:02 ` David Laight
2017-10-13 1:41 ` [PATCH net-next v2 3/4] net: dsa: dsa_loop: remove .set_addr Vivien Didelot
2017-10-13 1:41 ` [PATCH net-next v2 4/4] net: dsa: " Vivien Didelot
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=20171013014113.29561-1-vivien.didelot@savoirfairelinux.com \
--to=vivien.didelot@savoirfairelinux.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=f.fainelli@gmail.com \
--cc=kernel@savoirfairelinux.com \
--cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox