Bug 36154

Summary: [usb] Getting USB mouse to work: usbd and moused conflict
Product: Documentation Reporter: Ryan Kassel <ryankassel>
Component: Books & ArticlesAssignee: Simon L. B. Nielsen <simon>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   

Description Ryan Kassel 2002-03-21 03:50:00 UTC
      Upon adding a PCI USB card to my computer and connecting a USB mouse (and making all the necessary additions to the kernel and rc.conf and /dev) I found that I got the error at bootup in the rc.i386 initialization section:

moused: unable to open /dev/ums0: device busy

This is caused from moused being ran twice for the same device (ums0).

Fix: 

As per http://www.freebsd.org/doc/en_US.ISO8859-1/books/faq/hardware.html#USBMOUSE 
section 4 should have moused_enable="NO" since usbd should handle starting up moused (it does this automatically).  This way, you can hot-swap the USB device as well.
How-To-Repeat:       Install a USB mouse and follow the instructions at 
http://www.freebsd.org/doc/en_US.ISO8859-1/books/faq/hardware.html#USBMOUSE
Comment 1 iedowse freebsd_committer freebsd_triage 2002-12-08 18:02:40 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-doc


Documentation bug: faq/hardware.html should not suggest setting any 
moused_* variables for a USB mouse since moused is started automatically 
by usbd. Instead, use `allscreens_flags="-m on"' to enable the mouse 
cursor.
Comment 2 simon 2003-05-27 01:35:20 UTC
Perhaps a patch like this ?

Note:

* etc/usbd.conf was changed before 5.0 and 4.8, to enable mouse in the
  console after attaching. Relevant versions in CVS: 1.11 and 1.5.2.3.

* usbd_flags="" is the default and has been since v. 1.1 of
  etc/defaults/rc.conf.

%%%
Index: book.sgml
===================================================================
RCS file: /home/ncvs/doc/en_US.ISO8859-1/books/faq/book.sgml,v
retrieving revision 1.538
diff -u -d -u -r1.538 book.sgml
--- book.sgml	13 May 2003 19:15:26 -0000	1.538
+++ book.sgml	27 May 2003 00:22:18 -0000
@@ -2734,17 +2734,15 @@
 
             <step>
               <para>Edit <filename>/etc/rc.conf</filename> and add the
-                following lines:</para>
+                following line:</para>
 
-              <programlisting>moused_enable="YES"
-moused_type="auto"
-moused_port="/dev/ums0"
-moused_flags=""
-usbd_enable="YES"
-usbd_flags=""</programlisting>
+              <programlisting>usbd_enable="YES"</programlisting>
 
-              <para>See the <link linkend="moused">previous section</link>
-                for more detailed discussion on moused.</para>
+              <para>To enable the mouse in the console, in &os;
+                versions older than 4.8, add the following line to
+                <filename>/etc/rc.conf</filename>:</para>
+
+              <programlisting>allscreens_flags="-m on"</programlisting>
             </step>
 
             <step>
%%%

-- 
Simon L. Nielsen
No PGP in honor of GNATS.
Comment 3 Simon L. B. Nielsen freebsd_committer freebsd_triage 2003-10-18 21:53:00 UTC
Responsible Changed
From-To: freebsd-doc->simon

I'm looking into this one.
Comment 4 Simon L. B. Nielsen freebsd_committer freebsd_triage 2005-02-26 22:33:48 UTC
State Changed
From-To: open->closed

The FAQ entry is only applicable for FreeBSD 3.X.  For 4.X and newer 
USB mice should just work.  This was actually stated in the entry but 
it was easy to miss (I also missed it at first), so I removed the 
FAQ entry to avoid confusion. 

Thanks for the submission, and sorry about the waaaay to long 
processing time for this PR.