FreeBSD: Fixing the stuck-on-reboot problem on the Dell Inspiron 7352 (and newer ThinkPads)

While the Dell Inspiron 7352 is not my primary FreeBSD laptop (that would be an HP EliteBook Folio 1040 G1 G3), the Inspiron is the laptop I use exclusively for schoolwork and my job at NYU CUSP. One issue this laptop has with FreeBSD is the fact that when I reboot, it reboots to a blank screen, stays there for a minute, and then shows the Dell logo and boots as normal.

It also turns out that a similar problem exists on newer ThinkPads such as the 4th and 5th generation X1 Carbon, and the T470s, except that unlike my Inspiron, the ThinkPads freeze on a Lenovo logo. While it's possible that ThinkPads may have a different issue, the issue could also be the same. I do not own a ThinkPad, so I cannot test for Lenovo-specific bugs.

So what's the issue?

While it may be easy to blame UEFI or ACPI, it's not a 100% UEFI issue. The culprit is actually the ng_ubt kernel module and newer Intel Wireless AC cards. It turns out that while the Bluetooth part of Intel AC cards don't work on FreeBSD, ng_ubt still gets loaded by devd and (I believe) it doesn't unload cleanly because of a lack of driver support. It could also be possible that the UEFI doesn't clean up after the OS.

So what you need to do is to modify devd in order to not load the ng_ubt kernel module. But first, you need to get the device IDs of the Bluetooth device. To do this, you need to look at /var/log/messages. To do so, grep the file for occurrences of ubt:

root@flex:~ # grep -R ubt /var/log/messages

And you will get messages like:

Apr 25 12:26:57 flex kernel: ubt0 on uhub0
Apr 25 12:26:57 flex kernel: ubt0: <vendor 0x8087 product 0x0a2a, class 224/1, rev 2.01/0.01, addr 3> on usbus0

With the hexadecimal vendor and product IDs, create a new file called /etc/devd/no_bluetooth.conf (or any .conf file in /etc/devd) with the following contents:

nomatch 50 {
    match "bus" "uhub[0-9]+";
    match "mode" "host";
    match "vendor" "VENDOR_ID";
    match "product" "PRODUCT_ID";
    #action "kldload -n ng_ubt";
    action "logger blocked bluetooth module";

Replace VENDOR_ID with your vendor ID (0x8087 for me) and PRODUCT_ID with your product ID (0x0a2a for me).

To test it, do a hard shutdown. Then turn it on, and reboot. If it doesn't get stuck, then the problem is with ng_ubt. It worked on the Dell Inspiron 7352, but it may not work on ThinkPads.

Update: Two ThinkPad T470s users on the linked bug report have also had success with my workaround. However, one user found that they should disable Bluetooth completely with this file as well. My workaround does not disable Bluetooth completely, but does so if the only Bluetooth adapter is an Intel device. I decided not to disable Bluetooth completely here incase someone wants to use a USB Bluetooth dongle and are okay with a (possible) reboot hitch once in a while.


If you don't use a USB Bluetooth dongle, you should be able to reboot correctly. However, if you use one, you may end up with a stuck-on-reboot as devd may load nt_ubt for the dongle and also load the Intel Bluetooth. I have not tested this scenario as I don't have a USB Bluetooth dongle with FreeBSD support.



UPDATE: I changed the title from FreeBSD: Fixing the stuck-on-reboot problem on the Dell Inspiron 7352 (and possibly newer ThinkPads) to FreeBSD: Fixing the stuck-on-reboot problem on the Dell Inspiron 7352 (and newer ThinkPads) because (as reported a while ago on FreeBSD Bugzilla) this solution (read: workaround) also works on Lenovo ThinkPads.

Show Comments