Merge tag 'vmwgfx-next-4.19-3' of git://people.freedesktop.org/~thomash/linux into drm-next
This introduces a header update and support for multisample surfaces. Signed-off-by: Dave Airlie <airlied@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/d020efb8-776d-5e8f-9d9f-122591e074d6@vmware.com
This commit is contained in:
@@ -56,6 +56,9 @@ int vmw_getparam_ioctl(struct drm_device *dev, void *data,
|
||||
case DRM_VMW_PARAM_HW_CAPS:
|
||||
param->value = dev_priv->capabilities;
|
||||
break;
|
||||
case DRM_VMW_PARAM_HW_CAPS2:
|
||||
param->value = dev_priv->capabilities2;
|
||||
break;
|
||||
case DRM_VMW_PARAM_FIFO_CAPS:
|
||||
param->value = dev_priv->fifo.capabilities;
|
||||
break;
|
||||
@@ -113,6 +116,9 @@ int vmw_getparam_ioctl(struct drm_device *dev, void *data,
|
||||
case DRM_VMW_PARAM_DX:
|
||||
param->value = dev_priv->has_dx;
|
||||
break;
|
||||
case DRM_VMW_PARAM_SM4_1:
|
||||
param->value = dev_priv->has_sm4_1;
|
||||
break;
|
||||
default:
|
||||
return -EINVAL;
|
||||
}
|
||||
@@ -122,15 +128,12 @@ int vmw_getparam_ioctl(struct drm_device *dev, void *data,
|
||||
|
||||
static u32 vmw_mask_multisample(unsigned int cap, u32 fmt_value)
|
||||
{
|
||||
/* If the header is updated, update the format test as well! */
|
||||
BUILD_BUG_ON(SVGA3D_DEVCAP_DXFMT_BC5_UNORM + 1 != SVGA3D_DEVCAP_MAX);
|
||||
|
||||
if (cap >= SVGA3D_DEVCAP_DXFMT_X8R8G8B8 &&
|
||||
cap <= SVGA3D_DEVCAP_DXFMT_BC5_UNORM)
|
||||
fmt_value &= ~(SVGADX_DXFMT_MULTISAMPLE_2 |
|
||||
SVGADX_DXFMT_MULTISAMPLE_4 |
|
||||
SVGADX_DXFMT_MULTISAMPLE_8);
|
||||
else if (cap == SVGA3D_DEVCAP_MULTISAMPLE_MASKABLESAMPLES)
|
||||
/*
|
||||
* A version of user-space exists which use MULTISAMPLE_MASKABLESAMPLES
|
||||
* to check the sample count supported by virtual device. Since there
|
||||
* never was support for multisample count for backing MOB return 0.
|
||||
*/
|
||||
if (cap == SVGA3D_DEVCAP_MULTISAMPLE_MASKABLESAMPLES)
|
||||
return 0;
|
||||
|
||||
return fmt_value;
|
||||
|
Reference in New Issue
Block a user