Comments

Kernel – 6.2-rc Pre-Release Tests. VMware OK, NVIDIA Fails.. — 6 Comments

  1. 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)

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.