Commit acbb7f14 authored by Philipp Zabel's avatar Philipp Zabel

drm/imx: parallel-display: reduce scope of edid_len

The edid_len variable is never used again. Use a local variable instead
of storing it in the device structure.
Signed-off-by: default avatarPhilipp Zabel <p.zabel@pengutronix.de>
parent f433ff4d
......@@ -28,7 +28,6 @@ struct imx_parallel_display {
struct drm_bridge bridge;
struct device *dev;
void *edid;
int edid_len;
u32 bus_format;
u32 bus_flags;
struct drm_display_mode mode;
......@@ -305,6 +304,7 @@ static int imx_pd_bind(struct device *dev, struct device *master, void *data)
struct device_node *np = dev->of_node;
const u8 *edidp;
struct imx_parallel_display *imxpd;
int edid_len;
int ret;
u32 bus_format = 0;
const char *fmt;
......@@ -318,10 +318,9 @@ static int imx_pd_bind(struct device *dev, struct device *master, void *data)
if (ret && ret != -ENODEV)
return ret;
edidp = of_get_property(np, "edid", &imxpd->edid_len);
edidp = of_get_property(np, "edid", &edid_len);
if (edidp)
imxpd->edid = devm_kmemdup(dev, edidp, imxpd->edid_len,
GFP_KERNEL);
imxpd->edid = devm_kmemdup(dev, edidp, edid_len, GFP_KERNEL);
ret = of_property_read_string(np, "interface-pix-fmt", &fmt);
if (!ret) {
......
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