Commit 8b329486 authored by Dan Carpenter's avatar Dan Carpenter Committed by Archit Taneja

drm/bridge: adv7511: Fix a use after free

We free "edid", then use it again on the next line.

Fixes: 3b1b9750 ("drm: adv7511/33: add HDMI CEC support")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarArchit Taneja <architt@codeaurora.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20171017204343.zctliubjkq7imudi@mwanda
parent aaddb6d2
...@@ -607,10 +607,10 @@ static int adv7511_get_modes(struct adv7511 *adv7511, ...@@ -607,10 +607,10 @@ static int adv7511_get_modes(struct adv7511 *adv7511,
adv7511_set_config_csc(adv7511, connector, adv7511->rgb, adv7511_set_config_csc(adv7511, connector, adv7511->rgb,
drm_detect_hdmi_monitor(edid)); drm_detect_hdmi_monitor(edid));
kfree(edid);
cec_s_phys_addr_from_edid(adv7511->cec_adap, edid); cec_s_phys_addr_from_edid(adv7511->cec_adap, edid);
kfree(edid);
return count; return count;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment