Commit 90af89b9 authored by Ben Skeggs's avatar Ben Skeggs
Browse files

drm/nouveau: fix a nouveau_bo dereference after it's been destroyed

Signed-off-by: default avatarBen Skeggs <>
parent de1f46a4
......@@ -160,11 +160,11 @@ nouveau_bo_new(struct drm_device *dev, struct nouveau_channel *chan,
ret = ttm_bo_init(&dev_priv->ttm.bdev, &nvbo->bo, size,
ttm_bo_type_device, &nvbo->placement, align, 0,
false, NULL, size, nouveau_bo_del_ttm);
nvbo->channel = NULL;
if (ret) {
/* ttm will call nouveau_bo_del_ttm if it fails.. */
return ret;
nvbo->channel = NULL;
list_add_tail(&nvbo->head, &dev_priv->ttm.bo_list);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment