summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/vmwgfx/vmwgfx_resource.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2020-10-06 03:06:41 +0300
committerDave Airlie <airlied@redhat.com>2020-10-07 08:41:49 +0300
commit279a3010218d517284641b7dac2d65c0ecef78ab (patch)
tree80b3a20427d4df07d147cd0054a1baf9d7ec06fa /drivers/gpu/drm/vmwgfx/vmwgfx_resource.c
parent881c4117957bc39390930f8344c600858a72179b (diff)
downloadlinux-279a3010218d517284641b7dac2d65c0ecef78ab.tar.xz
drm/vmwgfx: move null mem checks outside move notifies
Both fns checked mem == NULL, just move the check outside. Acked-by: Christian König <christian.koenig@amd.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20201006000644.1005758-3-airlied@gmail.com
Diffstat (limited to 'drivers/gpu/drm/vmwgfx/vmwgfx_resource.c')
-rw-r--r--drivers/gpu/drm/vmwgfx/vmwgfx_resource.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_resource.c b/drivers/gpu/drm/vmwgfx/vmwgfx_resource.c
index 5e922d9d5f2c..00b535831a7a 100644
--- a/drivers/gpu/drm/vmwgfx/vmwgfx_resource.c
+++ b/drivers/gpu/drm/vmwgfx/vmwgfx_resource.c
@@ -867,7 +867,7 @@ void vmw_query_move_notify(struct ttm_buffer_object *bo,
mutex_lock(&dev_priv->binding_mutex);
dx_query_mob = container_of(bo, struct vmw_buffer_object, base);
- if (mem == NULL || !dx_query_mob || !dx_query_mob->dx_query_ctx) {
+ if (!dx_query_mob || !dx_query_mob->dx_query_ctx) {
mutex_unlock(&dev_priv->binding_mutex);
return;
}