projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0766e2e
)
drm/i915/gvt: Avoid dereference a potential null pointer
author
Xinyun Liu
<xinyun.liu@intel.com>
Thu, 7 Jun 2018 14:48:40 +0000
(22:48 +0800)
committer
Zhenyu Wang
<zhenyuw@linux.intel.com>
Mon, 11 Jun 2018 07:03:36 +0000
(15:03 +0800)
Add sanity check for up_irq_info.
Signed-off-by: Xinyun Liu <xinyun.liu@intel.com>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
drivers/gpu/drm/i915/gvt/interrupt.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/i915/gvt/interrupt.c
b/drivers/gpu/drm/i915/gvt/interrupt.c
index
7a041b3
..
1d79596
100644
(file)
--- a/
drivers/gpu/drm/i915/gvt/interrupt.c
+++ b/
drivers/gpu/drm/i915/gvt/interrupt.c
@@
-350,7
+350,8
@@
static void update_upstream_irq(struct intel_vgpu *vgpu,
clear_bits |= (1 << bit);
}
- WARN_ON(!up_irq_info);
+ if (WARN_ON(!up_irq_info))
+ return;
if (up_irq_info->group == INTEL_GVT_IRQ_INFO_MASTER) {
u32 isr = i915_mmio_reg_offset(up_irq_info->reg_base);