diff options
| author | Mark Brown <broonie@kernel.org> | 2023-05-19 12:32:04 +0900 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2023-05-19 12:32:04 +0900 |
| commit | af53b00fa3aca3410c89900a34e5d727a27c36e2 (patch) | |
| tree | 1b51641988e0ae56f8de4a693ab3d1aecc5491d4 /drivers/gpu/drm/ast/ast_main.c | |
| parent | 98be58f2b517b212b57b8493dab92312a52614ac (diff) | |
| parent | f1fcbaa18b28dec10281551dfe6ed3a3ed80e3d6 (diff) | |
Merge tag 'v6.4-rc2' into asoc-6.5 to get fixes for CI
Linux 6.4-rc2
Diffstat (limited to 'drivers/gpu/drm/ast/ast_main.c')
| -rw-r--r-- | drivers/gpu/drm/ast/ast_main.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/gpu/drm/ast/ast_main.c b/drivers/gpu/drm/ast/ast_main.c index 794ffd4a29c5..f32ce29edba7 100644 --- a/drivers/gpu/drm/ast/ast_main.c +++ b/drivers/gpu/drm/ast/ast_main.c @@ -425,11 +425,12 @@ struct ast_device *ast_device_create(const struct drm_driver *drv, return ERR_PTR(-EIO); /* - * If we don't have IO space at all, use MMIO now and - * assume the chip has MMIO enabled by default (rev 0x20 - * and higher). + * After AST2500, MMIO is enabled by default, and it should be adopted + * to be compatible with Arm. */ - if (!(pci_resource_flags(pdev, 2) & IORESOURCE_IO)) { + if (pdev->revision >= 0x40) { + ast->ioregs = ast->regs + AST_IO_MM_OFFSET; + } else if (!(pci_resource_flags(pdev, 2) & IORESOURCE_IO)) { drm_info(dev, "platform has no IO space, trying MMIO\n"); ast->ioregs = ast->regs + AST_IO_MM_OFFSET; } |
