[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20210409125151.9520-1-linqiheng@huawei.com>
Date: Fri, 9 Apr 2021 20:51:51 +0800
From: Qiheng Lin <linqiheng@...wei.com>
To: <airlied@...ux.ie>, <daniel@...ll.ch>
CC: <jani.nikula@...ux.intel.com>, <joonas.lahtinen@...ux.intel.com>,
<rodrigo.vivi@...el.com>, <intel-gfx@...ts.freedesktop.org>,
<dri-devel@...ts.freedesktop.org>, <linux-kernel@...r.kernel.org>,
Qiheng Lin <linqiheng@...wei.com>
Subject: [PATCH -next] drm/i915/display: remove redundant NULL check
Fix the following coccicheck warning:
drivers/gpu/drm/i915/display/intel_psr.c:1530:29-31: WARNING
!A || A && B is equivalent to !A || B
Signed-off-by: Qiheng Lin <linqiheng@...wei.com>
---
drivers/gpu/drm/i915/display/intel_psr.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c
index 32d3d56259c2..4cec6b4d7fb9 100644
--- a/drivers/gpu/drm/i915/display/intel_psr.c
+++ b/drivers/gpu/drm/i915/display/intel_psr.c
@@ -1526,8 +1526,7 @@ void intel_psr_wait_for_idle(const struct intel_crtc_state *new_crtc_state)
u32 psr_status;
mutex_lock(&intel_dp->psr.lock);
- if (!intel_dp->psr.enabled ||
- (intel_dp->psr.enabled && intel_dp->psr.psr2_enabled)) {
+ if (!intel_dp->psr.enabled || intel_dp->psr.psr2_enabled) {
mutex_unlock(&intel_dp->psr.lock);
continue;
}
--
2.31.1
Powered by blists - more mailing lists