diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2017-02-07 15:53:07 +0100 |
---|---|---|
committer | Zhenyu Wang <zhenyuw@linux.intel.com> | 2017-02-08 06:11:22 +0100 |
commit | 5bf63fb40eacb7ed1f1de70ae30a597313fa9960 (patch) | |
tree | aee3d13ba3e09b42f6118f0b81a99cb91e8dddc6 /drivers/gpu/drm/i915 | |
parent | drm/i915/gvt: fix vgpu type size init (diff) | |
download | linux-5bf63fb40eacb7ed1f1de70ae30a597313fa9960.tar.xz linux-5bf63fb40eacb7ed1f1de70ae30a597313fa9960.zip |
drm/i915/gvt/kvmgt: remove some dead code
"caps.buf" is always NULL here and "caps.size" is always zero. The code
is a no-op and can be removed.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915')
-rw-r--r-- | drivers/gpu/drm/i915/gvt/kvmgt.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/gpu/drm/i915/gvt/kvmgt.c b/drivers/gpu/drm/i915/gvt/kvmgt.c index 080ca77abd22..b49a01d85dde 100644 --- a/drivers/gpu/drm/i915/gvt/kvmgt.c +++ b/drivers/gpu/drm/i915/gvt/kvmgt.c @@ -965,11 +965,6 @@ static long intel_vgpu_ioctl(struct mdev_device *mdev, unsigned int cmd, sparse->areas[0].offset = PAGE_ALIGN(vgpu_aperture_offset(vgpu)); sparse->areas[0].size = vgpu_aperture_sz(vgpu); - if (!caps.buf) { - kfree(caps.buf); - caps.buf = NULL; - caps.size = 0; - } break; case VFIO_PCI_BAR3_REGION_INDEX ... VFIO_PCI_BAR5_REGION_INDEX: |