From: "John W. Linville" <linville@tuxdriver.com>
To: Vivien Didelot <vivien.didelot@gmail.com>
Cc: netdev@vger.kernel.org, Chris Healy <cphealy@gmail.com>,
f.fainelli@gmail.com, andrew@lunn.ch
Subject: Re: [PATCH v2 0/7] ethtool: pretty dump mv88e6xxx registers
Date: Fri, 18 Jan 2019 13:40:54 -0500 [thread overview]
Message-ID: <20190118184054.GE30266@tuxdriver.com> (raw)
In-Reply-To: <20181218190641.31883-1-vivien.didelot@gmail.com>
On Tue, Dec 18, 2018 at 02:06:34PM -0500, Vivien Didelot wrote:
> This patch series adds support to pretty dump the registers of user
> ports created by the kernel "dsa" subsystem.
>
> The first patch adds the base support for "dsa" interfaces.
>
> The second patch adds the boilerplate for the "mv88e6xxx" DSA driver,
> all using 32 registers of 16 bits, the switch ID being assigned
> by the kernel driver into the regs version. Support for other DSA
> drivers such as "b53" or "ksz" can be added similarly later. Because
> the different switches supported by mv88e6xxx have slightly different
> register layout, we keep it simple and stupid by providing one dump
> function per switch.
>
> The remaining patches add support for the switch models currently
> supported by the mv88e6xxx driver. Here's an example of dump of the
> 32 registers of a 88E6352 port:
>
> # ethtool -d lan3
> 88E6352 Switch Port Registers
> ------------------------------
> 00: Port Status 0x500f
> Pause Enabled 0
> My Pause 1
> 802.3 PHY Detected 1
> Link Status Down
> Duplex Half
> Speed 10 Mbps
> EEE Enabled 0
> Transmitter Paused 0
> Flow Control 0
> Config Mode 0xf
> 01: Physical Control 0x0003
> RGMII Receive Timing Control Default
> RGMII Transmit Timing Control Default
> 200 BASE Mode 100
> Flow Control's Forced value 0
> Force Flow Control 0
> Link's Forced value Down
> Force Link 0
> Duplex's Forced value Half
> Force Duplex 0
> Force Speed Not forced
> 02: Jamming Control 0x0000
> 03: Switch Identifier 0x3521
> 04: Port Control 0x0433
> Source Address Filtering controls Disabled
> Egress Mode Unmodified
> Ingress & Egress Header Mode 0
> IGMP and MLD Snooping 1
> Frame Mode Normal
> VLAN Tunnel 0
> TagIfBoth 0
> Initial Priority assignment Tag & IP Priority
> Egress Flooding mode No unknown DA
> Port State Forwarding
> 05: Port Control 1 0x0000
> Message Port 0
> Trunk Port 0
> Trunk ID 0
> FID[11:4] 0x000
> 06: Port Base VLAN Map (Header) 0x0060
> FID[3:0] 0x000
> VLANTable 5 6
> 07: Default VLAN ID & Priority 0x0000
> Default Priority 0x0
> Force to use Default VID 0
> Default VLAN Identifier 0
> 08: Port Control 2 0x2080
> Force good FCS in the frame 0
> Jumbo Mode 10240
> 802.1QMode Disabled
> Discard Tagged Frames 0
> Discard Untagged Frames 0
> Map using DA hits 1
> ARP Mirror enable 0
> Egress Monitor Source Port 0
> Ingress Monitor Source Port 0
> Use Default Queue Priority 0
> Default Queue Priority 0x0
> 09: Egress Rate Control 0x0001
> 10: Egress Rate Control 2 0x0000
> 11: Port Association Vector 0x0001
> 12: Port ATU Control 0x0000
> 13: Override 0x0000
> 14: Policy Control 0x0000
> 15: Port Ether Type 0x9100
> 16: InDiscardsLo Frame Counter 0x0000
> 17: InDiscardsHi Frame Counter 0x0000
> 18: InFiltered/TcamCtr Frame Counter 0x0000
> 19: Rx Frame Counter 0x0000
> 20: Reserved 0x0000
> 21: Reserved 0x0000
> 22: LED Control 0x0022
> 23: Reserved 0x0000
> 24: Tag Remap 0-3 0x3210
> 25: Tag Remap 4-7 0x7654
> 26: Reserved 0x0000
> 27: Queue Counters 0x8000
> 28: Reserved 0x0000
> 29: Reserved 0x0000
> 30: Reserved 0x0000
> 31: Reserved 0x0000
>
>
> Changes in v2:
> - read the switch model from regs->version instead of regs[3]
>
>
> Vivien Didelot (7):
> ethtool: dsa: add pretty dump
> ethtool: dsa: mv88e6xxx: add pretty dump
> ethtool: dsa: mv88e6xxx: add pretty dump for 88E6185
> ethtool: dsa: mv88e6xxx: add pretty dump for 88E6161
> ethtool: dsa: mv88e6xxx: add pretty dump for 88E6352
> ethtool: dsa: mv88e6xxx: add pretty dump for 88E6390
> ethtool: dsa: mv88e6xxx: add pretty dump for others
>
> Makefile.am | 2 +-
> dsa.c | 685 ++++++++++++++++++++++++++++++++++++++++++++++++++++
> ethtool.c | 1 +
> internal.h | 3 +
> 4 files changed, 690 insertions(+), 1 deletion(-)
> create mode 100644 dsa.c
Queued for next release.
--
John W. Linville Someday the world will need a hero, and you
linville@tuxdriver.com might be all we have. Be ready.
prev parent reply other threads:[~2019-01-18 18:45 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-18 19:06 [PATCH v2 0/7] ethtool: pretty dump mv88e6xxx registers Vivien Didelot
2018-12-18 19:06 ` [PATCH v2 1/7] ethtool: dsa: add pretty dump Vivien Didelot
2018-12-18 19:06 ` [PATCH v2 2/7] ethtool: dsa: mv88e6xxx: " Vivien Didelot
2018-12-18 19:06 ` [PATCH v2 3/7] ethtool: dsa: mv88e6xxx: add pretty dump for 88E6185 Vivien Didelot
2018-12-18 19:06 ` [PATCH v2 4/7] ethtool: dsa: mv88e6xxx: add pretty dump for 88E6161 Vivien Didelot
2018-12-18 19:06 ` [PATCH v2 5/7] ethtool: dsa: mv88e6xxx: add pretty dump for 88E6352 Vivien Didelot
2018-12-18 19:06 ` [PATCH v2 6/7] ethtool: dsa: mv88e6xxx: add pretty dump for 88E6390 Vivien Didelot
2018-12-18 19:06 ` [PATCH v2 7/7] ethtool: dsa: mv88e6xxx: add pretty dump for others Vivien Didelot
2018-12-19 9:41 ` [PATCH v2 0/7] ethtool: pretty dump mv88e6xxx registers Andrew Lunn
2019-01-18 18:40 ` John W. Linville [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=20190118184054.GE30266@tuxdriver.com \
--to=linville@tuxdriver.com \
--cc=andrew@lunn.ch \
--cc=cphealy@gmail.com \
--cc=f.fainelli@gmail.com \
--cc=netdev@vger.kernel.org \
--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).