evdi: Fails to build on kernel 5.4

evdi 1.6.4 fails to build on kernel 5.4:

module/evdi_drv.h:23:10: fatal error: linux/reservation.h: No such file or directory

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 6
  • Comments: 66 (38 by maintainers)

Most upvoted comments

@d3rrial

Being bored here in hospital I’ve added install/uninstall & fixed versioning.

There an all-in-one patch, including the kernel 5.4 fixes: https://crazy.dev.frugalware.org/evdi-all-in-one-fixes.patch

The patch is against the latest git, but may work for 1.6.4. The following options to make have been added:

PREFIX defaults to /usr/local LIBDIR defaults to $PREFIX/lib DESTDIR defaults to nothing ( for packagers ) RUN_DEPMOD disabled by default RUN_DEPMOD=1 or =true will run depmod -a INSTALL defaults to install RM defaults to rm LN defaults to ln

HOWTO use:

  1. clone the git source git clone https://github.com/DisplayLink/evdi.git
  2. get the patch wget https://crazy.dev.frugalware.org/evdi-all-in-one-fixes.patch
  3. patch the source cd location_you_cloned_evdi patch -Np1 <full_path_to_the_patch
  4. run make
  5. sudo make PREFIX=/usr RUN_DEPMOD=1 install , to install system wide. if you want to test what is doing first do something like this: make PREFIX=/usr DESTDIR=$(pwd)/TEST_DIR install , and have a look into $PWD/TEST_DIR.

I hope that helps you and @thx1111 to test the patch.

@displaylink-dkurek

That patch nothing for you in this form, it contains like 4 PR’s, just a help for the users are willing to test around but have broken dkms for whatever reason.

Just jumping in here to say thanks to all who have contributed to this thread. I recently upgraded my Fedora 31 to kernel 5.5.11-200.fc31.x86_64, and once again, my DisplayLink driver (fedora-31-displaylink-1.6.4-1.x86_64.rpm) was failing to work. Searched high and low and finally came across the suggestions here in thread. In summary:

$ sudo dnf install displaylink-1.6.4-2.x86_64.rpm $ git clone https://github.com/DisplayLink/evdi.git $ cd evdi $ sudo dkms install ./module

“Magically” my monitors attached to my Dell D3100 dock came to life. Again, thanks to all!

P.S. I’m in no way bashing elguero and all who have contributed to https://github.com/elguero/displaylink-rpm.git. Huge thanks to everyone on that project who has even made the DisplayLink drivers availabe to us Fedora users. https://www.displaylink.com/downloads themselves won’t even support us!

Oh, ok! I’ve just run sudo dkms install ./module on the repo root and it seems like it’s installed! Indeed, the DisplayLink screen started to work immediately.

Thank you for your patience. I’m missing some instructions in order to build and install the module in the readme, that was all.

@matheo that error goes away when you add the M= parameter as https://github.com/DisplayLink/evdi/issues/172#issuecomment-561964789 suggests.

For the people like me who out of the loop a bit. What do I need to do to install on Kernel 5.4 the latest DisplayLink package downloaded from the DisplayLink website?

OK, so update for kernel 5.4, 5.5 and changes for DKMS build landed on devel. Hopefully I haven’t missed anything 😃

@displaylink-dkurek

no, feel free to use the patch.

( btw 5.5 need another round of fixes but is just a matter of includes soring and a small code fix )

Hi all, I’d like to know if it’s possible to build the module in 5.4.0-9-generic? I’m getting:

./displaylink-driver-5.2.14.run 
Verifying archive integrity...  100%   All good.
Uncompressing DisplayLink Linux Driver 5.2.14  100%  
DisplayLink Linux Software 5.2.14 install script called: install
Distribution discovered: Ubuntu Focal Fossa (development branch)
Installing
Configuring EVDI DKMS module
Registering EVDI kernel module with DKMS
Building EVDI kernel module with DKMS
ERROR (code 3): Failed to build evdi/5.2.14. Consult /var/lib/dkms/evdi/5.2.14/build/make.log for details..

where the error section is:

make -f ./scripts/Makefile.modbuiltin obj=drivers/acpi/apei
make -f ./scripts/Makefile.modbuiltin obj=drivers/acpi/dptf
make -C /usr/src/linux-headers-5.4.0-9-generic/tools/build CFLAGS= LDFLAGS= /usr/src/linux-headers-5.4.0-9-generic/tools/objtool/fixdep
(for m in ; do echo $m; done;   \
cat /dev/null samples/vfio-mdev/modules.builtin) > samples/modules.builtin
make -f ./scripts/Makefile.modbuiltin obj=drivers/acpi/hmat
(for m in ; do echo $m; done;   \
cat /dev/null ) > drivers/android/modules.builtin
(for m in ; do echo $m; done;   \
cat /dev/null ) > security/integrity/evm/modules.builtin
(for m in ; do echo $m; done;   \
cat /dev/null ) > fs/debugfs/modules.builtin
make -f ./scripts/Makefile.modbuiltin obj=crypto/asymmetric_keys
make -f ./scripts/Makefile.modbuiltin obj=arch/x86/entry
make -f ./scripts/Makefile.modbuiltin obj=drivers/auxdisplay
make -f ./scripts/Makefile.modbuiltin obj=fs/devpts
(for m in drivers/ata/libata.ko drivers/ata/ata_piix.ko drivers/ata/pata_sis.ko drivers/ata/ata_generic.ko; do echo $m; done;   \
cat /dev/null ) > drivers/ata/modules.builtin
(for m in ; do echo $m; done;   \
cat /dev/null ) > security/integrity/ima/modules.builtin
make -f ./scripts/Makefile.modbuiltin obj=kernel/debug/kdb
(for m in ; do echo $m; done;   \
cat /dev/null ) > drivers/acpi/apei/modules.builtin
(for m in ; do echo $m; done;   \
cat /dev/null ) > drivers/acpi/dptf/modules.builtin
/usr/src/linux-headers-5.4.0-9-generic/tools/build/Makefile.build:37: /usr/src/linux-headers-5.4.0-9-generic/tools/build/Build.include: No such file or directory
make[5]: *** No rule to make target '/usr/src/linux-headers-5.4.0-9-generic/tools/build/Build.include'.  Stop.
make[4]: *** [Makefile:43: /usr/src/linux-headers-5.4.0-9-generic/tools/objtool/fixdep-in.o] Error 2
make[3]: *** [/usr/src/linux-headers-5.4.0-9-generic/tools/build/Makefile.include:5: fixdep] Error 2
make[2]: *** [Makefile:67: objtool] Error 2
make[1]: *** [Makefile:1783: tools/objtool] Error 2

thanks for any tip and keep it up!

@displaylink-dkurek

is there any reason why a regular ‘make install’ target doesn’t exist?

BTW while looking at that I found the versioning of the library is broken as well the kernel modules version is out-of-sync, want PR’s for these too?

Eg these: https://dpaste.de/XGBd/raw https://dpaste.de/LPYG/raw