File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -426,11 +426,12 @@ struct ast_private *ast_device_create(const struct drm_driver *drv,
426
426
return ERR_PTR (- EIO );
427
427
428
428
/*
429
- * If we don't have IO space at all, use MMIO now and
430
- * assume the chip has MMIO enabled by default (rev 0x20
431
- * and higher).
429
+ * After AST2500, MMIO is enabled by default, and it should be adopted
430
+ * to be compatible with Arm.
432
431
*/
433
- if (!(pci_resource_flags (pdev , 2 ) & IORESOURCE_IO )) {
432
+ if (pdev -> revision >= 0x40 ) {
433
+ ast -> ioregs = ast -> regs + AST_IO_MM_OFFSET ;
434
+ } else if (!(pci_resource_flags (pdev , 2 ) & IORESOURCE_IO )) {
434
435
drm_info (dev , "platform has no IO space, trying MMIO\n" );
435
436
ast -> ioregs = ast -> regs + AST_IO_MM_OFFSET ;
436
437
}
You can’t perform that action at this time.
0 commit comments