From owner-cvs-src-old@FreeBSD.ORG Mon Jul 25 17:19:07 2011 Return-Path: Delivered-To: cvs-src-old@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 716A41065670 for ; Mon, 25 Jul 2011 17:19:07 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 473748FC0C for ; Mon, 25 Jul 2011 17:19:07 +0000 (UTC) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.4/8.14.4) with ESMTP id p6PHJ7CZ087933 for ; Mon, 25 Jul 2011 17:19:07 GMT (envelope-from marius@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.4/8.14.4/Submit) id p6PHJ7L9087932 for cvs-src-old@freebsd.org; Mon, 25 Jul 2011 17:19:07 GMT (envelope-from marius@repoman.freebsd.org) Message-Id: <201107251719.p6PHJ7L9087932@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to marius@repoman.freebsd.org using -f From: Marius Strobl Date: Mon, 25 Jul 2011 17:18:47 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: RELENG_7 Subject: cvs commit: src/sbin/ifconfig ifmedia.c X-BeenThere: cvs-src-old@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: **OBSOLETE** CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Jul 2011 17:19:07 -0000 marius 2011-07-25 17:18:47 UTC FreeBSD src repository Modified files: (Branch: RELENG_7) sbin/ifconfig ifmedia.c Log: SVN rev 224343 on 2011-07-25 17:18:47Z by marius MFC: r221954 When setting media always and not just in case of switching to IFM_AUTO clear the options of the current media, i.e. only inherit the instance, which matches what NetBSD does. Without this it's really non-intuitive that the following sequence: ifconfig bge0 media 1000baseT mediaopt full-duplex ifconfig bge0 media 100baseTX results in 100baseTX full-duplex to be set or that: ifconfig bge0 media autoselect mediaopt flowcontrol ifconfig bge0 media 1000baseT mediaopt full-duplex tries to set 1000baseT full-duplex with flowcontrol, which isn't suported und thus fails while the following: ifconfig re0 media 1000baseT mediaopt flowcontrol,full-duplex ifconfig re0 media autoselect just switches to autoselection without flowcontrol. Revision Changes Path 1.25.2.3 +1 -5 src/sbin/ifconfig/ifmedia.c