summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/msm
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2016-07-13 18:54:11 +0200
committerRob Clark <robdclark@gmail.com>2016-07-16 10:29:33 -0400
commit851dd75d64dbfc9a97d5109659e82e95d6bbe5bf (patch)
treee98d32200865cd176f4f79b9da8dcbbe7c3fb4a5 /drivers/gpu/drm/msm
parent5745d21f9a92fa3b70149df69574a13becc3d53e (diff)
downloadop-kernel-dev-851dd75d64dbfc9a97d5109659e82e95d6bbe5bf.zip
op-kernel-dev-851dd75d64dbfc9a97d5109659e82e95d6bbe5bf.tar.gz
drm/msm/hdmi: Delete an unnecessary check before the function call "kfree"
The kfree() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Rob Clark <robdclark@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/msm')
-rw-r--r--drivers/gpu/drm/msm/hdmi/hdmi_hdcp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/msm/hdmi/hdmi_hdcp.c b/drivers/gpu/drm/msm/hdmi/hdmi_hdcp.c
index 0baaaaa..6e76797 100644
--- a/drivers/gpu/drm/msm/hdmi/hdmi_hdcp.c
+++ b/drivers/gpu/drm/msm/hdmi/hdmi_hdcp.c
@@ -1430,7 +1430,7 @@ struct hdmi_hdcp_ctrl *msm_hdmi_hdcp_init(struct hdmi *hdmi)
void msm_hdmi_hdcp_destroy(struct hdmi *hdmi)
{
- if (hdmi && hdmi->hdcp_ctrl) {
+ if (hdmi) {
kfree(hdmi->hdcp_ctrl);
hdmi->hdcp_ctrl = NULL;
}
OpenPOWER on IntegriCloud