KVM no longer works in BIOS

Have been using Comet Pro for couple of months without issue but suddenly it has stopped responding in BIOS (still works within OS')

Dual boot between CachyOS and Windows and have been able to select the desired OS in Limine during the countdown window, but now it will not accept any inputs from mouse or keyboard. Sending command to boot directly into BIOS from CachyOS to select boot option from BIOS interface does not work as it does not recognize inputs there either, and I'm forced to use physically connected mouse and keyboard (defeating purpose of headless fully remote device).

Have attempted disconnecting and reconnecting several times are well as trying different USB ports and disconnecting other devices and nothing works. Also updated firmware to 1.10.1 and selected different options in Device Identity with no luck. Any assistance would be very much appreciated. Thanks.

Hi, maybe related? [WORKAROUND INCLUDED] Keyboard does not work in BIOS/BitLocker

To implement that workaround, is it a matter of accessing the Comet's Terminal and creating that script at /etc/kvmd/user/scripts/?

Used Gemini to get these instructions to apply that workaround but no luck :frowning:

  1. Remount the file system as writable:

    Bash

    mount -o remount,rw /
    
    
  2. Create the script directory and file:

    Bash

    mkdir -p /etc/kvmd/user/scripts
    nano /etc/kvmd/user/scripts/usb-class-fix
    
    
  3. Paste the script content:

    Bash

    #!/bin/sh
    case "$1" in
    start)
        (
        G=/sys/kernel/config/usb_gadget/rockchip
        for n in $(seq 1 120); do [ -n "$(cat $G/UDC 2>/dev/null)" ] && break; sleep 1; done
        UDC=$(cat $G/UDC 2>/dev/null)
        [ -n "$UDC" ] || exit 0
        [ "$(cat $G/bDeviceClass)" = "0x00" ] && exit 0
        echo "" > $G/UDC
        echo 0 > $G/bDeviceClass
        echo 0 > $G/bDeviceSubClass
        echo 0 > $G/bDeviceProtocol
        echo "$UDC" > $G/UDC
        logger -t usb-class-fix "bDeviceClass set to 0 on $UDC"
        ) </dev/null >/dev/null 2>&1 &
        ;;
    esac
    
    

    (Save and exit nano: press Ctrl+O, Enter, then Ctrl+X).

  4. Make the script executable:

    Bash

    chmod +x /etc/kvmd/user/scripts/usb-class-fix
    
    
  5. Register the execution hook in your override configuration: Open the override YAML file:

    Bash

    nano /etc/kvmd/override.yaml
    
    

    Add the hook configuration block to the file:

    YAML

    kvmd:
      hooks:
        usb_class_fix:
          run: /etc/kvmd/user/scripts/usb-class-fix start
    
    

    (Save and exit nano: press Ctrl+O, Enter, then Ctrl+X).

  6. Reboot the device:

    Bash

    reboot
    
    

@_eli I only have the PoE model, not Pro, so there might be some differences, but given that the firmware is identical, it should work. Here are some observations:

  1. Wrong filename (why it does nothing). GL's /etc/init.d/S99custom only runs files in that folder that match S??*, meaning a name starting with S and two characters (normally digits). usb-class-fix doesn't match, so it never runs at boot. It needs a name like S90usb-class-fix.sh.

  2. The override.yaml "hooks" block isn't a real kvmd setting. kvmd has no kvmd: hooks: option, so that block does nothing, and kvmd may refuse to start because of the unknown key. You should remove it.

  3. Remounting as writable isn't needed. On my device /etc was writable as-is, and I never remounted. It's harmless, though.

Corrected steps:

mkdir -p /etc/kvmd/user/scripts
mv /etc/kvmd/user/scripts/usb-class-fix /etc/kvmd/user/scripts/S90usb-class-fix.sh
chmod +x /etc/kvmd/user/scripts/S90usb-class-fix.sh
# then remove the "hooks:" block they added to /etc/kvmd/override.yaml
reboot

To check after the reboot:

cat /sys/kernel/config/usb_gadget/rockchip/bDeviceClass   # should print 0x00
logread | grep usb-class-fix                              # should show "bDeviceClass set to 0"

If it still shows 0xEF after the reboot, check that /etc/init.d/S99custom exists and that ls /sys/kernel/config/usb_gadget/ shows rockchip. I only verified this on my GL-RM1PE with firmware 1.10.0beta2, and other models or firmware versions may name things differently.

Thank you so much for assisting. I performed the following in this order:

  1. Removed the "hooks:" block added to /etc/kvmd/override.yaml

  2. Ran the three commands provided successfully:
    mkdir -p /etc/kvmd/user/scripts
    mv /etc/kvmd/user/scripts/usb-class-fix /etc/kvmd/user/scripts/S90usb-class-fix.sh
    chmod +x /etc/kvmd/user/scripts/S90usb-class-fix.sh

  3. Rebooted

Below are results of running final checks:

bash-5.2# cat /sys/kernel/config/usb_gadget/rockchip/bDeviceClass
0x00
bash-5.2# logread | grep usb-class-fix
Oct 21 18:47:20 glkvm user.notice usb-class-fix: bDeviceClass set to 0 on 21500000.usb
bash-5.2#

This however actually made the KVM stop working entirely on the OS. I manually forced shut down the PC by holding the power button and after turning on it did not work on Limine bootloader and when it got back to CachyOS the mouse and keyboard is not working at all :frowning:

EDIT: Disconnecting and reconnecting USB cable made the Comet Pro reboot on its own. When back in OS I disconnected and reconnected again. I rebooted the PC and still not working in bootloader, but it is at least working again in OS

Hi, please try this firmware.

I have a mainland China RM10. Can I use this firmware?

Yes, you can use.

Flashed firmware, still not working in bootloader/bios, only in OS :confused:

@_eli depending on how technical you are, you should be able to debug this issue by spinning up an AI agent and giving it SSH access to your RM10. It's ordinary Linux underneath, so the agent should be able to navigate and experiment by changing all properties of the USB device until something works.

My preference is that GLiNet finds a permanent fix as access so Bios is core feature and selling point of these devices. I travel for work and have come to depend on this feature to access and manage home PC/server :frowning:

@_eli I'm sure they're trying their best, but there's thousands of different devices with varying behaviors, it's impossible to test them all. If you can figure it out with AI and report it to them, I am sure they will make it a proper/permanent fix.

Which USB resources are currently enabled? Please test with only keyboard and mouse retained.

Did some more troubleshooting with Gemini and it advised to unplug PC and hold down power button for 30 seconds and this actually worked. Do not want to mark issue as resolved in the event it occurs again over the next couple of days and will update accordingly.