summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2019-12-10 15:23:49 +0100
committerVille Syrjälä <ville.syrjala@linux.intel.com>2019-12-11 17:19:28 +0100
commitf3417d703f18b2bfe180e28cd65f44b540546d29 (patch)
tree72a53a0f137c0c0ef3931ced1c005a0f53a26956
parentdrm/i915/display: remove duplicated assignment to pointer crtc_state (diff)
downloadlinux-f3417d703f18b2bfe180e28cd65f44b540546d29.tar.xz
linux-f3417d703f18b2bfe180e28cd65f44b540546d29.zip
drm/i915: remove redundant checks for a null fb pointer
A prior check and return when pointer fb is null makes subsequent null checks on fb redundant. Remove the redundant null checks. Addresses-Coverity: ("Logically dead code") Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20191210142349.333171-1-colin.king@canonical.com
-rw-r--r--drivers/gpu/drm/i915/i915_debugfs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
index 6cb149ba1905..9cd5ce5bc93b 100644
--- a/drivers/gpu/drm/i915/i915_debugfs.c
+++ b/drivers/gpu/drm/i915/i915_debugfs.c
@@ -2582,8 +2582,8 @@ static void intel_plane_hw_info(struct seq_file *m, struct intel_plane *plane)
plane_state->hw.rotation);
seq_printf(m, "\t\thw: fb=%d,%s,%dx%d, visible=%s, src=" DRM_RECT_FP_FMT ", dst=" DRM_RECT_FMT ", rotation=%s\n",
- fb ? fb->base.id : 0, fb ? format_name.str : "n/a",
- fb ? fb->width : 0, fb ? fb->height : 0,
+ fb->base.id, format_name.str,
+ fb->width, fb->height,
yesno(plane_state->uapi.visible),
DRM_RECT_FP_ARG(&plane_state->uapi.src),
DRM_RECT_ARG(&plane_state->uapi.dst),