From owner-freebsd-geom@FreeBSD.ORG Thu Apr 7 14:46:58 2011 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D9351106564A for ; Thu, 7 Apr 2011 14:46:58 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 2D2668FC15 for ; Thu, 7 Apr 2011 14:46:57 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id RAA17888; Thu, 07 Apr 2011 17:46:54 +0300 (EEST) (envelope-from avg@FreeBSD.org) Message-ID: <4D9DCE5D.7040607@FreeBSD.org> Date: Thu, 07 Apr 2011 17:46:53 +0300 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.15) Gecko/20110309 Lightning/1.0b2 Thunderbird/3.1.9 MIME-Version: 1.0 To: Poul-Henning Kamp References: <70252.1302171058@critter.freebsd.dk> In-Reply-To: <70252.1302171058@critter.freebsd.dk> X-Enigmail-Version: 1.1.2 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-geom@FreeBSD.org Subject: Re: geom and removable media X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 07 Apr 2011 14:46:58 -0000 on 07/04/2011 13:10 Poul-Henning Kamp said the following: > In message <4D9D7EEB.3080607@FreeBSD.org>, Andriy Gapon writes: > >> Which I >> don't think would a right thing in the current world order where /dev/cdX >> represents both the drive and its media. > > You can create the new /dev/cdX right away, so there is no real window of > inconsistency. Yes, true. But I am trying to see whether that would buy us much comparing to just doing spoil + re-taste dance. I.e. my main concern is that the other geoms do not have a stale view of the media. I am OK with leaving everything else as it is now, so that any requests could still go all the way down to hardware (and fail). To summarize: I am thinking about posting a spoil event when we detect that a drive has no media (e.g. via a SCSI sense code) and posting a a retaste event when we detect presence of new media (probably as a result of some request succeeding). -- Andriy Gapon