Skip to content

Commit

Permalink
graphics/drm-510-kmod: fix runtime on powerpc64*
Browse files Browse the repository at this point in the history
Add a patch from freebsd/drm-kmod#214 to failure to load:
Mar 16 10:29:34 talos kernel: link_elf: symbol acpi_iicbus_driver undefined
Mar 16 10:29:35 talos kernel: KLD radeonkms.ko: depends on drmn - not available or version mismatch

evadot mentioned that it had been fixed, but the issue still happens on FreeBSD
13.2-RC2 with drm-510-kmod-5.10.163_2.
  • Loading branch information
pkubaj committed Mar 16, 2023
1 parent f4553a3 commit ffbe0e2
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
2 changes: 1 addition & 1 deletion graphics/drm-510-kmod/Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PORTNAME= drm-510-kmod
PORTVERSION= 5.10.163
PORTREVISION= 2
PORTREVISION= 3
CATEGORIES= graphics kld

MAINTAINER= x11@FreeBSD.org
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
--- drivers/gpu/drm/drm_os_freebsd.c.bak 2022-11-05 15:37:52.826643000 -0400
+++ drivers/gpu/drm/drm_os_freebsd.c 2022-11-05 15:38:25.740620000 -0400
@@ -202,11 +202,15 @@
#if __FreeBSD_version >= 1301505
#if __FreeBSD_version >= 1400058
DRIVER_MODULE(iicbus, drmn, iicbus_driver, NULL, NULL);
+#if defined(__amd64__) || defined(__aarch64__) || defined(__i386__)
DRIVER_MODULE(acpi_iicbus, drmn, acpi_iicbus_driver, NULL, NULL);
+#endif
#else
DRIVER_MODULE(iicbus, drmn, iicbus_driver, iicbus_devclass, NULL, NULL);
+#if defined(__amd64__) || defined(__aarch64__) || defined(__i386__)
DRIVER_MODULE(acpi_iicbus, drmn, acpi_iicbus_driver, iicbus_devclass, NULL,
NULL);
+#endif
#endif
MODULE_DEPEND(drmn, iicbus, IICBUS_MINVER, IICBUS_PREFVER, IICBUS_MAXVER);
MODULE_DEPEND(drmn, iic, 1, 1, 1);

0 comments on commit ffbe0e2

Please sign in to comment.