Lines Matching +full:in +full:-
1 // SPDX-License-Identifier: GPL-2.0-only
21 struct omap_dss_device *in; member
36 struct omap_dss_device *in = ddata->in; in tpd_connect() local
39 r = in->ops.hdmi->connect(in, dssdev); in tpd_connect()
43 dst->src = dssdev; in tpd_connect()
44 dssdev->dst = dst; in tpd_connect()
46 if (ddata->ct_cp_hpd_gpio) { in tpd_connect()
47 gpiod_set_value_cansleep(ddata->ct_cp_hpd_gpio, 1); in tpd_connect()
48 /* DC-DC converter needs at max 300us to get to 90% of 5V */ in tpd_connect()
59 struct omap_dss_device *in = ddata->in; in tpd_disconnect() local
61 WARN_ON(dst != dssdev->dst); in tpd_disconnect()
63 if (dst != dssdev->dst) in tpd_disconnect()
66 gpiod_set_value_cansleep(ddata->ct_cp_hpd_gpio, 0); in tpd_disconnect()
68 dst->src = NULL; in tpd_disconnect()
69 dssdev->dst = NULL; in tpd_disconnect()
71 in->ops.hdmi->disconnect(in, &ddata->dssdev); in tpd_disconnect()
77 struct omap_dss_device *in = ddata->in; in tpd_enable() local
80 if (dssdev->state == OMAP_DSS_DISPLAY_ACTIVE) in tpd_enable()
83 in->ops.hdmi->set_timings(in, &ddata->timings); in tpd_enable()
85 r = in->ops.hdmi->enable(in); in tpd_enable()
89 dssdev->state = OMAP_DSS_DISPLAY_ACTIVE; in tpd_enable()
97 struct omap_dss_device *in = ddata->in; in tpd_disable() local
99 if (dssdev->state != OMAP_DSS_DISPLAY_ACTIVE) in tpd_disable()
102 in->ops.hdmi->disable(in); in tpd_disable()
104 dssdev->state = OMAP_DSS_DISPLAY_DISABLED; in tpd_disable()
111 struct omap_dss_device *in = ddata->in; in tpd_set_timings() local
113 ddata->timings = *timings; in tpd_set_timings()
114 dssdev->panel.timings = *timings; in tpd_set_timings()
116 in->ops.hdmi->set_timings(in, timings); in tpd_set_timings()
124 *timings = ddata->timings; in tpd_get_timings()
131 struct omap_dss_device *in = ddata->in; in tpd_check_timings() local
134 r = in->ops.hdmi->check_timings(in, timings); in tpd_check_timings()
143 struct omap_dss_device *in = ddata->in; in tpd_read_edid() local
146 if (!gpiod_get_value_cansleep(ddata->hpd_gpio)) in tpd_read_edid()
147 return -ENODEV; in tpd_read_edid()
149 gpiod_set_value_cansleep(ddata->ls_oe_gpio, 1); in tpd_read_edid()
151 r = in->ops.hdmi->read_edid(in, edid, len); in tpd_read_edid()
153 gpiod_set_value_cansleep(ddata->ls_oe_gpio, 0); in tpd_read_edid()
162 return gpiod_get_value_cansleep(ddata->hpd_gpio); in tpd_detect()
169 struct omap_dss_device *in = ddata->in; in tpd_set_infoframe() local
171 return in->ops.hdmi->set_infoframe(in, avi); in tpd_set_infoframe()
178 struct omap_dss_device *in = ddata->in; in tpd_set_hdmi_mode() local
180 return in->ops.hdmi->set_hdmi_mode(in, hdmi_mode); in tpd_set_hdmi_mode()
203 struct device_node *node = pdev->dev.of_node; in tpd_probe_of()
204 struct omap_dss_device *in; in tpd_probe_of() local
206 in = omapdss_of_find_source_for_first_ep(node); in tpd_probe_of()
207 if (IS_ERR(in)) { in tpd_probe_of()
208 dev_err(&pdev->dev, "failed to find video source\n"); in tpd_probe_of()
209 return PTR_ERR(in); in tpd_probe_of()
212 ddata->in = in; in tpd_probe_of()
224 ddata = devm_kzalloc(&pdev->dev, sizeof(*ddata), GFP_KERNEL); in tpd_probe()
226 return -ENOMEM; in tpd_probe()
230 if (pdev->dev.of_node) { in tpd_probe()
235 return -ENODEV; in tpd_probe()
238 gpio = devm_gpiod_get_index_optional(&pdev->dev, NULL, 0, in tpd_probe()
245 ddata->ct_cp_hpd_gpio = gpio; in tpd_probe()
247 gpio = devm_gpiod_get_index_optional(&pdev->dev, NULL, 1, in tpd_probe()
254 ddata->ls_oe_gpio = gpio; in tpd_probe()
256 gpio = devm_gpiod_get_index(&pdev->dev, NULL, 2, in tpd_probe()
263 ddata->hpd_gpio = gpio; in tpd_probe()
265 dssdev = &ddata->dssdev; in tpd_probe()
266 dssdev->ops.hdmi = &tpd_hdmi_ops; in tpd_probe()
267 dssdev->dev = &pdev->dev; in tpd_probe()
268 dssdev->type = OMAP_DISPLAY_TYPE_HDMI; in tpd_probe()
269 dssdev->output_type = OMAP_DISPLAY_TYPE_HDMI; in tpd_probe()
270 dssdev->owner = THIS_MODULE; in tpd_probe()
271 dssdev->port_num = 1; in tpd_probe()
275 dev_err(&pdev->dev, "Failed to register output\n"); in tpd_probe()
282 omap_dss_put_device(ddata->in); in tpd_probe()
289 struct omap_dss_device *dssdev = &ddata->dssdev; in tpd_remove()
290 struct omap_dss_device *in = ddata->in; in tpd_remove() local
292 omapdss_unregister_output(&ddata->dssdev); in tpd_remove()
300 tpd_disconnect(dssdev, dssdev->dst); in tpd_remove()
302 omap_dss_put_device(in); in tpd_remove()