]> www.infradead.org Git - users/willy/linux.git/commitdiff
drm/ast: Detect DRAM before TX-chip
authorThomas Zimmermann <tzimmermann@suse.de>
Fri, 17 Jan 2025 10:29:07 +0000 (11:29 +0100)
committerThomas Zimmermann <tzimmermann@suse.de>
Wed, 22 Jan 2025 12:52:48 +0000 (13:52 +0100)
Move DRAM detection before TX-chip detection. Both steps are independent
from each other. Detection of the TX-chip is now next to posting those
chips, which can be done in a single step.

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250117103450.28692-3-tzimmermann@suse.de
drivers/gpu/drm/ast/ast_main.c

index 037d389ab630dee28319771d12d46d31d0479ec3..456230bef2736437ad2ce4c4446a9a72cbc8a8e0 100644 (file)
@@ -290,15 +290,13 @@ struct drm_device *ast_device_create(struct pci_dev *pdev,
        ast->regs = regs;
        ast->ioregs = ioregs;
 
-       ast_detect_tx_chip(ast, need_post);
-
        ret = ast_get_dram_info(ast);
        if (ret)
                return ERR_PTR(ret);
-
        drm_info(dev, "dram MCLK=%u Mhz type=%d bus_width=%d\n",
                 ast->mclk, ast->dram_type, ast->dram_bus_width);
 
+       ast_detect_tx_chip(ast, need_post);
        if (need_post)
                ast_post_gpu(ast);