Skip to content

Commit fb5e19d

Browse files
en4bzzackr
authored andcommitted
drm/vmwgfx: 3D disabled should not effect STDU memory limits
This limit became a hard cap starting with the change referenced below. Surface creation on the device will fail if the requested size is larger than this limit so altering the value arbitrarily will expose modes that are too large for the device's hard limits. Fixes: 7ebb47c ("drm/vmwgfx: Read new register for GB memory when available") Signed-off-by: Ian Forbes <[email protected]> Signed-off-by: Zack Rusin <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 4268269 commit fb5e19d

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

drivers/gpu/drm/vmwgfx/vmwgfx_drv.c

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -960,13 +960,6 @@ static int vmw_driver_load(struct vmw_private *dev_priv, u32 pci_id)
960960
vmw_read(dev_priv,
961961
SVGA_REG_SUGGESTED_GBOBJECT_MEM_SIZE_KB);
962962

963-
/*
964-
* Workaround for low memory 2D VMs to compensate for the
965-
* allocation taken by fbdev
966-
*/
967-
if (!(dev_priv->capabilities & SVGA_CAP_3D))
968-
mem_size *= 3;
969-
970963
dev_priv->max_mob_pages = mem_size * 1024 / PAGE_SIZE;
971964
dev_priv->max_primary_mem =
972965
vmw_read(dev_priv, SVGA_REG_MAX_PRIMARY_MEM);

0 commit comments

Comments
 (0)