diff options
Diffstat (limited to 'drivers/gpu/drm/i915/i915_dma.c')
-rw-r--r-- | drivers/gpu/drm/i915/i915_dma.c | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index 2b9725f7bf2c..f221631cdc86 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c | |||
@@ -1827,19 +1827,11 @@ int i915_driver_unload(struct drm_device *dev) | |||
1827 | 1827 | ||
1828 | int i915_driver_open(struct drm_device *dev, struct drm_file *file) | 1828 | int i915_driver_open(struct drm_device *dev, struct drm_file *file) |
1829 | { | 1829 | { |
1830 | struct drm_i915_file_private *file_priv; | 1830 | int ret; |
1831 | |||
1832 | DRM_DEBUG_DRIVER("\n"); | ||
1833 | file_priv = kzalloc(sizeof(*file_priv), GFP_KERNEL); | ||
1834 | if (!file_priv) | ||
1835 | return -ENOMEM; | ||
1836 | |||
1837 | file->driver_priv = file_priv; | ||
1838 | |||
1839 | spin_lock_init(&file_priv->mm.lock); | ||
1840 | INIT_LIST_HEAD(&file_priv->mm.request_list); | ||
1841 | 1831 | ||
1842 | idr_init(&file_priv->context_idr); | 1832 | ret = i915_gem_open(dev, file); |
1833 | if (ret) | ||
1834 | return ret; | ||
1843 | 1835 | ||
1844 | return 0; | 1836 | return 0; |
1845 | } | 1837 | } |