From owner-freebsd-net@FreeBSD.ORG Tue Dec 13 09:36:02 2011 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C1CF81065673 for ; Tue, 13 Dec 2011 09:36:02 +0000 (UTC) (envelope-from sthaug@nethelp.no) Received: from bizet.nethelp.no (bizet.nethelp.no [195.1.209.33]) by mx1.freebsd.org (Postfix) with SMTP id 0CAF08FC0C for ; Tue, 13 Dec 2011 09:36:01 +0000 (UTC) Received: (qmail 42129 invoked from network); 13 Dec 2011 09:09:18 -0000 Received: from bizet.nethelp.no (HELO localhost) (195.1.209.33) by bizet.nethelp.no with SMTP; 13 Dec 2011 09:09:18 -0000 Date: Tue, 13 Dec 2011 10:09:18 +0100 (CET) Message-Id: <20111213.100918.41670796.sthaug@nethelp.no> To: pyunyh@gmail.com, stb@lassitu.de From: sthaug@nethelp.no In-Reply-To: <20111213025041.GF3705@michelle.cdnetworks.com> References: <600A8C6C-DAB4-4E22-A034-38224017166B@lassitu.de> <20111213025041.GF3705@michelle.cdnetworks.com> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-net@freebsd.org Subject: Re: "ifconfig media off"? X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2011 09:36:02 -0000 > > I'm currently writing a driver to configure an ethernet switch chip (see TL-WR1043ND on -embedded). > > > > I noticed that there doesn't seem to be a way to power down a phy right now through the ifconfig media command. > > > > Would there be objections to extend the media subtype definitions to include an "off", "poweroff" or "down" media subtype, and add code to the relevant phy drivers to power down the phy for this media subtype? > > > > The difference between media subtype "none" and this new one would be that there will be no link, even if there is a physical connection. With media subtype "none", a 10 MBit/s half-duplex connection is established, potentially confusing the remote end about the availability of this link. On the local side, the link is down, so no packets are exchanged. I have actually wanted this capability for quite a while now. Working for an ISP and being used to routers and switches where ports can be completely turned off, I see this as a welcome addition to FreeBSD. Steinar Haug, Nethelp consulting, sthaug@nethelp.no