Kernel – 6.2-rc Pre-Release Tests. VMware OK, NVIDIA Fails..
Tested the December 19th git version of 6.2-rc, and – so far – VMware 17.0 (patched) compiles/loads OK, but NVIDIA 525.60.11 fails to compile:
……….
/home/rgadsdon/NVIDIA-Linux-x86_64-525.60.11/kernel/nvidia-drm/nvidia-drm-drv.o
/home/rgadsdon/NVIDIA-Linux-x86_64-525.60.11/kernel/nvidia-drm/nvidia-drm-drv.c: In function ‘nv_drm_init_mode_config’:
/home/rgadsdon/NVIDIA-Linux-x86_64-525.60.11/kernel/nvidia-drm/nvidia-drm-drv.c:262:21: error: ‘struct drm_mode_config’ has no member named ‘fb_base’
262 | dev->mode_config.fb_base = 0;
| ^
make[2]: *** [scripts/Makefile.build:252: /home/rgadsdon/NVIDIA-Linux-x86_64-525.60.11/kernel/nvidia-drm/nvidia-drm-drv.o] Error 1
make[1]: *** [Makefile:2008: /home/rgadsdon/NVIDIA-Linux-x86_64-525.60.11/kernel] Error 2
make[1]: Leaving directory ‘/usr/src/linux-6.2-rc0’
make: *** [Makefile:82: modules] Error 2
This is due to the removal of drm_mode_config::fb_base
see: https://www.spinics.net/lists/dri-devel/msg368009.html
Obviously, more changes to the kernel tree will be coming in the next few days, so more may get ‘broken’..
Robert Gadsdon. December 20th 2022.
This is currently running on my machine: 6.2-rc1 + nvidia 525.60.13 after a rewrite of Joan Bruguera (https://gist.github.com/joanbm) 470xx patch. Please read the warning that he had to use a huge hack to get it working…
diff -rupN nvidia-525.60.13/nvidia/nv-acpi.c nvidia-525.60.13p/nvidia/nv-acpi.c
— nvidia-525.60.13/nvidia/nv-acpi.c 2022-11-30 08:25:57.000000000 +0100
+++ nvidia-525.60.13p/nvidia/nv-acpi.c 2022-12-26 01:36:34.885455849 +0100
@@ -21,6 +21,7 @@
* DEALINGS IN THE SOFTWARE.
*/
+#include
#define __NO_VERSION__
#include “os-interface.h”
diff -rupN nvidia-525.60.13/nvidia-drm/nvidia-drm-connector.c nvidia-525.60.13p/nvidia-drm/nvidia-drm-connector.c
— nvidia-525.60.13/nvidia-drm/nvidia-drm-connector.c 2022-11-30 07:40:30.000000000 +0100
+++ nvidia-525.60.13p/nvidia-drm/nvidia-drm-connector.c 2022-12-26 01:31:54.244217513 +0100
@@ -20,6 +20,8 @@
* DEALINGS IN THE SOFTWARE.
*/
+#include
+#include
#include “nvidia-drm-conftest.h” /* NV_DRM_ATOMIC_MODESET_AVAILABLE */
#if defined(NV_DRM_ATOMIC_MODESET_AVAILABLE)
@@ -98,6 +100,7 @@ __nv_drm_detect_encoder(struct NvKmsKapi
break;
}
+#if LINUX_VERSION_CODE override_edid) {
const struct drm_property_blob *edid = connector->edid_blob_ptr;
@@ -110,6 +113,25 @@ __nv_drm_detect_encoder(struct NvKmsKapi
sizeof(pDetectParams->edid.buffer));
}
}
+#else
+ // Rel. commit “drm/edid: detach debugfs EDID override from EDID property update” (Jani Nikula, 24 Oct 2022)
+ // NOTE: HUGE HACK!
+ mutex_lock(&connector->edid_override_mutex);
+ if (connector->edid_override) {
+ const struct edid *edid = drm_edid_raw(connector->edid_override);
+ size_t edid_length = EDID_LENGTH * (edid->extensions + 1);
+ if (edid_length edid.buffer)) {
+ memcpy(pDetectParams->edid.buffer, edid, edid_length);
+ pDetectParams->edid.bufferSize = edid_length;
+ pDetectParams->overrideEdid = NV_TRUE;
+ } else {
+ WARN_ON(edid_length >
+ sizeof(pDetectParams->edid.buffer));
+ }
+ }
+ mutex_unlock(&connector->edid_override_mutex);
+#endif
+
if (!nvKms->getDynamicDisplayInfo(nv_dev->pDevice, pDetectParams)) {
NV_DRM_DEV_LOG_ERR(
diff -rupN nvidia-525.60.13/nvidia-drm/nvidia-drm-drv.c nvidia-525.60.13p/nvidia-drm/nvidia-drm-drv.c
— nvidia-525.60.13/nvidia-drm/nvidia-drm-drv.c 2022-11-30 07:40:30.000000000 +0100
+++ nvidia-525.60.13p/nvidia-drm/nvidia-drm-drv.c 2022-12-26 01:33:19.280609961 +0100
@@ -20,6 +20,7 @@
* DEALINGS IN THE SOFTWARE.
*/
+#include
#include “nvidia-drm-conftest.h” /* NV_DRM_AVAILABLE and NV_DRM_DRM_GEM_H_PRESENT */
#include “nvidia-drm-priv.h”
@@ -257,9 +258,12 @@ nv_drm_init_mode_config(struct nv_drm_de
dev->mode_config.preferred_depth = 24;
dev->mode_config.prefer_shadow = 1;
+// Rel. commit “drm: Remove drm_mode_config::fb_base” (Zack Rusin, 18 Oct 2022)
+#if defined(CONFIG_FB) && LINUX_VERSION_CODE mode_config.fb_base = 0;
+#endif
#if defined(NV_DRM_CRTC_STATE_HAS_ASYNC_FLIP) || \
defined(NV_DRM_CRTC_STATE_HAS_PAGEFLIP_FLAGS)
There seem to be some bits missing?
‘# include’s with nothing following?
RG.
Watching the original patch I guess he meant to write
+#include
+#include
I am still testing (it would be nice to have a raw format to download since the ” are wrong)
this doesn’t work for me
https://pastebin.com/A20axQJa
https://pastebin.com/A20axQJa
this doesn’t work for me
https://github.com/NVIDIA/open-gpu-kernel-modules/issues/429