From owner-freebsd-usb@FreeBSD.ORG Thu Oct 25 03:27:30 2007 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BC72F16A420 for ; Thu, 25 Oct 2007 03:27:30 +0000 (UTC) (envelope-from drgerlists@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.242]) by mx1.freebsd.org (Postfix) with ESMTP id 6CCCA13C4B0 for ; Thu, 25 Oct 2007 03:27:30 +0000 (UTC) (envelope-from drgerlists@gmail.com) Received: by an-out-0708.google.com with SMTP id c24so75138ana for ; Wed, 24 Oct 2007 20:27:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:date:from:organization:reply-to:to:subject:cc:message-id:references:in-reply-to:user-agent:mime-version:content-type:content-transfer-encoding; bh=MCTfhzgKuhU3fOJ7SkLqCrQ6z0yghddmUCm87nRDIGE=; b=QAF08zUVPrZhY9MvrAL7Cdz0ob/pGMEhUP5jszIBQCiHm3pJYsQRgFrQYEJ7tt9kdWOSD8AaCFh8fQcEaHLZjixwFWv4TlHmia+LM4vYcQ3N9RA4fm+EtZp6ZrIQZ1zd/0bvLU4uJF9SHar30inEXd+yMDSRIPC4Hx4+PSioEEs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:date:from:organization:reply-to:to:subject:cc:message-id:references:in-reply-to:user-agent:mime-version:content-type:content-transfer-encoding; b=BgMjxVm9DpcDPBvSSgajcJRruS80inhhBSG+deZ3LlkX3ZwZxcSAE/4kuFOd0ieyghoOY7hwSoL/+kiq4MYoM1dBJSbyDb6vVI/1UX0XnN/0jVTBvp8VOh9MUMc+Mge4+7mEnC752e/qiGml9KZLVbMVoSun4TnRdTNhtszyH+U= Received: by 10.101.66.14 with SMTP id t14mr1694327ank.1193281122437; Wed, 24 Oct 2007 19:58:42 -0700 (PDT) Received: from lmrmac.uhw.utoledo.edu ( [131.183.86.111]) by mx.google.com with ESMTPS id 13sm140791wrl.2007.10.24.19.58.40 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 24 Oct 2007 19:58:40 -0700 (PDT) Date: Wed, 24 Oct 2007 22:58:39 -0400 From: drgerlists@gmail.com (Dr. Gary E. RAFE) Organization: Dr. Gary E. RAFE To: amdmi3@amdmi3.ru Message-ID: <4720065f.pXzyS31GREBN7Z4DD3SoGkw2@lmrmac.uhw.utoledo.edu> References: <20071025011507.GA15904@hades.panopticon> In-Reply-To: <20071025011507.GA15904@hades.panopticon> User-Agent: Heirloom mailx 12.3 7/15/07 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-usb@freebsd.org Subject: Re: how to distinguish multiple umass devices? X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: drgerlists@gmail.com List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Oct 2007 03:27:30 -0000 Dmitry Marakasov wrote: !I have multiple umass devices (flash key, player and photo camera), and !I want to distinguish their devices in some way. ! !The best thing would be to have /dev/flash, /dev/camera etc, as in this !case I'll distinguish thoughput graphs on GKrellM system monitor. But I !don't think it's possible, so I need a way to at least create !corresponding symlinks in /dev. As I understand, devd is my savior, but !there's one problem that bugs me: devd sees umass[012], but it doesn't !know anything about da[012]. Is there guarantee that umassX matches daX, !or is it possible to get da* device from devd on umass attach? HAL appears solve this, but I don't need the overhead of HAL, so I mediated the attach process with a script that is called from devd: attach 99 { device-name "umass[0-9]+"; action "/usr/opt/etc/rmediactl $device-name start"; }; You are welcome to have a look at this script for some ideas: Comments from the list are welcome. -- Dr Gary E RAFE: drgerlists at gmail dot com