From nobody@FreeBSD.org  Tue Dec 13 09:37:57 2011
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 38F82106567A
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 13 Dec 2011 09:37:57 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id 28D6B8FC12
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 13 Dec 2011 09:37:57 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.4/8.14.4) with ESMTP id pBD9buaJ057452
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 13 Dec 2011 09:37:56 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.4/8.14.4/Submit) id pBD9buJF057451;
	Tue, 13 Dec 2011 09:37:56 GMT
	(envelope-from nobody)
Message-Id: <201112130937.pBD9buJF057451@red.freebsd.org>
Date: Tue, 13 Dec 2011 09:37:56 GMT
From: Stefan Bethke <stb@lassitu.de>
To: freebsd-gnats-submit@FreeBSD.org
Subject: Power down PHY when "none" media is selected
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         163240
>Category:       kern
>Synopsis:       Power down PHY when "none" media is selected
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    marius
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Dec 13 09:40:09 UTC 2011
>Closed-Date:    
>Last-Modified:  Tue Dec 13 13:26:12 UTC 2011
>Originator:     Stefan Bethke
>Release:        -current r228399
>Organization:
>Environment:
>Description:
Per discussion on -net, it would be advantageous to power down a PHY when not in use, so that no link is established to the remote end of the cable.

The patch adds the power-down bit to the bits to be set for the "none" media selection to the common PHY code, enabling powering down the PHY for the following PHY drivers:
 ac am ax bmt ics lxt ml nsg ns pna qs rdc rl smc tdk tl true uk

>How-To-Repeat:

>Fix:
Index: sys/dev/mii/mii_physubr.c
===================================================================
--- sys/dev/mii/mii_physubr.c	(revision 228402)
+++ sys/dev/mii/mii_physubr.c	(working copy)
@@ -58,7 +58,7 @@
  */
 static const struct mii_media mii_media_table[MII_NMEDIA] = {
 	/* None */
-	{ BMCR_ISO,		ANAR_CSMA,
+	{ BMCR_ISO | BMCR_PDOWN,	ANAR_CSMA,
 	  0, },
 
 	/* 10baseT */


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->marius 
Responsible-Changed-By: marius 
Responsible-Changed-When: Tue Dec 13 13:25:33 UTC 2011 
Responsible-Changed-Why:  
grab 

http://www.freebsd.org/cgi/query-pr.cgi?pr=163240 
>Unformatted:
