]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
drm/vc4: hvs: Fix dlist debug not resetting the next entry pointer
authorDave Stevenson <dave.stevenson@raspberrypi.com>
Fri, 21 Jun 2024 15:20:41 +0000 (16:20 +0100)
committerDave Stevenson <dave.stevenson@raspberrypi.com>
Mon, 9 Sep 2024 12:02:53 +0000 (13:02 +0100)
The debug function to display the dlists didn't reset next_entry_start
when starting each display, so resulting in not stopping the
list at the correct place.

Fixes: c6dac00340fc ("drm/vc4: hvs: Add debugfs node that dumps the current display lists")
Reviewed-by: Maxime Ripard <mripard@kernel.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20240621152055.4180873-18-dave.stevenson@raspberrypi.com
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
drivers/gpu/drm/vc4/vc4_hvs.c

index 8dab59341a82036bdf593c99935790e79f630523..bdc70b62905452b7cc77a704f2a5deaa9c20eae9 100644 (file)
@@ -110,7 +110,7 @@ static int vc4_hvs_debugfs_dlist(struct seq_file *m, void *data)
        struct vc4_dev *vc4 = to_vc4_dev(dev);
        struct vc4_hvs *hvs = vc4->hvs;
        struct drm_printer p = drm_seq_file_printer(m);
-       unsigned int next_entry_start = 0;
+       unsigned int next_entry_start;
        unsigned int i, j;
        u32 dlist_word, dispstat;
 
@@ -124,6 +124,7 @@ static int vc4_hvs_debugfs_dlist(struct seq_file *m, void *data)
                }
 
                drm_printf(&p, "HVS chan %u:\n", i);
+               next_entry_start = 0;
 
                for (j = HVS_READ(SCALER_DISPLISTX(i)); j < 256; j++) {
                        dlist_word = readl((u32 __iomem *)vc4->hvs->dlist + j);