From 1f3c4dd938a1710d762bac37dfb1b17c90af4732 Mon Sep 17 00:00:00 2001
From: Robert Noland <rnoland@2hip.net>
Date: Wed, 20 Aug 2008 17:15:46 -0400
Subject: i915: Free dev->dev_private on unload.

---
 shared-core/i915_dma.c | 2 ++
 1 file changed, 2 insertions(+)

(limited to 'shared-core')

diff --git a/shared-core/i915_dma.c b/shared-core/i915_dma.c
index 34d9355d..84aafaae 100644
--- a/shared-core/i915_dma.c
+++ b/shared-core/i915_dma.c
@@ -1114,6 +1114,8 @@ int i915_driver_unload(struct drm_device *dev)
 
 	drm_free(dev->dev_private, sizeof(drm_i915_private_t),
 		 DRM_MEM_DRIVER);
+	dev->dev_private = NULL;
+
 #ifdef __linux__
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25)
 	intel_fini_chipset_flush_compat(dev);
-- 
cgit v1.2.3