Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 18 May 2024 07:06:26 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        Oleksandr Kryvulia <shuriku@shurik.kiev.ua>
Cc:        FreeBSD Current <freebsd-current@freebsd.org>
Subject:   Re: usb mouse not work on boot
Message-ID:  <CANCZdfpD5FeHbb2B-cMDjQesr9NS%2BUVBpzgLG%2Bg4GgSjkBxC3A@mail.gmail.com>
In-Reply-To: <34a397ef-ca2d-4e04-9066-3cf8a0c48616@shurik.kiev.ua>
References:  <ae973e80-7f06-432c-ab66-b1a2ab337eaa@shurik.kiev.ua> <20240518092649.6430ad53@ernst.home> <af05317d-8d64-4a25-b13d-785848c0d326@shurik.kiev.ua> <86ttivwikf.fsf@ltc.des.dev> <cae2b31c-68ed-46c9-9d7b-415926186766@shurik.kiev.ua> <34a397ef-ca2d-4e04-9066-3cf8a0c48616@shurik.kiev.ua>

index | next in thread | previous in thread | raw e-mail

[-- Attachment #1 --]
On Sat, May 18, 2024, 6:51 AM Oleksandr Kryvulia <shuriku@shurik.kiev.ua>
wrote:

> 18.05.24 12:59, Oleksandr Kryvulia:
>
> 18.05.24 12:55, Dag-Erling Smørgrav:
>
> Oleksandr Kryvulia <shuriku@shurik.kiev.ua> <shuriku@shurik.kiev.ua> writes:
>
> Gary Jennejohn <garyj@gmx.de> <garyj@gmx.de> writes:
>
> Try adding uhid_load="YES" to your /boot/loader.conf.  With that
> added the module should be automatically loaded during the kernel
> boot.
>
> As workaround I already have kld_list+="uhid" in /etc/rc.conf.
>
> I hope you don't mean that literally, because /etc/rc.conf is a shell
> script and += is not valid shell syntax.  On the other hand, something
> like
>
> kld_list="${kld_list} uhid"
>
> Yes, you are right. I mean
> sysrc kld_list+="uhid"
>
>
> One more correction. Via kld_list I need load ums(4), loading only uhid(4)
> does not solve a problem.
>


You don't need to change kld_list. In fact, you should undo any changes
you've made there. Undo everything in loader.conf you've done.

This is a bug in the boot optimization stuff. Or rather, this exposes a
long standing bug in the USB code where there's an asymmetry between the
nomatch events and the bus tree it presents to devctl causing devmatch to
fail when the nomatch events aren't present on boot.

Just set hw.bus.devctl_nomatch_enabled=1 in /boot/loader.conf and reboot.
Or update to the change I'm about to make.

Warner

[-- Attachment #2 --]
<div dir="ltr"><div dir="auto"><div><br><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, May 18, 2024, 6:51 AM Oleksandr Kryvulia &lt;<a href="mailto:shuriku@shurik.kiev.ua" target="_blank">shuriku@shurik.kiev.ua</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><u></u>

  
    
  
  <div>
    18.05.24 12:59, Oleksandr Kryvulia:<br>
    <blockquote type="cite">
      
      18.05.24 12:55, Dag-Erling Smørgrav:<br>
      <blockquote type="cite">
        <pre><pre>Oleksandr Kryvulia <a href="mailto:shuriku@shurik.kiev.ua" rel="noreferrer" target="_blank">&lt;shuriku@shurik.kiev.ua&gt;</a> writes:
</pre><blockquote type="cite" style="color:#007cff"><pre>Gary Jennejohn <a href="mailto:garyj@gmx.de" rel="noreferrer" target="_blank">&lt;garyj@gmx.de&gt;</a> writes:
</pre><blockquote type="cite" style="color:#007cff"><pre>Try adding uhid_load=&quot;YES&quot; to your /boot/loader.conf.  With that
added the module should be automatically loaded during the kernel
boot.
</pre></blockquote><pre>As workaround I already have kld_list+=&quot;uhid&quot; in /etc/rc.conf.
</pre></blockquote><pre>I hope you don&#39;t mean that literally, because /etc/rc.conf is a shell
script and += is not valid shell syntax.  On the other hand, something
like

kld_list=&quot;${kld_list} uhid&quot;</pre></pre>
      </blockquote>
      Yes, you are right. I mean<br>
      <span style="font-family:monospace"><span style="color:#000000;background-color:#ffffff">sysrc
          kld_list+=&quot;uhid&quot;</span></span></blockquote>
    <br>
    One more correction. Via kld_list I need load ums(4), loading only
    uhid(4) does not solve a problem.<br></div></blockquote></div></div><div dir="auto"><br></div></div><div><br></div><div>You don&#39;t need to change kld_list. In fact, you should undo any changes you&#39;ve made there. Undo everything in loader.conf you&#39;ve done.<br></div><div><br></div><div>This is a bug in the boot optimization stuff. Or rather, this exposes a long standing bug in the USB code where there&#39;s an asymmetry between the nomatch events and the bus tree it presents to devctl causing devmatch to fail when the nomatch events aren&#39;t present on boot.</div><div><br></div><div>Just set hw.bus.devctl_nomatch_enabled=1 in /boot/loader.conf and reboot. Or update to the change I&#39;m about to make.</div><div><br></div><div>Warner<br></div>
</div>
home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CANCZdfpD5FeHbb2B-cMDjQesr9NS%2BUVBpzgLG%2Bg4GgSjkBxC3A>