]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
fbdev: tcx.c fix mem_map to correct smem_start offset
authorRené Rebe <rene@exactco.de>
Thu, 20 Nov 2025 13:24:00 +0000 (14:24 +0100)
committerHelge Deller <deller@gmx.de>
Tue, 2 Dec 2025 18:44:05 +0000 (19:44 +0100)
403ae52ac047 ("sparc: fix drivers/video/tcx.c warning") changed the
physbase initializing breaking the user-space mmap, e.g. for Xorg
entirely.

Fix fbdev mmap table so the sbus mmap helper work correctly, and
not try to map vastly (physbase) offset memory.

Fixes: 403ae52ac047 ("sparc: fix drivers/video/tcx.c warning")
Cc: <stable@vger.kernel.org>
Signed-off-by: René Rebe <rene@exactco.de>
Signed-off-by: Helge Deller <deller@gmx.de>
drivers/video/fbdev/tcx.c

index f9a0085ad72bf7f274eea48967d79e10b1dbd2cb..ca9e84e8d8605220b51ec754e72f8d7cbdc1171e 100644 (file)
@@ -428,7 +428,7 @@ static int tcx_probe(struct platform_device *op)
                        j = i;
                        break;
                }
-               par->mmap_map[i].poff = op->resource[j].start;
+               par->mmap_map[i].poff = op->resource[j].start - info->fix.smem_start;
        }
 
        info->fbops = &tcx_ops;