drm/i915/gvt: Fix the kernel null pointer error
authorfred gao <fred.gao@intel.com>
Wed, 16 Aug 2017 07:48:03 +0000 (15:48 +0800)
committerZhenyu Wang <zhenyuw@linux.intel.com>
Wed, 23 Aug 2017 06:08:57 +0000 (14:08 +0800)
commitffeaf9aaf97b4bdaf114d6df52f800d71918768c
tree346dde7bc87ad691ac5b2a438b91a82fe3ad42e4
parentd6086598d34e1cf9091c7be201f5b2041dc6203e
drm/i915/gvt: Fix the kernel null pointer error

once error happens in shadow_indirect_ctx function, the variable
wa_ctx->indirect_ctx.obj is not initialized but accessed, so the
kernel null point panic occurs.

Fixes: 894cf7d15634 ("drm/i915/gvt: i915_gem_object_create() returns an error pointer")
Cc: stable@vger.kernel.org # v4.8+
Signed-off-by: fred gao <fred.gao@intel.com>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
drivers/gpu/drm/i915/gvt/cmd_parser.c