google-coral / edgetpu

Coral issue tracker (and legacy Edge TPU API source)
https://coral.ai
Apache License 2.0
422 stars 125 forks source link

Installation for M.2 Accelerator on RockPI 4 fails ..... #493

Open ghost opened 2 years ago

ghost commented 2 years ago

Description

Hello,

I have (as also under the RaspBerry) problems with the installation of the drivers /software and would be very pleased if I am helped here. I have proceeded according to your installation instructions:

                           https://coral.ai/docs/m2/get-started/

and up to this step 6 everything worked fine, also verify that the PCIe driver is loaded.

Here I get a message from the system that "NO" device or file is present.

Under "lspci -v" I get the following message:

01:00.0 System peripheral: Global Unichip Corp. Coral Edge TPU (prog-if ff) Subsystem: Global Unichip Corp. Coral Edge TPU

Under the command "lspci -vv | grep -i MSI-X" I get the following displayed:

    Capabilities: [b0] MSI-X: Enable- Count=1 Masked+.
    Capabilities: [d0] MSI-X: Enable- Count=128 Masked-.

Here is another output from: lspci -nn | grep 089a 01:00.0 System peripheral [0880]: Global Unichip Corp. Coral Edge TPU [1ac1:089a]

This is an ARM64 - Debian system. It would be very helpful if I could get some help here, because I would very much like to start using my investment. Best regards

Z. Matthias

Click to expand! ### Issue Type Build/Install ### Operating System Linux ### Coral Device M.2 Accelerator B+M ### Other Devices _No response_ ### Programming Language Other ### Relevant Log Output _No response_
dominch commented 2 years ago

Were there any installation errors? Is DKMS module loaded into kernel? what is output of: sudo modprobe apex sudo modprobe gasket

manoj7410 commented 2 years ago

@Zhexue-M Please share the output of:

ghost commented 2 years ago

modprobe apex brings: modprobe: FATAL: Module apex not found in directory /lib/modules/5.10.63-rockchip64 modprobe gasket brings: modprobe: FATAL: Module gasket not found in directory /lib/modules/5.10.63-rockchip64

modinfo gasket brings: modinfo: ERROR: Module gasket not found. modinfo apex brings: modinfo: ERROR: Module apex not found.

dominch commented 2 years ago

@Zhexue-M did that line returned errors? apt-get install gasket-dkms

Can You please share uname -a too?

ghost commented 2 years ago

If in type "apt install gasket-dkms", I´ve got the following information back:

Reading package lists... Done Building dependency tree... Done Reading state information... Done gasket-dkms is already the newest version (1.0-17). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

By "uname -a" it comes out:

Linux 5.10.63-rockchip64 #21.08.2 SMP PREEMPT Wed Sep 8 10:57:23 UTC 2021 aarch64 GNU/Linux

dominch commented 2 years ago

It seems that DKMS module is not installed, is that Armbian? Have You installed kernel headers modules? try apt update && apt upgrade -y && apt install -y linux-headers-current-rockchip64 Then apt-get --reinstall install gasket-dkms and past here dkms build log.

ghost commented 2 years ago

I had do that an now, I´ve got an Error - Message: Error! Bad return status for module build on kernel: 5.10.63-rockchip64 (aarch64) Consult /var/lib/dkms/gasket/1.0/build/make.log for more information. dpkg: error processing package gasket-dkms (--configure): installed gasket-dkms package post-installation script subprocess returned error exit status 10 Errors were encountered while processing: gasket-dkms E: Sub-process /usr/bin/dpkg returned an error code (1)

On LOG-File: DKMS make.log for gasket-1.0 for kernel 5.10.63-rockchip64 (aarch64) Thu Oct 21 10:24:37 AM UTC 2021 make: Entering directory '/usr/src/linux-headers-5.10.63-rockchip64' Makefile:682: arch//Makefile: No such file or directory make: *** No rule to make target 'arch//Makefile'. Stop. make: Leaving directory '/usr/src/linux-headers-5.10.63-rockchip64'

dominch commented 2 years ago

try as root: cd /usr/src/linux-headers-$(uname -r) make scripts then reinstall dkms module again