2

I have 534d:6021 MacroSilicon VGA Display Adapter which I want to connect my third screen through my usb 3 port. However it has only windows drivers. How can I setup this adapter with a suitable driver on my ubuntu 22.04.

USB 534d:6021 »
/ 03-00-00  MacroSilicon    VGA Display Adapter cdrom   uas, usb_storage    detected 

this is the output of hw-probe.

tealy
  • 99

2 Answers2

2

(I don't own the hardware so not completely tested)

  1. Update to the latest Ubuntu 22.04.3 (you should be running 6.2 kernel)
  2. Run these commands:
cd Downloads
wget https://github.com/nunesbns/ms912x/archive/refs/heads/kernel-6-support.zip
unzip kernel-6-support.zip
cd ms912x-kernel-6-support/
sudo apt install -y build-essential
make clean
make all -j
sudo modprobe drm_shmem_helper
sudo insmod ms912x.ko
journalctl -k | grep ms912x
# expected output:
# Oct 12 12:59:56 hp-laptop kernel: usbcore: registered new interface driver ms912x
  1. Test if your device works.
R A
  • 551
  • it resulteds in Skipping BTF generation for /home/c/Downloads/ms912x-kernel-6-support/ms912x.ko due to unavailability of vmlinux and then got fixed with https://askubuntu.com/questions/1348250/skipping-btf-generation-xxx-due-to-unavailability-of-vmlinux-on-ubuntu-21-04 – Max Oct 14 '23 at 08:17
  • make results in make[1]: *** /lib/modules/6.1.0-11-amd64/build: No such file or directory. Stop. After installing linux headers, it works with make CHECK="/usr/bin/sparse" -C /usr/src/linux-headers-6.1.0-11-amd64/ M=$PWD modules – Ale Oct 15 '23 at 17:00
  • This error is occurring: Fatal error: Invalid --compress-debug-sections option: 'zstd'. Any idea? – Eduardo Lucio Oct 17 '23 at 04:03
  • @Ale How were you able to use Kernel 6.1.0-11 if it doesn't have drm/drm_fbdev_generic.h? – Eduardo Lucio Oct 17 '23 at 04:21
  • @RA The device is recognized, but the screen is completely dark. If I restart OS, then the driver no longer works. I have to reinstall. Any ideas about what could be going on? – Eduardo Lucio Oct 18 '23 at 19:04
  • @EduardoLucio https://github.com/rhgndf/ms912x you can create an issue here and ask. On reboot sudo insmod ms912x.ko should be enough. Also, see if there's anything strange in your journal – R A Oct 18 '23 at 19:20
  • @RA insmod: ERROR: could not load module ms912x.ko: No such file or directory – Eduardo Lucio Oct 18 '23 at 23:55
  • @Eduardo Lucio Just comment out the line that includes it. Besides the link pointed by Max, also need sudo ln -n -s /boot/System.map-6.1.0-11-amd64 /usr/src/linux-headers-6.1.0-11-amd64/System.map and then make the modules_install target. The moduke ten loads automatically. Yet, xrandr won't see it. – Ale Oct 19 '23 at 06:08
  • @Ale I didn't quite understand what you explained... Anyway, the System.map file doesn't exist on my system. – Eduardo Lucio Oct 19 '23 at 13:45
  • I opened another topic to address issues about the ms912x driver - Device 534d:6021 (USB 3.0 to HDMI Adapter) - here: https://unix.stackexchange.com/q/759400/61742 . – Eduardo Lucio Oct 19 '23 at 23:56
0

Install MacroSilicon USB to HDMI Adapter driver (534d:6021)

Installation process

To install, run these commands...

git clone https://github.com/rhgndf/ms912x.git
cd "./ms912x"

These git commands allow you to clean up a previous installation and ensure you

have the latest version in case of reinstallations or tests.

git fetch --all git reset --hard origin/main git clean -fdx

make clean make all -j sudo rmmod ms912x # It will not work if the device is in use. sudo insmod ms912x.ko sudo modprobe drm_shmem_helper

IMPORTANT: Linux kernel 6.2.X (or above) is necessary, because of DRM support.

EXTRA: Necessary packages for Manjaro Linux yay -S linux65; yay -S linux65-headers; yay -S make; yay -S base-devel; yay -S binutils; yay -S libdrm; yay -S sparse; yay -S zstd. Ubuntu has equivalent packages (Kernel's ones, perhaps not).

... OR (simply)...

bash insmod.sh

Information about your device (or about problems with it)

Some commands to obtain information about your device (or about problems with it)...

lsusb -v
dmesg | grep -Ei "ms912x"
journalctl -k | grep -Ei "ms912x"
edid-decode < /sys/class/drm/<YOUR_DEVICE>/edid
cat /etc/X11/xorg.conf.d/10-prime-offload.conf

Results I got

On Linux, the performance is UNACCEPTABLE and there are also compatibility problems.

Other than that the device claims to be USB 3.0, but it's just USB 2.0 .

NOTE: It didn't work with the KDE gui using X11 (I had to use Wayland that is immature). The distribution tested was Manjaro KDE.

Conclusion

Unfortunately, MacroSilicon is not interested in Linux users (a shame, really ), nor does it support important and valuable open source projects like this one ms912x driver for Linux.

Therefore, at the moment, my guidance is that Linux users use devices based on DisplayLink chips (manufacturer Synaptics). I tested the WL-UG3501H device, for example, and had excellent results. The manufacturer Synaptics provides good support for Linux drivers.

EXTRA: To install drivers for devices based on DisplayLink chips (manufacturer Synaptics) on Manjaro Linux use the command yay -S displaylink. Ubuntu has an equivalent package.

PLUS: USB video card adapters for Linux Ubuntu .

Thanks!