x11-drivers/evdi: Fix building for linux kernel 6.2 and up
There are some changes in linux kernel 6.2 that prevent building of evdi. This patch fixes it for live ebuild (not sure if it can be backported). I'm also trying to get it merged upstream. Reffer: https://github.com/DisplayLink/evdi/pull/401 Signed-off-by: listout <listout@protonmail.com>
This commit is contained in:
parent
e8cfd062ad
commit
836a646d88
@ -1,3 +1,4 @@
|
||||
AUX evdi-9999-linux-6.0.2-fix.patch 1424 BLAKE2B 7966738e8bd107997c54c1a199e73fb6079d0a8027682f223b043ca5fa6e832b592f5af725727502c8a88a82d1526d493590dfcad645ab88a2097746829383b3 SHA512 307172802e4235405f0b9b888e12d580d403cca16baeec27c2dea97a93923f5df45b30ded0b251befefb5d253fd2982ad35bf0810e78540da6ef889dad9578dc
|
||||
DIST evdi-1.10.0.tar.gz 68714 BLAKE2B 5fab970380eee7430154733427203e0507652290869014fa3958c11ac6562e08805056568b6527a0744f5ff69064c5e124a687aa4e82df6d57411a03f1b3a518 SHA512 3c945de20fbbf22324dc5f1199dfcddb98b26c1e7913c700874b30816359acf603f119889e8da4b8b6aab3786a8b0ff6ddcd044a7a9d7c31faf2a5d5382728b3
|
||||
DIST evdi-1.10.1.tar.gz 68769 BLAKE2B b0fd9cc6adf5125666d45cca8cbb04b7bbaae4d2e85b97a874d69a3baf2631204ba6b60c0200c66f105f92d5c4e3de9eb331226aa5c4931bae2529355941cd1c SHA512 e24c82d341463e8ba7dea3dc66dd0264d3c9511b24022f62685fdcb6f9b3ba899e4091198b37531da3c628ab82a52ac9d40a1104ee8fc541b98a77bce4de01f8
|
||||
DIST evdi-1.11.0.tar.gz 69054 BLAKE2B e0839cfb82e421b0b38adb0237b7b6937f67f4e47314b255a7682facd969be3ed1aff8f5d4d8fcbbb7949a5fa9c07b7e9719dedd6e7413d8d8a9cf9f46856cc8 SHA512 87c2ecb505ce9e2a2af20e6bed377cb9fd0564440fcbca7e22aa30b50a2edf4a94d4778b24b40096ea66f2020139fa8b54ade633c447c3ef8287e6a22524186f
|
||||
@ -8,5 +9,5 @@ EBUILD evdi-1.10.1.ebuild 771 BLAKE2B a49f50153b1f0972f7888fb78f0f08370f3c1f196c
|
||||
EBUILD evdi-1.11.0.ebuild 771 BLAKE2B a49f50153b1f0972f7888fb78f0f08370f3c1f196c11d0f21cee4a7b6d01750f39cf2931f7d0b566db59fb92c894b95645bd3cee7cc48e2acd850a6590cc526e SHA512 c25af388ba1cf37328f4cbf0ec45adc84b9c151faa359ac0f54396f0cc082d7b2b384d4e713af0656fa2984b43f265304f02d7225328199d40d342ce03d292c5
|
||||
EBUILD evdi-1.12.0.ebuild 771 BLAKE2B b8a77c581fd9c0958e96f0cfe1c4e4f261af9c09aa53b727fb622a9bccde80c75cf9319d2e73bf18367ac02a5faf3147cae200750d0865317546684fc5555223 SHA512 ab89b13fc069035a9882525705873a0ecd9b3bde21ae13fc169c1c473d797b750778a59bdcb9f8a77788f1f088c9440b9cc75522951d52f358ffde9d73011c78
|
||||
EBUILD evdi-1.9.1.ebuild 633 BLAKE2B c3d3557accee3db1066c2d0ee0d5c27325b1c9a52339923ca9b55598cf44e9ee8b4b65dbbbc856ba1f04345eba6d80917be95c07866c402342a00b5a0b6819f8 SHA512 edc0726a8b2f775fe21e5fed7dac167e88be17fac475a6f51fcd64e2270e63557b287bc334e4b34bbda02c0abe4e4c8c4b4050ccd5e697b63738d1cc4830585b
|
||||
EBUILD evdi-9999.ebuild 771 BLAKE2B b8a77c581fd9c0958e96f0cfe1c4e4f261af9c09aa53b727fb622a9bccde80c75cf9319d2e73bf18367ac02a5faf3147cae200750d0865317546684fc5555223 SHA512 ab89b13fc069035a9882525705873a0ecd9b3bde21ae13fc169c1c473d797b750778a59bdcb9f8a77788f1f088c9440b9cc75522951d52f358ffde9d73011c78
|
||||
EBUILD evdi-9999.ebuild 833 BLAKE2B 6efba2d261f3a0f99eb0b8fdd7dec46d5d0505259f5b58212e5e129db828e6e931cb61ae355db4c6b39f7349faa2378e0915a75ed7025be32c6d07c92a7f0f59 SHA512 8b9bfcb3b0786fe288e35c8e10840c2593721164afdc9e443965cc85532b0da1ed919df763f9d22cf33af3abee62417991220ec96a4390244c950912aab7c12a
|
||||
MISC metadata.xml 323 BLAKE2B 0fccf5a219e12db367cf9bae8f8df08a8af86edd49ce0e6948aa5250415f1123f4c4ba0a5dd44b8242425a4965e70a2c63e2e73fa61eed370c47543ccd0224ed SHA512 5f0ce854399dfd6e9ebcf6f9b8a5ed26ad0a13ddac9a185c63033332801706f126bb2b09977319e984687da529381123f5a31693d7d8a0a648212fba0e01d2e5
|
||||
|
@ -27,6 +27,10 @@ BDEPEND="sys-kernel/linux-headers"
|
||||
MODULE_NAMES="evdi(video:${S})"
|
||||
CONFIG_CHECK="~FB_VIRTUAL ~I2C"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-${PV}-linux-6.0.2-fix.patch
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
default
|
||||
local KVER=$(cat "${KERNEL_DIR}/include/config/kernel.release")
|
||||
|
53
x11-drivers/evdi/files/evdi-9999-linux-6.0.2-fix.patch
Normal file
53
x11-drivers/evdi/files/evdi-9999-linux-6.0.2-fix.patch
Normal file
@ -0,0 +1,53 @@
|
||||
# Original patch was suggested by Crashdummyy.
|
||||
#
|
||||
# Since commit 9877d8f6bc374912b08dfe862cddbb78b395a5ef in the linux kernel feild
|
||||
# fbdev has been renamed to info in struct drm_fb_helper.
|
||||
#
|
||||
# Reffer: DisplayLink#394
|
||||
# Reffer: DisplayLink#384
|
||||
--- a/evdi_fb.c
|
||||
+++ b/evdi_fb.c
|
||||
@@ -405,7 +405,11 @@ static int evdifb_create(struct drm_fb_helper *helper,
|
||||
fb = &efbdev->efb.base;
|
||||
|
||||
efbdev->helper.fb = fb;
|
||||
+#if KERNEL_VERSION(6, 1, 12) >= LINUX_VERSION_CODE
|
||||
efbdev->helper.fbdev = info;
|
||||
+#else
|
||||
+ efbdev->helper.info = info;
|
||||
+#endif
|
||||
|
||||
strcpy(info->fix.id, "evdidrmfb");
|
||||
|
||||
@@ -459,8 +463,13 @@ static void evdi_fbdev_destroy(__always_unused struct drm_device *dev,
|
||||
{
|
||||
struct fb_info *info;
|
||||
|
||||
+#if KERNEL_VERSION(6, 1, 12) >= LINUX_VERSION_CODE
|
||||
if (efbdev->helper.fbdev) {
|
||||
info = efbdev->helper.fbdev;
|
||||
+#else
|
||||
+ if (efbdev->helper.info) {
|
||||
+ info = efbdev->helper.info;
|
||||
+#endif
|
||||
unregister_framebuffer(info);
|
||||
if (info->cmap.len)
|
||||
fb_dealloc_cmap(&info->cmap);
|
||||
@@ -537,10 +546,17 @@ void evdi_fbdev_unplug(struct drm_device *dev)
|
||||
return;
|
||||
|
||||
efbdev = evdi->fbdev;
|
||||
+#if KERNEL_VERSION(6, 1, 12) >= LINUX_VERSION_CODE
|
||||
if (efbdev->helper.fbdev) {
|
||||
struct fb_info *info;
|
||||
|
||||
info = efbdev->helper.fbdev;
|
||||
+#else
|
||||
+ if (efbdev->helper.info) {
|
||||
+ struct fb_info *info;
|
||||
+
|
||||
+ info = efbdev->helper.info;
|
||||
+#endif
|
||||
#if KERNEL_VERSION(5, 6, 0) <= LINUX_VERSION_CODE || defined(EL8)
|
||||
unregister_framebuffer(info);
|
||||
#else
|
Loading…
Reference in New Issue
Block a user