drm/radeon: fix regression in UMS CS ioctl
authorAlex Deucher <alexander.deucher@amd.com>
Wed, 30 May 2012 14:09:30 +0000 (10:09 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 9 Jun 2012 15:36:13 +0000 (00:36 +0900)
commit44920b1991d9182bc3ff8f90df71b0e5311448dc
tree9c690c224456a44b0d1f9dd27afda1afe55f07cf
parent1e98ce80a4493f32b44f227d6050318462ca9d5d
drm/radeon: fix regression in UMS CS ioctl

commit 9b00147d9f2ba137ce74b66b768a8312be0b6781 upstream.

radeon_cs_parser_init is called by both the legacy UMS
CS ioctl and the KMS CS ioctl.  Protect KMS specific
pieces of the code by checking that rdev is not NULL.

Reported-by: Michael Burian <michael.burian@sbg.at>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/radeon/radeon_cs.c