Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Nov 2013 19:10:28 +0000 (UTC)
From:      Jean-Sebastien Pedron <dumbbell@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r258062 - in stable/10/sys/dev/drm2: . radeon
Message-ID:  <201311121910.rACJASHU066884@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dumbbell
Date: Tue Nov 12 19:10:28 2013
New Revision: 258062
URL: http://svnweb.freebsd.org/changeset/base/258062

Log:
  MFC r257869:
  
  drm: Initialize "handle" to 0 before calling drm_gem_handle_create()
  
  This is variable is being checked in drm_gem_name_create() before being
  set.
  
  Approved by:	re (delphij)

Modified:
  stable/10/sys/dev/drm2/drm_crtc.c
  stable/10/sys/dev/drm2/radeon/radeon_gem.c
Directory Properties:
  stable/10/sys/   (props changed)

Modified: stable/10/sys/dev/drm2/drm_crtc.c
==============================================================================
--- stable/10/sys/dev/drm2/drm_crtc.c	Tue Nov 12 18:59:23 2013	(r258061)
+++ stable/10/sys/dev/drm2/drm_crtc.c	Tue Nov 12 19:10:28 2013	(r258062)
@@ -2317,6 +2317,7 @@ int drm_mode_getfb(struct drm_device *de
 	r->depth = fb->depth;
 	r->bpp = fb->bits_per_pixel;
 	r->pitch = fb->pitches[0];
+	r->handle = 0;
 	fb->funcs->create_handle(fb, file_priv, &r->handle);
 
 out:

Modified: stable/10/sys/dev/drm2/radeon/radeon_gem.c
==============================================================================
--- stable/10/sys/dev/drm2/radeon/radeon_gem.c	Tue Nov 12 18:59:23 2013	(r258061)
+++ stable/10/sys/dev/drm2/radeon/radeon_gem.c	Tue Nov 12 19:10:28 2013	(r258062)
@@ -567,6 +567,7 @@ int radeon_mode_dumb_create(struct drm_f
 	if (r)
 		return -ENOMEM;
 
+	handle = 0;
 	r = drm_gem_handle_create(file_priv, gobj, &handle);
 	/* drop reference from allocate - handle holds it now */
 	drm_gem_object_unreference_unlocked(gobj);



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