From owner-freebsd-arch@FreeBSD.ORG Tue Jan 15 09:29:50 2008 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9F3F716A418; Tue, 15 Jan 2008 09:29:50 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from falcon.cybervisiontech.com (falcon.cybervisiontech.com [217.20.163.9]) by mx1.freebsd.org (Postfix) with ESMTP id 97D5A13C457; Tue, 15 Jan 2008 09:29:49 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from localhost (localhost [127.0.0.1]) by falcon.cybervisiontech.com (Postfix) with ESMTP id B7DEA43C03A; Tue, 15 Jan 2008 11:29:47 +0200 (EET) X-Virus-Scanned: Debian amavisd-new at falcon.cybervisiontech.com Received: from falcon.cybervisiontech.com ([127.0.0.1]) by localhost (falcon.cybervisiontech.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id B31Jv8WjXobZ; Tue, 15 Jan 2008 11:29:47 +0200 (EET) Received: from [10.2.1.87] (gateway.cybervisiontech.com.ua [88.81.251.18]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by falcon.cybervisiontech.com (Postfix) with ESMTP id E685743C031; Tue, 15 Jan 2008 11:29:46 +0200 (EET) Message-ID: <478C7D09.5050402@icyb.net.ua> Date: Tue, 15 Jan 2008 11:29:45 +0200 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.9 (X11/20071116) MIME-Version: 1.0 To: Kris Kennaway References: <478B3EE0.8040908@icyb.net.ua> <7iir1wtp91.wl%gnn@neville-neil.com> <20080114160617.GN99258@elvis.mu.org> <478B953F.1070209@icyb.net.ua> <20080114170624.GR99258@elvis.mu.org> <478B9A2C.4080206@icyb.net.ua> <20080114213347.GU99258@elvis.mu.org> <478BD6DE.1070407@FreeBSD.org> In-Reply-To: <478BD6DE.1070407@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: gnn@FreeBSD.org, Alfred Perlstein , freebsd-arch@FreeBSD.org Subject: Re: cdcontrol purpose X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 15 Jan 2008 09:29:50 -0000 on 14/01/2008 23:40 Kris Kennaway said the following: > Alfred Perlstein wrote: >> * Andriy Gapon [080114 09:18] wrote: >>> on 14/01/2008 19:06 Alfred Perlstein said the following: >>>> * Andriy Gapon [080114 08:57] wrote: >>>>> So I hope my question would be clearer now: should cdcontrol be allowed >>>>> to override "prevent" issued by mount/open(2) and eject a disk in use ? >>>>> Or should it simply fail in the same way that the physical button is >>>>> disabled? >>>> It should not. >>> Sorry, I am not completely sure which question you answered with that, >>> damn alternative questions :-) >>> >> Regarding: >> >>>>> should cdcontrol be allowed >>>>> to override "prevent" issued by mount/open(2) and eject a disk in use ? >> It should not do this. It should NOT eject a disk in use. >> >> Furthermore: >> >>>> If in that situation the tool does not emit a diagnostic that's >>>> useful then it could be augmented to do so. >> >> > > When I tried this last it indeed did not eject a mounted CDROM. I > wonder if Andriy's hardware is not responding to the "lock media" > command or something. Can anyone else confirm this behaviour? Kris, as I reported in this posting: http://docs.freebsd.org/cgi/getmsg.cgi?fetch=457200+0+archive/2007/freebsd-stable/20071223.freebsd-stable the behavior differs for SCSI and ATAPI devices, with the latter some checks within the driver forbid 'eject' command, but do not forbid 'allow'. So, while you can not eject a disk with cdcontrol alone, drive's tray becomes unlocked and now you can do it with a physical button. This is even weirder behavior than what happens with SCSI. -- Andriy Gapon