diff options
author | Thomas Zimmermann <tzimmermann@suse.de> | 2022-06-01 14:25:16 +0300 |
---|---|---|
committer | Thomas Zimmermann <tzimmermann@suse.de> | 2022-06-07 10:39:51 +0300 |
commit | d45e32c9d98ce7c22a4bafe69cee58165b59533b (patch) | |
tree | 0479e9f3cb16036722eb011b6c73c192530b5a35 /drivers/gpu/drm/mgag200/mgag200_g200ev.c | |
parent | ce19021fd99ab2c915f2b44b0df39bef75f11d18 (diff) | |
download | linux-d45e32c9d98ce7c22a4bafe69cee58165b59533b.tar.xz |
drm/mgag200: Call mgag200_device_probe_vram() from per-model init
Call mgag200_device_probe_vram() from each model's initializer. The
G200EW3 uses a special helper with additional instructions.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com>
Tested-by: Jocelyn Falempe <jfalempe@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220601112522.5774-5-tzimmermann@suse.de
Diffstat (limited to 'drivers/gpu/drm/mgag200/mgag200_g200ev.c')
-rw-r--r-- | drivers/gpu/drm/mgag200/mgag200_g200ev.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/mgag200/mgag200_g200ev.c b/drivers/gpu/drm/mgag200/mgag200_g200ev.c index e55dd01ed42e..ff3c7b17ac44 100644 --- a/drivers/gpu/drm/mgag200/mgag200_g200ev.c +++ b/drivers/gpu/drm/mgag200/mgag200_g200ev.c @@ -15,6 +15,7 @@ struct mga_device *mgag200_g200ev_device_create(struct pci_dev *pdev, const stru { struct mga_device *mdev; struct drm_device *dev; + resource_size_t vram_available; int ret; mdev = devm_drm_dev_alloc(&pdev->dev, drv, struct mga_device, base); @@ -39,7 +40,9 @@ struct mga_device *mgag200_g200ev_device_create(struct pci_dev *pdev, const stru if (ret) return ERR_PTR(ret); - ret = mgag200_modeset_init(mdev); + vram_available = mgag200_device_probe_vram(mdev); + + ret = mgag200_modeset_init(mdev, vram_available); if (ret) return ERR_PTR(ret); |