diff options
| author | Zack Rusin <zack.rusin@broadcom.com> | 2024-04-11 22:55:07 -0400 |
|---|---|---|
| committer | Zack Rusin <zack.rusin@broadcom.com> | 2024-04-15 13:32:18 -0400 |
| commit | cd2eb57df1b8bbac90daad622b2f1ef00640c38c (patch) | |
| tree | 3c833c4ee7afaa845175776844f60e171874fe53 /drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | |
| parent | bfc7bc539392f681194de341dd2bb9e83f31f588 (diff) | |
| download | linux-cd2eb57df1b8bbac90daad622b2f1ef00640c38c.tar.gz linux-cd2eb57df1b8bbac90daad622b2f1ef00640c38c.tar.bz2 linux-cd2eb57df1b8bbac90daad622b2f1ef00640c38c.zip | |
drm/vmwgfx: Implement virtual kms
By default vmwgfx doesn't support vblanking or crc generation which
makes it impossible to use various IGT tests to validate vmwgfx.
Implement virtual kernel mode setting, which is mainly related to
simulated vblank support.
Code is very similar to amd's vkms and the vkms module itself, except
that it's integrated with vmwgfx three different output technologies -
legacy, screen object and screen targets.
Make IGT's kms_vblank pass on vmwgfx and allows a lot of other IGT
tests to run with vmwgfx.
Support for vkms needs to be manually enabled by adding:
guestinfo.vmwgfx.vkms_enable = "TRUE"
somewhere in the vmx file, otherwise it's off by default.
Signed-off-by: Zack Rusin <zack.rusin@broadcom.com>
Acked-by: Martin Krastev <martin.krastev@broadcom.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240412025511.78553-2-zack.rusin@broadcom.com
Diffstat (limited to 'drivers/gpu/drm/vmwgfx/vmwgfx_drv.c')
| -rw-r--r-- | drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c index c7d90f96d16a..e34c48fd25d4 100644 --- a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c @@ -32,6 +32,7 @@ #include "vmwgfx_binding.h" #include "vmwgfx_devcaps.h" #include "vmwgfx_mksstat.h" +#include "vmwgfx_vkms.h" #include "ttm_object.h" #include <drm/drm_aperture.h> @@ -910,6 +911,8 @@ static int vmw_driver_load(struct vmw_private *dev_priv, u32 pci_id) "Please switch to a supported graphics device to avoid problems."); } + vmw_vkms_init(dev_priv); + ret = vmw_dma_select_mode(dev_priv); if (unlikely(ret != 0)) { drm_info(&dev_priv->drm, |
