Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

XDMA: missing 'System.map' file #52

Open
SamuelFarid opened this issue Mar 6, 2020 · 34 comments
Open

XDMA: missing 'System.map' file #52

SamuelFarid opened this issue Mar 6, 2020 · 34 comments

Comments

@SamuelFarid
Copy link

Hello!

I am trying to install the driver following the procedure in the readme file but I get the following output when running make install:

Makefile:10: XVC_FLAGS: .
make -C /lib/modules/5.3.0-40-generic/build M=/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma modules
make[1]: Entering directory '/usr/src/linux-headers-5.3.0-40-generic'
/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/Makefile:10: XVC_FLAGS: .
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/libxdma.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma_cdev.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_ctrl.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_events.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_sgdma.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_xvc.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_bypass.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma_mod.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma_thread.o
LD [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma.o
Building modules, stage 2.
/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/Makefile:10: XVC_FLAGS: .
MODPOST 1 modules
CC /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma.mod.o
LD [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma.ko
make[1]: Leaving directory '/usr/src/linux-headers-5.3.0-40-generic'
make -C /lib/modules/5.3.0-40-generic/build M=/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma modules_install
make[1]: Entering directory '/usr/src/linux-headers-5.3.0-40-generic'
INSTALL /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma.ko
DEPMOD 5.3.0-40-generic
Warning: modules_install: missing 'System.map' file. Skipping depmod.
make[1]: Leaving directory '/usr/src/linux-headers-5.3.0-40-generic'

Is there any way to solve that issue? I have tried a lot of things but it doesn't work. I am running on Ubuntu 19.10

Thanks in advance!

@lesjokolat
Copy link

yes there is its a tweak to makefile

#44 (comment)

@SamuelFarid
Copy link
Author

Thanks for your reply, but I have done this and the output is still the same.

@lesjokolat
Copy link

copy the output after you did it if you could. Will allow me to compare.

@SamuelFarid
Copy link
Author

root@SEAS16012:/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma# make install
Makefile:10: XVC_FLAGS: .
make -C /lib/modules/5.3.0-40-generic/build M=/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma modules
make[1]: Entering directory '/usr/src/linux-headers-5.3.0-40-generic'
/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/Makefile:10: XVC_FLAGS: .
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/libxdma.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma_cdev.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_ctrl.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_events.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_sgdma.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_xvc.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/cdev_bypass.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma_mod.o
CC [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma_thread.o
LD [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma.o
Building modules, stage 2.
/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/Makefile:10: XVC_FLAGS: .
MODPOST 1 modules
CC /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma.mod.o
LD [M] /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma.ko
make[1]: Leaving directory '/usr/src/linux-headers-5.3.0-40-generic'
make -C /lib/modules/5.3.0-40-generic/build M=/home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma modules_install
make[1]: Entering directory '/usr/src/linux-headers-5.3.0-40-generic'
INSTALL /home/samuel/dma_ip_drivers/XDMA/linux-kernel/xdma/xdma.ko
DEPMOD 5.3.0-40-generic
Warning: modules_install: missing 'System.map' file. Skipping depmod.
make[1]: Leaving directory '/usr/src/linux-headers-5.3.0-40-generic'
depmod -a

@lesjokolat
Copy link

can you add the makefile you adjusted?

@SamuelFarid
Copy link
Author

SHELL = /bin/bash
ifneq ($(xvc_bar_num),)
XVC_FLAGS += -D__XVC_BAR_NUM__=$(xvc_bar_num)
endif

ifneq ($(xvc_bar_offset),)
XVC_FLAGS += -D__XVC_BAR_OFFSET__=$(xvc_bar_offset)
endif

$(warning XVC_FLAGS: $(XVC_FLAGS).)

topdir := $(shell cd $(src)/.. && pwd)

TARGET_MODULE:=xdma

EXTRA_CFLAGS := -I$(topdir)/include $(XVC_FLAGS)
#EXTRA_CFLAGS += -D__LIBXDMA_DEBUG__
#EXTRA_CFLAGS += -DINTERNAL_TESTING

ifneq ($(KERNELRELEASE),)
$(TARGET_MODULE)-objs := libxdma.o xdma_cdev.o cdev_ctrl.o cdev_events.o cdev_sgdma.o cdev_xvc.o cdev_bypass.o xdma_mod.o xdma_thread.o
obj-m := $(TARGET_MODULE).o
else
BUILDSYSTEM_DIR:=/lib/modules/$(shell uname -r)/build
PWD:=$(shell pwd)
all :
$(MAKE) -C $(BUILDSYSTEM_DIR) M=$(PWD) modules

install: all
$(MAKE) -C $(BUILDSYSTEM_DIR) M=$(PWD) modules_install
depmod -a
clean:
$(MAKE) -C $(BUILDSYSTEM_DIR) M=$(PWD) clean

endif

@lesjokolat
Copy link

looks ok, I see you are root the only diff I can see is a run my command "su make install" Maybe a weird issue with how root is defined. My kernel example was a bit different as well.

its also odd you didnt get any SSL errors. Typically i was getting them as well at this point. Cna you try install from a non root account then SU command when make?

@SamuelFarid
Copy link
Author

I still got the same output. I have solved the ssl errors using this method.
May I know what OS and kernel version you are running?

@lesjokolat
Copy link

sure ubuntu 18.04.2
kernel
5.3.0-26

@SamuelFarid
Copy link
Author

Have you fixed the ssl error using the same method I have used? Is there anything else you have modified to solve the system.map missing file error?

@lesjokolat
Copy link

you know what I just realized it may have installed ok its just a warning message. try the 2 xmod checks after install to see if its found and installed.

@SamuelFarid
Copy link
Author

I have already done this but it fails to identify DMA. In your case the make install didn't give system.map file issue?

@lesjokolat
Copy link

correct I get message but this is a warning that allow install to continue.

When i run my xmod checks after I see driver is installed

@lesjokolat
Copy link

ok then I have also seen where you then need to go into test folder and run load driver script. then check xmod

@SamuelFarid
Copy link
Author

I have tried loading driver but it fails. This is the script output:

Loading xdma driver...insmod: ERROR: could not insert module ../xdma/xdma.ko: Operation not permitted
Error: Kernel module did not load properly.
FAILED

@lesjokolat
Copy link

insmod seems like the polling method is tripping up. i did not change polling method when I installed mine.

To check if driver is ok i run one of these 2

  • Check driver Version number
    modinfo xdma (or)
    modinfo ../xdma/xdma.ko

Then run lspci

@SamuelFarid
Copy link
Author

modinfo xdma (or) fails to run and its output:
bash: syntax error near unexpected token `('
And modinfo ../xdma/xdma.ko output:
filename: /home/samuel/dma_ip_drivers/XDMA/linux-kernel/tests/../xdma/xdma.ko
license: Dual BSD/GPL
version: 2019.2.51
description: Xilinx XDMA Reference Driver
author: Xilinx, Inc.
srcversion: FE994E934AE7021CE74856F
alias: pci:v000010EEd00002808svsdbcsci*
alias: pci:v000010EEd00004B28svsdbcsci*
alias: pci:v000010EEd00004A28svsdbcsci*
alias: pci:v000010EEd00004908svsdbcsci*
alias: pci:v000010EEd00004828svsdbcsci*
alias: pci:v000010EEd00004808svsdbcsci*
alias: pci:v000010EEd00006D30svsdbcsci*
alias: pci:v000010EEd00006A30svsdbcsci*
alias: pci:v000010EEd00006A28svsdbcsci*
alias: pci:v000010EEd00006930svsdbcsci*
alias: pci:v000010EEd00006928svsdbcsci*
alias: pci:v000010EEd00006830svsdbcsci*
alias: pci:v000010EEd00006828svsdbcsci*
alias: pci:v000010EEd00007038svsdbcsci*
alias: pci:v000010EEd00007034svsdbcsci*
alias: pci:v000010EEd00007032svsdbcsci*
alias: pci:v000010EEd00007031svsdbcsci*
alias: pci:v000010EEd00007028svsdbcsci*
alias: pci:v000010EEd00007024svsdbcsci*
alias: pci:v000010EEd00007022svsdbcsci*
alias: pci:v000010EEd00007021svsdbcsci*
alias: pci:v000010EEd00007018svsdbcsci*
alias: pci:v000010EEd00007014svsdbcsci*
alias: pci:v000010EEd00007012svsdbcsci*
alias: pci:v000010EEd00007011svsdbcsci*
alias: pci:v000010EEd00008038svsdbcsci*
alias: pci:v000010EEd00008034svsdbcsci*
alias: pci:v000010EEd00008032svsdbcsci*
alias: pci:v000010EEd00008031svsdbcsci*
alias: pci:v000010EEd00008028svsdbcsci*
alias: pci:v000010EEd00008024svsdbcsci*
alias: pci:v000010EEd00008022svsdbcsci*
alias: pci:v000010EEd00008021svsdbcsci*
alias: pci:v000010EEd00008018svsdbcsci*
alias: pci:v000010EEd00008014svsdbcsci*
alias: pci:v000010EEd00008012svsdbcsci*
alias: pci:v000010EEd00008011svsdbcsci*
alias: pci:v000010EEd00009011svsdbcsci*
alias: pci:v000010EEd00009021svsdbcsci*
alias: pci:v000010EEd00009031svsdbcsci*
alias: pci:v000010EEd00009012svsdbcsci*
alias: pci:v000010EEd00009022svsdbcsci*
alias: pci:v000010EEd00009032svsdbcsci*
alias: pci:v000010EEd00009014svsdbcsci*
alias: pci:v000010EEd00009024svsdbcsci*
alias: pci:v000010EEd00009034svsdbcsci*
alias: pci:v000010EEd00009018svsdbcsci*
alias: pci:v000010EEd00009028svsdbcsci*
alias: pci:v000010EEd00009038svsdbcsci*
alias: pci:v000010EEd0000903Fsvsdbcsci*
depends:
retpoline: Y
name: xdma
vermagic: 5.3.0-29-generic SMP mod_unload
parm: sgdma_timeout:timeout in seconds for sgdma, default is 10 sec. (uint)
parm: poll_mode:Set 1 for hw polling, default is 0 (interrupts) (uint)
parm: interrupt_mode:0 - MSI-x , 1 - MSI, 2 - Legacy (uint)
parm: enable_credit_mp:Set 0 to disable credit feature, default is 1 ( credit control enabled) (uint)
parm: desc_blen_max:per descriptor max. buffer length, default is (1 << 28) - 1 (uint)

I am able to see the pci device from lspci:
01:00.0 Memory controller: Xilinx Corporation Device 903f

@lesjokolat
Copy link

what linux environement are you runing?

could it be a csh vs bash setting?

@SamuelFarid
Copy link
Author

It’s ubuntu 19 using bash.

@lesjokolat
Copy link

yah that is only caveat I would worry about v19

modinfo xdma (or) fails to run and its output:
bash: syntax error near unexpected token `('

have you tried the older xdma archive 2018.3? maybe that will work?

@lesjokolat
Copy link

I am avoiding anything newer than 18.04.2 as Vivado itself doesn't support it. Otherwise you fall under excuse not a supported OS. Imagine the Vivado XDMA IPs you design they require compatibility and as such may not work.

@SamuelFarid
Copy link
Author

I have tried to use csh instead but the modinfo xdma (or) fails to run also. The older xdma archive fails during the make process. I think I will try to run Ubuntu 18.04 on virtualbox and check. Moreover, I have also tried the windows approach before and the drivers didn't work.

@SamuelFarid
Copy link
Author

I have install Ubuntu 18.04 instead and still the same error exists. Are you using dual boot? When I ran Ubuntu on virtualbox I was able to install the drivers but the virtualmachine itself wasn't able to detect the pci device, that's very weird.

@lesjokolat
Copy link

lesjokolat commented Mar 10, 2020

no my install is a native local host install.

which 18.04 version?

@SamuelFarid
Copy link
Author

Latest kernel version.

@SamuelFarid
Copy link
Author

SamuelFarid commented Mar 10, 2020

UPDATE: The driver is finally loaded successfully, the solution was to disable the secure boot.
The problem now is that load_driver cannot recognize any device despite the fact that the device is listed in lspci results:
01:00.0 Memory controller: Xilinx Corporation Device 903f

@lesjokolat
Copy link

if you want to try and use load driver script from the older 65444 driver set. It should make the device viewable

@Mahone-h
Copy link

UPDATE: The driver is finally loaded successfully, the solution was to disable the secure boot.
The problem now is that load_driver cannot recognize any device despite the fact that the device is listed in lspci results:
01:00.0 Memory controller: Xilinx Corporation Device 903f

Error: The Kernel module installed correctly, but no devices were recognized.
Have you solved this problem?

@lesjokolat
Copy link

I find if i get this error after teh install try to do this.
Launch vivado
re laod bitstream
then reboot

on startup if all goes well try to load driver and see if it helps

@Mahone-h
Copy link

I find if i get this error after teh install try to do this.
Launch vivado
re laod bitstream
then reboot

on startup if all goes well try to load driver and see if it helps

Ok, thank you. I have solved this problem. I used MSI interrupt and need to modify libxdma.c.
static unsigned int interrupt_ mode=1.

@BrianHuang85
Copy link

I am still getting the 'Warning: modules_install: missing 'System.map' file. Skipping depmod.' message even after the tweak in the Makefile #44 and the fix for the #39 SSL issue and secure boot in #52. The XDMA was not installed when I check with modinfo and lsmod commands.

setup as follow:
XDMA v2020.1.8
Ubuntu 18.04.5 LTS
Linux version 5.4.0-59

@lesjokolat
Copy link

Did you make clean , then install driver?
Also sometimes after you install go to test folder and run load driver script then check depmod

@BrianHuang85
Copy link

Did you make clean , then install driver?
Also sometimes after you install go to test folder and run load driver script then check depmod

Thank you. I forgot to make clean before make install.
Still getting the same warning message but the mod is successfully being installed.
problem solved.

@sujathabanoth-xlnx sujathabanoth-xlnx changed the title missing 'System.map' file XDMA: missing 'System.map' file Jan 29, 2021
@hmaarrfk
Copy link

Hello,

My name is Mark Harfouche. I am not affiliated with Xilinx in any way. Over the
years of using QDMA, I've been wanted better community organization.

I've created a fork of dma_ip_drivers which I intend to maintain and work with the
community at large to improve.

The fork can be found https://github.com/hmaarrfk/dma_ip_drivers

For now, I am stating the main goals of the repository in
hmaarrfk#2

If you are interested in working together, feel free to open an issue or PR to
my fork.

Best,

Mark

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants