From owner-freebsd-hackers@FreeBSD.ORG Tue Aug 14 14:14:18 2007 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 26CA516A421 for ; Tue, 14 Aug 2007 14:14:18 +0000 (UTC) (envelope-from sven-freebsd@hazejager.nl) Received: from chainsoftware.nl (hazejager.demon.nl [83.160.136.100]) by mx1.freebsd.org (Postfix) with ESMTP id B54FC13C4A3 for ; Tue, 14 Aug 2007 14:14:17 +0000 (UTC) (envelope-from sven-freebsd@hazejager.nl) Received: from chainsoftware.nl (localhost [127.0.0.1]) by chainsoftware.nl (8.13.8/8.13.8) with ESMTP id l7EEE7Mm036276; Tue, 14 Aug 2007 16:14:07 +0200 (CEST) (envelope-from sven-freebsd@hazejager.nl) Received: from localhost (sven@localhost) by chainsoftware.nl (8.13.8/8.13.8/Submit) with ESMTP id l7EEE6oi036273; Tue, 14 Aug 2007 16:14:07 +0200 (CEST) (envelope-from sven-freebsd@hazejager.nl) X-Authentication-Warning: proxy.chain.loc: sven owned process doing -bs Date: Tue, 14 Aug 2007 16:14:06 +0200 (CEST) From: Sven Hazejager To: soralx@cydem.org In-Reply-To: <20070814041736.4c16f41e@soralx> Message-ID: <07081416114656.-1077948560@somehost.domainz.com> References: <07081411265549.-1077952816@somehost.domainz.com> <20070814030833.49a7a030@soralx> <20070814041736.4c16f41e@soralx> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Spam-Status: No, hits=-3.977 tests=ALL_TRUSTED,BAYES_00 X-Scanned-By: MIMEDefang 2.56 on 192.168.0.1 Cc: freebsd-hackers@freebsd.org Subject: Re: How to stop attached USB device / send IRP_MN_REMOVE_DEVICE? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Aug 2007 14:14:18 -0000 >>> So, the question really is: how to send a IRP_MN_REMOVE_DEVICE >>> command? >> >> `camcontrol da? stop` seemed to do the trick before (5.2.1-R, AFAIR), >> but now I'm not sure (looks like it doesn't) > > sorry, I meant to say that `camcontrol da? stop` does not power down > the device anymore; nonetheless, it is probably safe to disconnect it No, camcontrol does not support this over USB. Windows XP demonstrates it is technically possible, and I do not believe it is fully safe to disconnect the drive (even when unmounted), as the drive then is not able to park its heads, which it DOES do under XP. So, we come back to the original question: how to send an IRP_MN_REMOVE_DEVICE event? Regards, Sven