From owner-cvs-src-old@FreeBSD.ORG Sun Sep 20 12:57:07 2009 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 C3FDE1065693 for ; Sun, 20 Sep 2009 12:57: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 A90F48FC14 for ; Sun, 20 Sep 2009 12:57:07 +0000 (UTC) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id n8KCv7H0060364 for ; Sun, 20 Sep 2009 12:57:07 GMT (envelope-from marius@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id n8KCv7KP060363 for cvs-src-old@freebsd.org; Sun, 20 Sep 2009 12:57:07 GMT (envelope-from marius@repoman.freebsd.org) Message-Id: <200909201257.n8KCv7KP060363@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to marius@repoman.freebsd.org using -f From: Marius Strobl Date: Sun, 20 Sep 2009 12:56:50 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: RELENG_7 Subject: cvs commit: src/sys/conf files src/sys/dev/gem if_gem.c if_gem_pci.c if_gem_sbus.c if_gemreg.h if_gemvar.h src/sys/modules/gem Makefile 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: Sun, 20 Sep 2009 12:57:07 -0000 marius 2009-09-20 12:56:50 UTC FreeBSD src repository Modified files: (Branch: RELENG_7) sys/conf files sys/dev/gem if_gem.c if_gem_pci.c if_gemreg.h if_gemvar.h sys/modules/gem Makefile Added files: (Branch: RELENG_7) sys/dev/gem if_gem_sbus.c Log: SVN rev 197349 on 2009-09-20 12:56:50Z by marius MFC: r194763, r194886 - Initialize the ifnet structure, especially if_dname, before probing the PHYs as some PHY drivers use it (but probably shouldn't). How gem(4) has worked with brgphy(4) on powerpc without this so far is unclear to me. - Call ether_ifdetach(9) before stopping the controller and the callouts. The consensus is that the latter is now safe to do and should also solve the problem of active BPF listeners clearing promiscuous mode can result in the tick callout being restarted which in turn will trigger a panic once it's actually gone. - Introduce a dying flag which is set during detach and checked in gem_ioctl() in order to prevent active BPF listeners to clear promiscuous mode which may lead to the tick callout being restarted which will trigger a panic once it's actually gone. - In gem_stop() reset rather than just disable the transmitter and receiver in order to ensure we're not unloading DMA maps still in use by the hardware. [1] - The blanking time is specified in PCI clocks so we should use twice the value when operating at 66MHz. - Spell some 2 as ETHER_ALIGN and a 19 as GEM_STATUS_TX_COMPLETION_SHFT to make the actual intentions clear. - As we don't unload the peak attempts counter ignore its overflow interrupts. - Remove a stale setting of a variable to GEM_TD_INTERRUPT_ME which isn't used afterwards. - For optimum performance increment the TX kick register in multiples of 4 if possible as suggested by the documentation. - Partially revert r164931; drivers should only clear the watchdog timer if all outstanding TX descriptors are done. - Fix some debugging strings. - Add a missing BUS_DMASYNC_POSTWRITE in gem_rint(). - As the error paths in the interrupt handler are generally unlikely predict them as false. - Add support for the SBus version of the GEM controller. [2] - Add some lock assertions. - Improve some comments. - Fix some more or less cosmetic issues in the code of the PCI front-end. - Change some softc members to be unsigned where more appropriate and remove unused ones. Obtained from: NetBSD (partially) [2], OpenBSD [1] Revision Changes Path 1.1243.2.59 +1 -0 src/sys/conf/files 1.44.2.7 +143 -90 src/sys/dev/gem/if_gem.c 1.23.2.3 +23 -23 src/sys/dev/gem/if_gem_pci.c 1.1.4.2 +210 -0 src/sys/dev/gem/if_gem_sbus.c (new) 1.5.2.3 +164 -178 src/sys/dev/gem/if_gemreg.h 1.15.2.3 +21 -24 src/sys/dev/gem/if_gemvar.h 1.1.22.1 +5 -1 src/sys/modules/gem/Makefile