Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 851dd75d authored by Markus Elfring's avatar Markus Elfring Committed by Rob Clark
Browse files

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: default avatarMarkus Elfring <elfring@users.sourceforge.net>
Signed-off-by: default avatarRob Clark <robdclark@gmail.com>
parent 5745d21f
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -1430,7 +1430,7 @@ struct hdmi_hdcp_ctrl *msm_hdmi_hdcp_init(struct hdmi *hdmi)


void msm_hdmi_hdcp_destroy(struct hdmi *hdmi)
void msm_hdmi_hdcp_destroy(struct hdmi *hdmi)
{
{
	if (hdmi && hdmi->hdcp_ctrl) {
	if (hdmi) {
		kfree(hdmi->hdcp_ctrl);
		kfree(hdmi->hdcp_ctrl);
		hdmi->hdcp_ctrl = NULL;
		hdmi->hdcp_ctrl = NULL;
	}
	}