From sacadmin Wed May 23 17:57:44 2007
Received: from sac.sfbay.sun.com (localhost [127.0.0.1])
	by sac.sfbay.sun.com (8.13.8+Sun/8.13.8) with ESMTP id l4O0viUU018086;
	Wed, 23 May 2007 17:57:44 -0700 (PDT)
Received: (from gd78059@localhost)
	by sac.sfbay.sun.com (8.13.8+Sun/8.13.8/Submit) id l4O0vigB018082;
	Wed, 23 May 2007 17:57:44 -0700 (PDT)
Date: Wed, 23 May 2007 17:57:44 -0700 (PDT)
From: "Garrett  D'Amore - sun microsystems" <gd78059@sac.sfbay.sun.com>
Message-Id: <200705240057.l4O0vigB018082@sac.sfbay.sun.com>
To: PSARC@sac.sfbay.sun.com
Cc: Garrett.Damore@Sun.COM
Subject: nemo ethernet stats update, part 2 [PSARC/2007/296 Self Review]
Status: RO
Content-Length: 4055


I'm submitting the follow case on my own behalf.  This project is intended
to add four more kstats to Nemo for ethernet, that I've found working with
legacy drivers like hme.

Since this change won't impact existing code, I'm filing it for self-review.
It adds three stable kstats though (for 100BaseT4), but this follows closely
the example set for the other MII stats, so it seems noncontroversial enough
to qualify for self-review.


Template Version: @(#)sac_nextcase 1.58 05/23/07 SMI
This information is Copyright 2007 Sun Microsystems
1. Introduction
    1.1. Project/Component Working Name:
	 nemo ethernet stats update, part 2
    1.2. Name of Document Author/Supplier:
	 Author:  Garrett D'Amore
    1.3  Date of This Document:
	23 May, 2007
4. Technical Description

Problem
-------

There are a few more ethernet kstats that need to be added to the Nemo (GLDv3)
framework for NIC drivers.

Specifically, we need a way to report Jabbers (almost all ethernt drivers
support this), and we need a way to be able to report 100T4 modes of operation.
(The 100T4 modes are needed by any driver supporting a chip that has an
external MII port, for example.)

Drivers which need this feature include the common "hme" driver, as well
as a number of less common variants.


Solution 
--------

We propose adding the following kstats for the mac_ether plugin:

	/* ether_stat enumeration */	/* kstat name */

	ETHER_STAT_JABBER_ERRORS	"jabber_errors"
	ETHER_STAT_CAP_100T4		"cap_100T4"
	ETHER_STAT_ADV_CAP_100T4	"adv_cap_100T4"
	ETHER_STAT_LP_CAP_100T4		"lp_cap_100T4"

Note that most drivers report "jabbers" rather than "jabber_errors", but
we chose the longer name to fit more closely with current Nemo practice.


Interface Binding
-----------------

We are requesting the following interface bindings:

	ETHER_STAT_JABBER_ERRORS	Consolidation Private
	ETHER_STAT_CAP_100T4		Consolidation Private
	ETHER_STAT_ADV_CAP_100T4	Consolidation Private
	ETHER_STAT_LP_CAP_100T4		Consolidation Private

	"jabber_errors"			Unstable

	"cap_100T4"			Stable
	"adv_cap_100T4"			Stable
	"lp_cap_100T4"			Stable

The reason the last three kstats are Stable is to fit with the other MII
stats that are already stable, as documented in iee802.3(5).  See below
for more detail.


Man Page Changes
----------------

Following is the diffs required for the ieee802.3 man page.

--- /tmp/ieee802.3.old  Wed May 23 17:41:32 2007
+++ /tmp/ieee802.3.new  Wed May 23 17:44:18 2007
@@ -7,12 +7,12 @@
 
 NAME
      ieee802.3,    cap_autoneg,     cap_1000fdx,     cap_1000hdx,
-     cap_100fdx, cap_100hdx, cap_10fdx, cap_10hdx, cap_rem_fault,
+     cap_100T4, cap_100fdx, cap_100hdx, cap_10fdx, cap_10hdx, cap_rem_fault,
      cap_pause, cap_asmpause,  adv_cap_autoneg,  adv_cap_1000fdx,
-     adv_cap_1000hdx,       adv_cap_100fdx,       adv_cap_100hdx,
+     adv_cap_1000hdx, adv_cap_100fdx,  adv_cap_100hdx, adv_cap_100T4,
      adv_cap_10fdx,         adv_cap_10hdx,         adv_cap_pause,
      adv_cap_asmpause,       adv_rem_fault,       lp_cap_autoneg,
-     lp_cap_1000fdx,        lp_cap_1000hdx,        lp_cap_100fdx,
+     lp_cap_1000fdx, lp_cap_1000hdx, lp_cap_100fdx, lp_cap_100T4,
      lp_cap_100hdx,   lp_cap_10fdx,  lp_cap_10hdx,  lp_cap_pause,
      lp_cap_asmpause,    lp_rem_fault,    xcvr_addr,     xcvr_id,
      xcvr_inuse,  link_up, link_duplex, link_pause, link_asmpause
@@ -51,6 +51,7 @@
      cap_1000hdx    Capable of 1000 half duplex operation
 
 
+     cap_100T4      Capable of 100T4 operation
 
 
      cap_100fdx     Capable of 100 full duplex operation
@@ -146,6 +147,7 @@
 
 
 
+     adv_cap_100T4    Advertise 100T4 capability
 
      adv_cap_100fdx   Advertise 100 full duplex capability
 
@@ -231,7 +233,9 @@
 
 
 
+     lp_cap_100T4   Link  partner  advertises  100T4 capaibilty
 
+
      lp_cap_100fdx   Link  partner  advertises  100  full  duplex
                      capability
 

6. Resources and Schedule
    6.4. Steering Committee requested information
   	6.4.1. Consolidation C-team Name:
		ON
    6.5. ARC review type: Automatic

