From owner-cvs-all@FreeBSD.ORG Wed Apr 16 11:30:18 2008 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 327A71065671; Wed, 16 Apr 2008 11:30:18 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from semihalf.com (semihalf.com [206.130.101.55]) by mx1.freebsd.org (Postfix) with ESMTP id A6FD58FC26; Wed, 16 Apr 2008 11:30:17 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from mail.semihalf.com (mail.semihalf.com [83.15.139.206]) by semihalf.com (8.13.1/8.13.1) with ESMTP id m3GB7rLl015196; Wed, 16 Apr 2008 05:07:54 -0600 Message-ID: <4805DE07.8050008@semihalf.com> Date: Wed, 16 Apr 2008 13:07:51 +0200 From: Rafal Jaworowski MIME-Version: 1.0 To: Marius Strobl References: <200803121601.m2CG1ZbG072258@repoman.freebsd.org> <20080412221501.GB44768@alchemy.franken.de> In-Reply-To: <20080412221501.GB44768@alchemy.franken.de> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: cvs-src@freebsd.org, src-committers@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/sys/boot/common dev_net.c src/sys/boot/uboot/lib console.c copy.c glue.c libuboot.h net.c time.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Apr 2008 11:30:18 -0000 Marius Strobl wrote: >> raj 2008-03-12 16:01:34 UTC >> >> FreeBSD src repository >> >> Modified files: >> sys/boot/common dev_net.c >> sys/boot/uboot/lib console.c copy.c glue.c libuboot.h net.c >> time.c >> Log: >> Eliminate artificial increasing of 'netdev_opens' counter in loader's net_open(). >> >> This was introduced as a workaround long time ago for some Alpha firmware >> (which is now gone), and actually prevented net_close() to ever be >> called. >> >> Certain firmwares (U-Boot) need local shutdown operations to be performed on a >> network controller upon transaction end: such platform-specific hooks are >> supposed to be called via netif_close() (from within net_close()). >> >> This change effectively reverts the following CVS commit: >> >> sys/boot/common/dev_net.c >> >> revision 1.7 >> date: 2000/05/13 15:40:46; author: dfr; state: Exp; lines: +2 -1 >> Only probe network settings on the first open of the network device. >> The alpha firmware takes a seriously long time to open the network device >> the first time. >> > > On at least sparc64 reverting this causes ofwn_init() to be called > over and over again, which doesn't seem to be the right thing to do > either. I think this is expected: the loader/libstand seem to call devopen()->net_open(), devclose()->net_close() upon each file access, but it doesn't seem harmful, only additional output is seen in this case. Previously, due to this artificial increase of 'netdev_opens' counter, the devclose() method for network device was never called. Rafal