From owner-svn-src-all@FreeBSD.ORG Wed Sep 15 15:04:18 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 52D5A1065674; Wed, 15 Sep 2010 15:04:18 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id 93CE48FC08; Wed, 15 Sep 2010 15:04:17 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id o8FF4DMW046293 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 15 Sep 2010 18:04:13 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id o8FF4CDo012902; Wed, 15 Sep 2010 18:04:12 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id o8FF4CXY012901; Wed, 15 Sep 2010 18:04:12 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Wed, 15 Sep 2010 18:04:12 +0300 From: Kostik Belousov To: Attilio Rao Message-ID: <20100915150412.GM2465@deviant.kiev.zoral.com.ua> References: <201009151424.o8FEOLZE039185@svn.freebsd.org> <20100915145209.GK2465@deviant.kiev.zoral.com.ua> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="tI9tJD/InAKWF1Ci" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-2.5 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_20, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r212661 - head/sys/dev/aac X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Sep 2010 15:04:18 -0000 --tI9tJD/InAKWF1Ci Content-Type: text/plain; charset=koi8-r Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Sep 15, 2010 at 04:57:15PM +0200, Attilio Rao wrote: > 2010/9/15 Kostik Belousov : > > On Wed, Sep 15, 2010 at 02:24:21PM +0000, Attilio Rao wrote: > >> Author: attilio > >> Date: Wed Sep 15 14:24:21 2010 > >> New Revision: 212661 > >> URL: http://svn.freebsd.org/changeset/base/212661 > >> > >> Log: > >> =9A Fix bogus busying mechanism from cdevsw callbacks: > >> =9A - D_TRACKCLOSE may be used there as d_close() are expected to matc= h up > >> =9A =9A d_open() calls > > VFS is not very good at properly calling VOP_CLOSE(). As example, prema= ture > > vnode reclaim due to devfs unmount would cause VOP_CLOSE() to be called > > only once despite the number of opens being =9A> 1. >=20 > Yes. > That makes implementing a similar semantic in drivers very difficult > and not very well fixable, in particular within the d_* callbacks. > I'm seriously wondering if we might just make a shortcut just for > supporting such a feature (busying the device on real devfs entry > activity) as several of them may be needing and may be probabilly > needing to be 100%. > Luckilly, it seems that such paths are not experienced very frequently. I am not sure what do you mean by "busying the device on real devfs entry activity". Is the operation made by dev_refthread() and friends enough ? Device cannot be destroyed by destroy_dev() until all threads leave the cdevsw methods. --tI9tJD/InAKWF1Ci Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (FreeBSD) iEYEARECAAYFAkyQ4GwACgkQC3+MBN1Mb4hezwCgkXk6Fq5UUL8fgIO6Y8a7Lv9a m4oAoOSJAfcrcTKBl70Xjuzz1TYYVORC =a12E -----END PGP SIGNATURE----- --tI9tJD/InAKWF1Ci--