Date: Thu, 07 Apr 2011 12:07:55 +0300 From: Andriy Gapon <avg@FreeBSD.org> To: Poul-Henning Kamp <phk@phk.freebsd.dk> Cc: freebsd-geom@FreeBSD.org Subject: Re: geom and removable media Message-ID: <4D9D7EEB.3080607@FreeBSD.org> In-Reply-To: <54077.1302165674@critter.freebsd.dk> References: <54077.1302165674@critter.freebsd.dk>
next in thread | previous in thread | raw e-mail | index | archive | help
on 07/04/2011 11:41 Poul-Henning Kamp said the following: > In message <4D9D4B10.1080501@FreeBSD.org>, Andriy Gapon writes: >> on 07/04/2011 03:09 Poul-Henning Kamp said the following: >>> In message <4D9C7B52.5010207@FreeBSD.org>, Andriy Gapon writes: >>> >>>> Suppose we implemented a mechanism to detect removal or change of removable media >>>> (e.g. for optical discs in cd drives). How to signal media removal (or change)? >>>> Destroy the existing and create a new disk(9)? >>>> Or do some sort of geom spoil on it? >>> >>> Basically yes. >> >> Apologies, but yes to what? :) > > To Both :-) That's what I feared :-) > Look at g_wither_provider() as a starting point. I perceive the following problem with g_wither_provider: as I understand that call would lead to telling all consumers of a provider that they are orphaned now, and geom_dev rightfully destroys its cdev on such an event. So I see the following effect: remove a disk from a CD drive -> /dev/cdX disappears. Which I don't think would a right thing in the current world order where /dev/cdX represents both the drive and its media. -- Andriy Gapon
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4D9D7EEB.3080607>