# Baikal BE-M1000 ARM64 Cortex-A57 USB not working



## oleantus (Dec 12, 2020)

I have аn ITX mainboard with BE-M1000 SoC.
This is an eight-core ARM Cortex-A57 processor. I tried to install the FreeBSD on this mainboard. I used the FreeBSD-12.2-RELEASE-arm64-aarch64-memstick.img. An attempt to install from USB flash drive was unsuccessful. The system does not find the boot device. I decided to try the installation from the SATA disk. This attempt was more successful. The system boots and the installer starts. But the USB keyboard doesn't work. I guessed that the system does not recognize USB ports.

I got the .dts files for this mainboard from Linux SDK and put them in the /usr/src/sys/gnu/dts/arm64/baikal/ on the working FreeBSD (amd64) system. Then I converted bm-mitx.dts to .dtb format:

cd /usr/src
make builddtb FDT_DTS_FILE="/usr/src/sys/gnu/dts/arm64/baikal/bm-mitx.dts"

I copied the resulting file bm-mitx.dtb to the installation flash drive into the directory /boot/dtb/. And added the following lines to the /boot/loader.conf:

dtbfile_load="YES"
dtbfile_type="dtb"
dtbfile_name="bm-mitx.dtb"

I also allowed writing to the root partition. After that I tried to boot again. During the booting, I saw that the file bm-mitx.dtb is being loaded. But nothing has changed, the USB ports (USB keyboard) are not working.

Please help me to solve this problem. Or at least tell me where to look for a solution.

I have attached dmesg.boot and messages files. And also other files with information.

Sofware development Kit (SDK) for Linux:








						SDK-M-4.3
					

Baikal Electronics File Cloud - Just Imagine




					share.baikalelectronics.ru
				




Datasheet:


			https://www.baikalelectronics.ru/upload/iblock/5e0/BE_M1000-Preliminary-Datasheet-ENG.pdf


----------



## Phishfry (Dec 14, 2020)

That is an interesting board.
Looking at the dmesg output I don't see any USB controller listed.
These errors did stand out to me:
"Malformed 'clock-output-names' property"
It comes from this source code file:








						freebsd-src/clk.c at master · freebsd/freebsd-src
					

FreeBSD src tree (read-only mirror). Contribute to freebsd/freebsd-src development by creating an account on GitHub.




					github.com
				




So what I would do is fix this error and check to see if FreeBSD even has the driver needed for USB from this device.
The best way to dissect this would be to use a supported Linux and see what driver they are using for USB driver.


----------



## Phishfry (Dec 14, 2020)

The relevant USB entry is in bm-clocks.dtsi


```
usb_clk:usb_clk@1F04D074 {
            #clock-cells = <0>;
            compatible = "fixed-clock";
                        clock-names = "usbclk";
            clock-frequency = <500000000>;
                        clock-output-names = "usbclk";
```


----------



## Phishfry (Dec 14, 2020)

The best place to ask questions for this is on IRC.
Specifically EFnet > bsdmips





__





						IRC/Channels - FreeBSD Wiki
					





					wiki.freebsd.org


----------



## oleantus (Dec 14, 2020)

Phishfry said:


> The best place to ask questions for this is on IRC.
> Specifically EFnet > bsdmips
> 
> 
> ...



Thanks for the advice, I will look for a solution.


----------

