From owner-freebsd-current@FreeBSD.ORG Fri Feb 13 03:31:35 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E0FF516A4CF for ; Fri, 13 Feb 2004 03:31:35 -0800 (PST) Received: from gvr.gvr.org (gvr-gw.gvr.org [80.126.103.228]) by mx1.FreeBSD.org (Postfix) with ESMTP id 72CEE43D2F for ; Fri, 13 Feb 2004 03:31:35 -0800 (PST) (envelope-from guido@gvr.org) Received: by gvr.gvr.org (Postfix, from userid 657) id C930C38; Fri, 13 Feb 2004 12:31:34 +0100 (CET) Date: Fri, 13 Feb 2004 12:31:34 +0100 From: Guido van Rooij To: current@freebsd.org Message-ID: <20040213113134.GA11021@gvr.gvr.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Subject: usb devices and devfs settings X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 Feb 2004 11:31:36 -0000 When I add usb devices after booting the system, the associated devices do show up in devfs. In my case: da0 and das0. However, the permissions on these devices does not change, despite devfs.conf. So how about adding the following to devd.conf in the default system: Note: the sleep 1 is necessary to give geom the chance to come up with devices before devd start executing /etc/rc.d/devfs -Guido --- /usr/src/etc/devd.conf Mon Jan 5 12:20:33 2004 +++ ./devd.conf Fri Feb 13 12:30:28 2004 @@ -24,6 +24,9 @@ set scsi-controller-regex "(adv|advw|aic|aha|ahb|ahc|ahd|bt|ct|iir|isp|mly|mpt|ncv|nsp|\ stg|sym|wds)[0-9]+"; + set usb-regex + "(uaudio|ubsa|ucom|udbp|ufm|uftdi|ugen|uhid|uhidev|ukbd|ulpt|\ + umass|umodem|ums|uplcom|urio|uscanner|uvisor|uvsco)[0-9]+"; }; # Note that the attach/detach with the highest value wins, so that one can @@ -127,3 +130,10 @@ action "/etc/acpi_ac $notify"; }; */ +# +# Set correct permissions for scsi and usb devs +# +attach 0 { + device-name "($usb-regex|$scsi-controller-regex)"; + action "sleep 1;/etc/rc.d/devfs start"; +};