summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/ast/ast_drv.c
diff options
context:
space:
mode:
authorThomas Zimmermann <tzimmermann@suse.de>2025-09-22 11:36:07 +0300
committerThomas Zimmermann <tzimmermann@suse.de>2025-09-29 14:28:12 +0300
commit6ee51e5c72cf45bd70638ce7fe6e3906148c1fcf (patch)
treeb03fd15f2a90a876d457d5d1b96e0654e722ea6a /drivers/gpu/drm/ast/ast_drv.c
parent095afdc53354cfba6223335d2fff8f3b8aa45c34 (diff)
downloadlinux-6ee51e5c72cf45bd70638ce7fe6e3906148c1fcf.tar.xz
drm/ast: Move Gen3 device initialization into separate helper
Split off device initialization for Gen3 hardware into the helpers ast_2200_device_create() and ast_2200_detect_wide_screen(). The new functions are duplicates of their counterparts in ast_main.c, but stripped from most non-Gen3 support. Simplifies maintenance as the driver's number of supported hardware generations grows. v2: - simplify widescreen-detection logic Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Link: https://lore.kernel.org/r/20250922083708.45564-8-tzimmermann@suse.de
Diffstat (limited to 'drivers/gpu/drm/ast/ast_drv.c')
-rw-r--r--drivers/gpu/drm/ast/ast_drv.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/ast/ast_drv.c b/drivers/gpu/drm/ast/ast_drv.c
index bcf0b318b495..caf41c31cc9d 100644
--- a/drivers/gpu/drm/ast/ast_drv.c
+++ b/drivers/gpu/drm/ast/ast_drv.c
@@ -390,6 +390,10 @@ static int ast_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
drm = ast_2100_device_create(pdev, &ast_driver, chip, config_mode,
regs, ioregs, need_post);
break;
+ case 3:
+ drm = ast_2200_device_create(pdev, &ast_driver, chip, config_mode,
+ regs, ioregs, need_post);
+ break;
default:
drm = ast_device_create(pdev, &ast_driver, chip, config_mode, regs, ioregs,
need_post);