From 01c9f529e540e79091fa775355fc6c4c2a26198e Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Fri, 21 Jul 2023 14:07:43 +0200 Subject: [PATCH] drop some 5.10 and 5.15 drm patches --- ...play-add-monitor-specific-edid-quirk.patch | 65 ------------------- ...-for-bos-that-are-always-valid-in-vm.patch | 62 ------------------ ...onsider-pinned-bos-for-eviction-swap.patch | 41 ------------ queue-5.10/series | 3 - ...play-add-monitor-specific-edid-quirk.patch | 65 ------------------- queue-5.15/series | 1 - 6 files changed, 237 deletions(-) delete mode 100644 queue-5.10/drm-amd-display-add-monitor-specific-edid-quirk.patch delete mode 100644 queue-5.10/drm-amdgpu-fix-clearing-mappings-for-bos-that-are-always-valid-in-vm.patch delete mode 100644 queue-5.10/drm-ttm-never-consider-pinned-bos-for-eviction-swap.patch delete mode 100644 queue-5.15/drm-amd-display-add-monitor-specific-edid-quirk.patch diff --git a/queue-5.10/drm-amd-display-add-monitor-specific-edid-quirk.patch b/queue-5.10/drm-amd-display-add-monitor-specific-edid-quirk.patch deleted file mode 100644 index ffeb2d9165c..00000000000 --- a/queue-5.10/drm-amd-display-add-monitor-specific-edid-quirk.patch +++ /dev/null @@ -1,65 +0,0 @@ -From 613a7956deb3b1ffa2810c6d4c90ee9c3d743dbb Mon Sep 17 00:00:00 2001 -From: Aurabindo Pillai -Date: Mon, 12 Jun 2023 12:44:00 -0400 -Subject: drm/amd/display: Add monitor specific edid quirk - -From: Aurabindo Pillai - -commit 613a7956deb3b1ffa2810c6d4c90ee9c3d743dbb upstream. - -Disable FAMS on a Samsung Odyssey G9 monitor. Experiments show that this -monitor does not work well under some use cases, and is likely -implementation specific bug on the monitor's firmware. - -Cc: stable@vger.kernel.org -Reviewed-by: Rodrigo Siqueira -Signed-off-by: Aurabindo Pillai -Tested-by: Daniel Wheeler -Signed-off-by: Alex Deucher -Signed-off-by: Greg Kroah-Hartman ---- - drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c | 26 ++++++++++++++ - 1 file changed, 26 insertions(+) - ---- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c -+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c -@@ -41,6 +41,30 @@ - - #include "dm_helpers.h" - -+static u32 edid_extract_panel_id(struct edid *edid) -+{ -+ return (u32)edid->mfg_id[0] << 24 | -+ (u32)edid->mfg_id[1] << 16 | -+ (u32)EDID_PRODUCT_ID(edid); -+} -+ -+static void apply_edid_quirks(struct edid *edid, struct dc_edid_caps *edid_caps) -+{ -+ uint32_t panel_id = edid_extract_panel_id(edid); -+ -+ switch (panel_id) { -+ /* Workaround for some monitors which does not work well with FAMS */ -+ case drm_edid_encode_panel_id('S', 'A', 'M', 0x0E5E): -+ case drm_edid_encode_panel_id('S', 'A', 'M', 0x7053): -+ case drm_edid_encode_panel_id('S', 'A', 'M', 0x71AC): -+ DRM_DEBUG_DRIVER("Disabling FAMS on monitor with panel id %X\n", panel_id); -+ edid_caps->panel_patch.disable_fams = true; -+ break; -+ default: -+ return; -+ } -+} -+ - /* dm_helpers_parse_edid_caps - * - * Parse edid caps -@@ -123,6 +147,8 @@ enum dc_edid_status dm_helpers_parse_edi - else - edid_caps->speaker_flags = DEFAULT_SPEAKER_LOCATION; - -+ apply_edid_quirks(edid_buf, edid_caps); -+ - kfree(sads); - kfree(sadb); - diff --git a/queue-5.10/drm-amdgpu-fix-clearing-mappings-for-bos-that-are-always-valid-in-vm.patch b/queue-5.10/drm-amdgpu-fix-clearing-mappings-for-bos-that-are-always-valid-in-vm.patch deleted file mode 100644 index c0f5e58d7f9..00000000000 --- a/queue-5.10/drm-amdgpu-fix-clearing-mappings-for-bos-that-are-always-valid-in-vm.patch +++ /dev/null @@ -1,62 +0,0 @@ -From ea2c3c08554601b051d91403a241266e1cf490a5 Mon Sep 17 00:00:00 2001 -From: Samuel Pitoiset -Date: Fri, 16 Jun 2023 15:14:07 +0200 -Subject: drm/amdgpu: fix clearing mappings for BOs that are always valid in VM -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -From: Samuel Pitoiset - -commit ea2c3c08554601b051d91403a241266e1cf490a5 upstream. - -Per VM BOs must be marked as moved or otherwise their ranges are not -updated on use which might be necessary when the replace operation -splits mappings. - -This fixes random GPU hangs when replacing sparse mappings from the -userspace, while OP_MAP/OP_UNMAP works fine because always valid BOs -are correctly handled there. - -Cc: stable@vger.kernel.org -Signed-off-by: Samuel Pitoiset -Reviewed-by: Christian König -Signed-off-by: Alex Deucher -Signed-off-by: Greg Kroah-Hartman ---- - drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 12 ++++++++++++ - 1 file changed, 12 insertions(+) - ---- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c -+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c -@@ -2470,18 +2470,30 @@ int amdgpu_vm_bo_clear_mappings(struct a - - /* Insert partial mapping before the range */ - if (!list_empty(&before->list)) { -+ struct amdgpu_bo *bo = before->bo_va->base.bo; -+ - amdgpu_vm_it_insert(before, &vm->va); - if (before->flags & AMDGPU_PTE_PRT) - amdgpu_vm_prt_get(adev); -+ -+ if (bo && bo->tbo.base.resv == vm->root.bo->tbo.base.resv && -+ !before->bo_va->base.moved) -+ amdgpu_vm_bo_moved(&before->bo_va->base); - } else { - kfree(before); - } - - /* Insert partial mapping after the range */ - if (!list_empty(&after->list)) { -+ struct amdgpu_bo *bo = after->bo_va->base.bo; -+ - amdgpu_vm_it_insert(after, &vm->va); - if (after->flags & AMDGPU_PTE_PRT) - amdgpu_vm_prt_get(adev); -+ -+ if (bo && bo->tbo.base.resv == vm->root.bo->tbo.base.resv && -+ !after->bo_va->base.moved) -+ amdgpu_vm_bo_moved(&after->bo_va->base); - } else { - kfree(after); - } diff --git a/queue-5.10/drm-ttm-never-consider-pinned-bos-for-eviction-swap.patch b/queue-5.10/drm-ttm-never-consider-pinned-bos-for-eviction-swap.patch deleted file mode 100644 index 78eb3ac4cb1..00000000000 --- a/queue-5.10/drm-ttm-never-consider-pinned-bos-for-eviction-swap.patch +++ /dev/null @@ -1,41 +0,0 @@ -From a2848d08742c8e8494675892c02c0d22acbe3cf8 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Christian=20K=C3=B6nig?= -Date: Fri, 7 Jul 2023 11:25:00 +0200 -Subject: drm/ttm: never consider pinned BOs for eviction&swap -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -From: Christian König - -commit a2848d08742c8e8494675892c02c0d22acbe3cf8 upstream. - -There is a small window where we have already incremented the pin count -but not yet moved the bo from the lru to the pinned list. - -Signed-off-by: Christian König -Reported-by: Pelloux-Prayer, Pierre-Eric -Tested-by: Pelloux-Prayer, Pierre-Eric -Acked-by: Alex Deucher -Cc: stable@vger.kernel.org -Link: https://patchwork.freedesktop.org/patch/msgid/20230707120826.3701-1-christian.koenig@amd.com -Signed-off-by: Greg Kroah-Hartman ---- - drivers/gpu/drm/ttm/ttm_bo.c | 6 ++++++ - 1 file changed, 6 insertions(+) - ---- a/drivers/gpu/drm/ttm/ttm_bo.c -+++ b/drivers/gpu/drm/ttm/ttm_bo.c -@@ -670,6 +670,12 @@ static bool ttm_bo_evict_swapout_allowab - { - bool ret = false; - -+ if (bo->pin_count) { -+ *locked = false; -+ *busy = false; -+ return false; -+ } -+ - if (bo->base.resv == ctx->resv) { - dma_resv_assert_held(bo->base.resv); - if (ctx->flags & TTM_OPT_FLAG_ALLOW_RES_EVICT) diff --git a/queue-5.10/series b/queue-5.10/series index 8068cdbd143..b11920ea80c 100644 --- a/queue-5.10/series +++ b/queue-5.10/series @@ -409,10 +409,7 @@ md-raid0-add-discard-support-for-the-original-layout.patch fs-dlm-return-positive-pid-value-for-f_getlk.patch drm-atomic-allow-vblank-enabled-self-refresh-disable.patch drm-rockchip-vop-leave-vblank-enabled-in-self-refresh.patch -drm-amdgpu-fix-clearing-mappings-for-bos-that-are-always-valid-in-vm.patch drm-amd-display-correct-dmub_fw_version-macro.patch -drm-amd-display-add-monitor-specific-edid-quirk.patch -drm-ttm-never-consider-pinned-bos-for-eviction-swap.patch serial-atmel-don-t-enable-irqs-prematurely.patch tty-serial-samsung_tty-fix-a-memory-leak-in-s3c24xx_serial_getclk-in-case-of-error.patch tty-serial-samsung_tty-fix-a-memory-leak-in-s3c24xx_serial_getclk-when-iterating-clk.patch diff --git a/queue-5.15/drm-amd-display-add-monitor-specific-edid-quirk.patch b/queue-5.15/drm-amd-display-add-monitor-specific-edid-quirk.patch deleted file mode 100644 index 5995cc6a4ae..00000000000 --- a/queue-5.15/drm-amd-display-add-monitor-specific-edid-quirk.patch +++ /dev/null @@ -1,65 +0,0 @@ -From 613a7956deb3b1ffa2810c6d4c90ee9c3d743dbb Mon Sep 17 00:00:00 2001 -From: Aurabindo Pillai -Date: Mon, 12 Jun 2023 12:44:00 -0400 -Subject: drm/amd/display: Add monitor specific edid quirk - -From: Aurabindo Pillai - -commit 613a7956deb3b1ffa2810c6d4c90ee9c3d743dbb upstream. - -Disable FAMS on a Samsung Odyssey G9 monitor. Experiments show that this -monitor does not work well under some use cases, and is likely -implementation specific bug on the monitor's firmware. - -Cc: stable@vger.kernel.org -Reviewed-by: Rodrigo Siqueira -Signed-off-by: Aurabindo Pillai -Tested-by: Daniel Wheeler -Signed-off-by: Alex Deucher -Signed-off-by: Greg Kroah-Hartman ---- - drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c | 26 ++++++++++++++ - 1 file changed, 26 insertions(+) - ---- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c -+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c -@@ -40,6 +40,30 @@ - - #include "dm_helpers.h" - -+static u32 edid_extract_panel_id(struct edid *edid) -+{ -+ return (u32)edid->mfg_id[0] << 24 | -+ (u32)edid->mfg_id[1] << 16 | -+ (u32)EDID_PRODUCT_ID(edid); -+} -+ -+static void apply_edid_quirks(struct edid *edid, struct dc_edid_caps *edid_caps) -+{ -+ uint32_t panel_id = edid_extract_panel_id(edid); -+ -+ switch (panel_id) { -+ /* Workaround for some monitors which does not work well with FAMS */ -+ case drm_edid_encode_panel_id('S', 'A', 'M', 0x0E5E): -+ case drm_edid_encode_panel_id('S', 'A', 'M', 0x7053): -+ case drm_edid_encode_panel_id('S', 'A', 'M', 0x71AC): -+ DRM_DEBUG_DRIVER("Disabling FAMS on monitor with panel id %X\n", panel_id); -+ edid_caps->panel_patch.disable_fams = true; -+ break; -+ default: -+ return; -+ } -+} -+ - /* dm_helpers_parse_edid_caps - * - * Parse edid caps -@@ -122,6 +146,8 @@ enum dc_edid_status dm_helpers_parse_edi - else - edid_caps->speaker_flags = DEFAULT_SPEAKER_LOCATION; - -+ apply_edid_quirks(edid_buf, edid_caps); -+ - kfree(sads); - kfree(sadb); - diff --git a/queue-5.15/series b/queue-5.15/series index 04bd2ef0874..be7f8242b7e 100644 --- a/queue-5.15/series +++ b/queue-5.15/series @@ -488,7 +488,6 @@ drm-atomic-allow-vblank-enabled-self-refresh-disable.patch drm-rockchip-vop-leave-vblank-enabled-in-self-refresh.patch drm-amdgpu-fix-clearing-mappings-for-bos-that-are-always-valid-in-vm.patch drm-amd-display-correct-dmub_fw_version-macro.patch -drm-amd-display-add-monitor-specific-edid-quirk.patch drm-amdgpu-avoid-restore-process-run-into-dead-loop.patch drm-ttm-don-t-leak-a-resource-on-swapout-move-error.patch drm-ttm-never-consider-pinned-bos-for-eviction-swap.patch -- 2.47.3