Lines Matching full:edp
7 #include "edp.h"
11 struct msm_edp *edp = dev_id; in edp_irq() local
13 /* Process eDP irq */ in edp_irq()
14 return msm_edp_ctrl_irq(edp->ctrl); in edp_irq()
19 struct msm_edp *edp = platform_get_drvdata(pdev); in edp_destroy() local
21 if (!edp) in edp_destroy()
24 if (edp->ctrl) { in edp_destroy()
25 msm_edp_ctrl_destroy(edp->ctrl); in edp_destroy()
26 edp->ctrl = NULL; in edp_destroy()
32 /* construct eDP at bind/probe time, grab all the resources. */
35 struct msm_edp *edp = NULL; in edp_init() local
39 pr_err("no eDP device\n"); in edp_init()
44 edp = devm_kzalloc(&pdev->dev, sizeof(*edp), GFP_KERNEL); in edp_init()
45 if (!edp) { in edp_init()
49 DBG("eDP probed=%p", edp); in edp_init()
51 edp->pdev = pdev; in edp_init()
52 platform_set_drvdata(pdev, edp); in edp_init()
54 ret = msm_edp_ctrl_init(edp); in edp_init()
58 return edp; in edp_init()
61 if (edp) in edp_init()
71 struct msm_edp *edp; in edp_bind() local
74 edp = edp_init(to_platform_device(dev)); in edp_bind()
75 if (IS_ERR(edp)) in edp_bind()
76 return PTR_ERR(edp); in edp_bind()
77 priv->edp = edp; in edp_bind()
88 if (priv->edp) { in edp_unbind()
90 priv->edp = NULL; in edp_unbind()
113 { .compatible = "qcom,mdss-edp" },
139 int msm_edp_modeset_init(struct msm_edp *edp, struct drm_device *dev, in msm_edp_modeset_init() argument
142 struct platform_device *pdev = edp->pdev; in msm_edp_modeset_init()
146 edp->encoder = encoder; in msm_edp_modeset_init()
147 edp->dev = dev; in msm_edp_modeset_init()
149 edp->bridge = msm_edp_bridge_init(edp); in msm_edp_modeset_init()
150 if (IS_ERR(edp->bridge)) { in msm_edp_modeset_init()
151 ret = PTR_ERR(edp->bridge); in msm_edp_modeset_init()
152 DRM_DEV_ERROR(dev->dev, "failed to create eDP bridge: %d\n", ret); in msm_edp_modeset_init()
153 edp->bridge = NULL; in msm_edp_modeset_init()
157 edp->connector = msm_edp_connector_init(edp); in msm_edp_modeset_init()
158 if (IS_ERR(edp->connector)) { in msm_edp_modeset_init()
159 ret = PTR_ERR(edp->connector); in msm_edp_modeset_init()
160 DRM_DEV_ERROR(dev->dev, "failed to create eDP connector: %d\n", ret); in msm_edp_modeset_init()
161 edp->connector = NULL; in msm_edp_modeset_init()
165 edp->irq = irq_of_parse_and_map(pdev->dev.of_node, 0); in msm_edp_modeset_init()
166 if (edp->irq < 0) { in msm_edp_modeset_init()
167 ret = edp->irq; in msm_edp_modeset_init()
172 ret = devm_request_irq(&pdev->dev, edp->irq, in msm_edp_modeset_init()
174 "edp_isr", edp); in msm_edp_modeset_init()
177 edp->irq, ret); in msm_edp_modeset_init()
181 priv->bridges[priv->num_bridges++] = edp->bridge; in msm_edp_modeset_init()
182 priv->connectors[priv->num_connectors++] = edp->connector; in msm_edp_modeset_init()
188 if (edp->bridge) { in msm_edp_modeset_init()
189 edp_bridge_destroy(edp->bridge); in msm_edp_modeset_init()
190 edp->bridge = NULL; in msm_edp_modeset_init()
192 if (edp->connector) { in msm_edp_modeset_init()
193 edp->connector->funcs->destroy(edp->connector); in msm_edp_modeset_init()
194 edp->connector = NULL; in msm_edp_modeset_init()