Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 20 Jun 2009 16:37:24 +0000 (UTC)
From:      Robert Noland <rnoland@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r194537 - head/sys/dev/drm
Message-ID:  <200906201637.n5KGbOh2080978@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rnoland
Date: Sat Jun 20 16:37:24 2009
New Revision: 194537
URL: http://svn.freebsd.org/changeset/base/194537

Log:
  Don't panic if drm_rmmap is called with a NULL map pointer.
  
  MFC after:	3 days

Modified:
  head/sys/dev/drm/drm_bufs.c

Modified: head/sys/dev/drm/drm_bufs.c
==============================================================================
--- head/sys/dev/drm/drm_bufs.c	Sat Jun 20 16:30:32 2009	(r194536)
+++ head/sys/dev/drm/drm_bufs.c	Sat Jun 20 16:37:24 2009	(r194537)
@@ -296,6 +296,9 @@ void drm_rmmap(struct drm_device *dev, d
 {
 	DRM_SPINLOCK_ASSERT(&dev->dev_lock);
 
+	if (map == NULL)
+		return;
+
 	TAILQ_REMOVE(&dev->maplist, map, link);
 
 	switch (map->type) {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200906201637.n5KGbOh2080978>