drm/radeon/vm: don't attempt to update ptes if ib allocation fails
authorAlex Deucher <alexander.deucher@amd.com>
Wed, 13 Nov 2013 20:25:35 +0000 (15:25 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 4 Dec 2013 18:57:30 +0000 (10:57 -0800)
commit7c5f3874d9d697f9e21acbdd8be9e65af6f5a880
tree40432ae86f6361dbf9ebd55be89a5b3f55d0d1be
parenta6647e9e4bdd231a008a12302d008a6cd81596bf
drm/radeon/vm: don't attempt to update ptes if ib allocation fails

commit 4cc948b94a222c310ae089c36718aac7a03aec90 upstream.

If we fail to allocate an indirect buffer (ib) when updating
the ptes, return an error instead of trying to use the ib.
Avoids a null pointer dereference.

Bug:
https://bugzilla.kernel.org/show_bug.cgi?id=58621

v2 (chk): rebased on drm-fixes-3.12 for stable inclusion

Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/radeon/radeon_gart.c