summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesper Juhl <jj@chaosbits.net>2012-04-09 22:49:57 +0200
committerJiri Kosina <jkosina@suse.cz>2012-04-30 13:15:31 +0200
commitc69a6ca1a4e398e7e85cab792ddbd874d9335233 (patch)
tree644bc66b8acdac1b54bf272bc9a809dc33947b2b
parent42a6bd2006c922143cee8d9ec7c4e27526d4d2a3 (diff)
radeon_cp: Remove unneeded tests for NULL before calling release_firmware()
release_firmware() does its own tests for NULL pointers so there's no need to explicitly test before calling it. Signed-off-by: Jesper Juhl <jj@chaosbits.net> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
-rw-r--r--drivers/gpu/drm/radeon/radeon_cp.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_cp.c b/drivers/gpu/drm/radeon/radeon_cp.c
index 0ebb7d4796f..ef67e181377 100644
--- a/drivers/gpu/drm/radeon/radeon_cp.c
+++ b/drivers/gpu/drm/radeon/radeon_cp.c
@@ -1827,14 +1827,10 @@ void radeon_do_release(struct drm_device * dev)
r600_do_cleanup_cp(dev);
else
radeon_do_cleanup_cp(dev);
- if (dev_priv->me_fw) {
- release_firmware(dev_priv->me_fw);
- dev_priv->me_fw = NULL;
- }
- if (dev_priv->pfp_fw) {
- release_firmware(dev_priv->pfp_fw);
- dev_priv->pfp_fw = NULL;
- }
+ release_firmware(dev_priv->me_fw);
+ dev_priv->me_fw = NULL;
+ release_firmware(dev_priv->pfp_fw);
+ dev_priv->pfp_fw = NULL;
}
}