AMD-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Mario Limonciello <superm1@kernel.org>
To: roman.li@amd.com, amd-gfx@lists.freedesktop.org
Cc: Mario Limonciello <mario.limonciello@amd.com>
Subject: [PATCH 0/4] Correct a series of off by 1 errors in DML and DML2
Date: Tue, 21 Jan 2025 07:57:15 -0600	[thread overview]
Message-ID: <20250121135719.2883833-1-superm1@kernel.org> (raw)

From: Mario Limonciello <mario.limonciello@amd.com>

Many people have reported a series of issues that lead to divide
by zero errors in DML2 code on DCN 3.5.

This divide by zero error is caused by accessing outside of the bound
of what is initialized on an array for the number of planes.

The first patch in the series fixes the immediate issue.  This patch
should go to fixes and stable.

The remaining patches fix what appears to be the same problem in other
code in both DML and DML2 that has (presumably) been copy/pasted for
loop iterators.

Mario Limonciello (4):
  drm/amd/display: Adjust plane init for off by one error
  drm/amd/display: Correct off by one errors in DML
  drm/amd/display: Correct some suspect code indentation
  drm/amd/display: Correct off by one errors in DML2

 .../dc/dml/dcn32/display_mode_vba_32.c        |  68 ++++-----
 .../amd/display/dc/dml2/display_mode_core.c   | 131 +++++++++---------
 .../src/dml2_core/dml2_core_dcn4_calcs.c      |  40 +++---
 .../dml21/src/dml2_core/dml2_core_shared.c    |  50 +++----
 4 files changed, 144 insertions(+), 145 deletions(-)

-- 
2.43.0


             reply	other threads:[~2025-01-21 13:57 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-21 13:57 Mario Limonciello [this message]
2025-01-21 13:57 ` [PATCH 1/4] drm/amd/display: Adjust plane init for off by one error Mario Limonciello
2025-01-21 16:32   ` Harry Wentland
2025-01-21 16:52     ` Mario Limonciello
2025-01-21 13:57 ` [PATCH 2/4] drm/amd/display: Correct off by one errors in DML Mario Limonciello
2025-01-21 13:57 ` [PATCH 3/4] drm/amd/display: Correct some suspect code indentation Mario Limonciello
2025-01-21 13:57 ` [PATCH 4/4] drm/amd/display: Correct off by one errors in DML2 Mario Limonciello

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250121135719.2883833-1-superm1@kernel.org \
    --to=superm1@kernel.org \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=mario.limonciello@amd.com \
    --cc=roman.li@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox