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

Unable to build on kernel 5.13 #297

Closed
cryocz opened this issue Jul 26, 2021 · 13 comments
Closed

Unable to build on kernel 5.13 #297

cryocz opened this issue Jul 26, 2021 · 13 comments

Comments

@cryocz
Copy link

cryocz commented Jul 26, 2021

Unable to build evdi v1.9.1 on 5.13.4-200.fc34.x86_64.

Setup

  • Are you using the latest EVDI version? Yes, v1.9.1
  • Is this issue related to evdi/kernel? Yes
  • Linux distribution and its version: Fedora 34
  • Linux kernel version: 5.13.4
  • Xorg version (if used): 1.20.11 (according to rpm -qa | grep xorg-x11-server-Xorg)
  • Desktop environment in use: GNOME 40.0

Steps to reproduce

$ sudo dkms install -m evdi -v 1.9.1 -k 5.13.4-200.fc34.x86_64/x86_64

Kernel preparation unnecessary for this kernel.  Skipping...

Building module:
cleaning build area...
make -j8 KERNELRELEASE=5.13.4-200.fc34.x86_64 all INCLUDEDIR=/lib/modules/5.13.4-200.fc34.x86_64/build/include KVERSION=5.13.4-200.fc34.x86_64 DKMS_BUILD=1...(bad exit status: 2)
Error! Bad return status for module build on kernel: 5.13.4-200.fc34.x86_64 (x86_64)
Consult /var/lib/dkms/evdi/1.9.1/build/make.log for more information.

Errors found in /var/lib/dkms/evdi/1.9.1/build/make.log:

/var/lib/dkms/evdi/1.9.1/build/evdi_modeset.c:331:26: error: initialization of ‘void (*)(struct drm_plane *, struct drm_atomic_state *)’ from incompatible pointer type ‘void (*)(struct drm_plane *, struct drm_plane_state *)’ [-Werror=incompatible-pointer-types]
  331 |         .atomic_update = evdi_plane_atomic_update,
      |                          ^~~~~~~~~~~~~~~~~~~~~~~~
/var/lib/dkms/evdi/1.9.1/build/evdi_modeset.c:331:26: note: (near initialization for ‘evdi_plane_helper_funcs.atomic_update’)
/var/lib/dkms/evdi/1.9.1/build/evdi_modeset.c:332:23: error: ‘drm_gem_fb_prepare_fb’ undeclared here (not in a function); did you mean ‘drm_gem_fb_create’?
  332 |         .prepare_fb = drm_gem_fb_prepare_fb
      |                       ^~~~~~~~~~~~~~~~~~~~~
      |                       drm_gem_fb_create
/var/lib/dkms/evdi/1.9.1/build/evdi_modeset.c:336:26: error: initialization of ‘void (*)(struct drm_plane *, struct drm_atomic_state *)’ from incompatible pointer type ‘void (*)(struct drm_plane *, struct drm_plane_state *)’ [-Werror=incompatible-pointer-types]
  336 |         .atomic_update = evdi_cursor_atomic_update,
      |                          ^~~~~~~~~~~~~~~~~~~~~~~~~
/var/lib/dkms/evdi/1.9.1/build/evdi_modeset.c:336:26: note: (near initialization for ‘evdi_cursor_helper_funcs.atomic_update’)
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:273: /var/lib/dkms/evdi/1.9.1/build/evdi_modeset.o] Error 1
make[1]: *** [Makefile:1853: /var/lib/dkms/evdi/1.9.1/build] Error 2
make[1]: Leaving directory '/usr/src/kernels/5.13.4-200.fc34.x86_64'
make: *** [Makefile:28: all] Error 2
@elguero
Copy link
Contributor

elguero commented Jul 27, 2021

Until there is a new release, you need to use the code in the devel branch to build against 5.13.

(Duplicate of #296)

@olof-nord
Copy link

Is kernel 5.13 planned to be supported?
My docking station stopped working (again) with v5.13.

I see no mention of it in the CI config.

Any estimation when an upcoming release is planned?

@xtermi2
Copy link

xtermi2 commented Jul 30, 2021

Same on Ubuntu 21.04 with 5.13 mainline kernel.

@carestad
Copy link

carestad commented Aug 12, 2021

From the commit log, 5.14 support was added recently so I would hope and think 5.13 is also supported now? But would have to build it manually though.

I believe Ubuntu 21.10 and Pop 21.10 will both use 5.13 kernels, so it would be nice it was working by then

@carestad
Copy link

I found a way to make the DisplayLink driver work with the 5.13 kernel in PopOS 21.04. I added a step-by-step in the DisplayLink forum. It might be applicable to some of the cases in here as well.

@xtermi2
Copy link

xtermi2 commented Aug 14, 2021

@carestad thx, works with 5.13 on Ubuntu 21.04

@dongsupark
Copy link

@carestad Thanks a lot.
It works with Kernel 5.13 on Fedora 34.
Though I had to disable check_libdrm in the script, as the function simply assumes Debian-specific commands like apt exist.

--- displaylink-installer.sh.orig       2021-08-16 11:11:02.115185859 +0200
+++ displaylink-installer.sh    2021-08-16 11:03:20.480823052 +0200
@@ -568,8 +568,8 @@
   # DKMS
   hash dkms 2>/dev/null || missing_requirement "DKMS"
 
-  # libdrm
-  check_libdrm || missing_requirement "libdrm"
+  ## libdrm
+  #check_libdrm || missing_requirement "libdrm"
 
   # Required kernel version
   KVER=$(uname -r)

@derDaywalker
Copy link

@carestad Thanks a lot, works like a charm.

I had to append -L to curl to follow a redirect

curl -L https://github.com/DisplayLink/evdi/archive/refs/heads/devel.tar.gz -o evdi.tar.gz

@dongsupark
Also thank you very much, I had to do this too, although libdrm is installed, but yes, on arch there is no apt too.

Now everything works again on 5.13.12-arch1-1

@carestad
Copy link

I had to append -L to curl to follow a redirect

curl -L https://github.com/DisplayLink/evdi/archive/refs/heads/devel.tar.gz -o evdi.tar.gz

Cheers, I updated the forum post with this 🙂

@DavidNorena
Copy link

for manjaro users is even easier

pamac install evdi-git :)

@YoannMa
Copy link

YoannMa commented Oct 1, 2021

@carestad Hi, would you mind posting the copy of your step-by-step here (or on Gist ?) as the DisplayLink forum seems down

@carestad
Copy link

carestad commented Oct 7, 2021

@carestad Hi, would you mind posting the copy of your step-by-step here (or on Gist ?) as the DisplayLink forum seems down

@YoannMa Unfortunately I did not have a copy of it. The forum is back online now though. I have made a public gist available here as well: https://gist.github.com/carestad/cbee30214e6bf6b153054d35d4cb3b18

@edwade
Copy link

edwade commented Nov 10, 2021

I found a way to make the DisplayLink driver work with the 5.13 kernel in PopOS 21.04. I added a step-by-step in the DisplayLink forum. It might be applicable to some of the cases in here as well.

Thank you @carestad - got me back up and running on Ubuntu 21.10 (Impish)! Absolute lifesaver!

@cryocz cryocz closed this as completed May 10, 2022
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

10 participants