netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/4] net: dsa: move master ethtool code
@ 2017-09-19 15:56 Vivien Didelot
  2017-09-19 15:56 ` [PATCH net-next 1/4] net: dsa: remove copy of master ethtool_ops Vivien Didelot
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Vivien Didelot @ 2017-09-19 15:56 UTC (permalink / raw)
  To: netdev
  Cc: linux-kernel, kernel, David S. Miller, Florian Fainelli,
	Andrew Lunn, Vivien Didelot

The DSA core overrides the master device's ethtool_ops structure so that
it can inject statistics and such of its dedicated switch CPU port.

This ethtool code is currently called on unnecessary conditions or
before the master interface and its switch CPU port get wired up.
This patchset fixes this.

Similarly to slave.c where the DSA slave net_device is the entry point
of the dsa_slave_* functions, this patchset also isolates the master's
ethtool code in a new master.c file, where the DSA master net_device is
the entry point of the dsa_master_* functions.

This is a first step towards better control of the master device and
support for multiple CPU ports.

Vivien Didelot (4):
  net: dsa: remove copy of master ethtool_ops
  net: dsa: setup master ethtool unconditionally
  net: dsa: setup master ethtool after dsa_ptr
  net: dsa: move master ethtool code

 include/net/dsa.h  |   1 -
 net/dsa/Makefile   |   2 +-
 net/dsa/dsa.c      |  28 -------------
 net/dsa/dsa2.c     |  18 ++++----
 net/dsa/dsa_priv.h |   7 ++--
 net/dsa/legacy.c   |  10 ++---
 net/dsa/master.c   | 120 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 net/dsa/slave.c    |  80 -----------------------------------
 8 files changed, 136 insertions(+), 130 deletions(-)
 create mode 100644 net/dsa/master.c

-- 
2.14.1

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2017-09-19 23:04 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-09-19 15:56 [PATCH net-next 0/4] net: dsa: move master ethtool code Vivien Didelot
2017-09-19 15:56 ` [PATCH net-next 1/4] net: dsa: remove copy of master ethtool_ops Vivien Didelot
2017-09-19 19:55   ` Florian Fainelli
2017-09-19 15:56 ` [PATCH net-next 2/4] net: dsa: setup master ethtool unconditionally Vivien Didelot
2017-09-19 17:48   ` Florian Fainelli
2017-09-19 15:56 ` [PATCH net-next 3/4] net: dsa: setup master ethtool after dsa_ptr Vivien Didelot
2017-09-19 17:49   ` Florian Fainelli
2017-09-19 15:57 ` [PATCH net-next 4/4] net: dsa: move master ethtool code Vivien Didelot
2017-09-19 19:56   ` Florian Fainelli
2017-09-19 20:04 ` [PATCH net-next 0/4] " Florian Fainelli
2017-09-19 23:04   ` David Miller

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).