Lines Matching refs:hdmi

44 static struct omap_hdmi hdmi;  variable
52 r = pm_runtime_get_sync(&hdmi.pdev->dev); in hdmi_runtime_get()
66 r = pm_runtime_put_sync(&hdmi.pdev->dev); in hdmi_runtime_put()
106 if (hdmi.vdda_reg != NULL) in hdmi_init_regulator()
109 reg = devm_regulator_get(&hdmi.pdev->dev, "vdda"); in hdmi_init_regulator()
126 hdmi.vdda_reg = reg; in hdmi_init_regulator()
135 r = regulator_enable(hdmi.vdda_reg); in hdmi_power_on_core()
146 hdmi.core_enabled = true; in hdmi_power_on_core()
151 regulator_disable(hdmi.vdda_reg); in hdmi_power_on_core()
158 hdmi.core_enabled = false; in hdmi_power_off_core()
161 regulator_disable(hdmi.vdda_reg); in hdmi_power_off_core()
168 struct omap_overlay_manager *mgr = hdmi.output.manager; in hdmi_power_on_full()
169 struct hdmi_wp_data *wp = &hdmi.wp; in hdmi_power_on_full()
180 p = &hdmi.cfg.timings; in hdmi_power_on_full()
184 hdmi_pll_compute(&hdmi.pll, p->pixelclock, &hdmi_cinfo); in hdmi_power_on_full()
186 r = dss_pll_enable(&hdmi.pll.pll); in hdmi_power_on_full()
192 r = dss_pll_set_config(&hdmi.pll.pll, &hdmi_cinfo); in hdmi_power_on_full()
198 r = hdmi_phy_configure(&hdmi.phy, hdmi_cinfo.clkdco, in hdmi_power_on_full()
209 hdmi4_configure(&hdmi.core, &hdmi.wp, &hdmi.cfg); in hdmi_power_on_full()
217 r = hdmi_wp_video_start(&hdmi.wp); in hdmi_power_on_full()
231 hdmi_wp_video_stop(&hdmi.wp); in hdmi_power_on_full()
233 hdmi_wp_set_phy_pwr(&hdmi.wp, HDMI_PHYPWRCMD_OFF); in hdmi_power_on_full()
237 dss_pll_disable(&hdmi.pll.pll); in hdmi_power_on_full()
245 struct omap_overlay_manager *mgr = hdmi.output.manager; in hdmi_power_off_full()
247 hdmi_wp_clear_irqenable(&hdmi.wp, 0xffffffff); in hdmi_power_off_full()
251 hdmi_wp_video_stop(&hdmi.wp); in hdmi_power_off_full()
253 hdmi_wp_set_phy_pwr(&hdmi.wp, HDMI_PHYPWRCMD_OFF); in hdmi_power_off_full()
255 dss_pll_disable(&hdmi.pll.pll); in hdmi_power_off_full()
263 struct omap_dss_device *out = &hdmi.output; in hdmi_display_check_timing()
274 mutex_lock(&hdmi.lock); in hdmi_display_set_timing()
276 hdmi.cfg.timings = *timings; in hdmi_display_set_timing()
280 mutex_unlock(&hdmi.lock); in hdmi_display_set_timing()
286 *timings = hdmi.cfg.timings; in hdmi_display_get_timings()
291 mutex_lock(&hdmi.lock); in hdmi_dump_regs()
294 mutex_unlock(&hdmi.lock); in hdmi_dump_regs()
298 hdmi_wp_dump(&hdmi.wp, s); in hdmi_dump_regs()
299 hdmi_pll_dump(&hdmi.pll, s); in hdmi_dump_regs()
300 hdmi_phy_dump(&hdmi.phy, s); in hdmi_dump_regs()
301 hdmi4_core_dump(&hdmi.core, s); in hdmi_dump_regs()
304 mutex_unlock(&hdmi.lock); in hdmi_dump_regs()
311 mutex_lock(&hdmi.lock); in read_edid()
316 r = hdmi4_read_edid(&hdmi.core, buf, len); in read_edid()
319 mutex_unlock(&hdmi.lock); in read_edid()
338 struct omap_dss_device *out = &hdmi.output; in hdmi_display_enable()
344 mutex_lock(&hdmi.lock); in hdmi_display_enable()
358 if (hdmi.audio_configured) { in hdmi_display_enable()
359 r = hdmi4_audio_config(&hdmi.core, &hdmi.wp, &hdmi.audio_config, in hdmi_display_enable()
360 hdmi.cfg.timings.pixelclock); in hdmi_display_enable()
363 hdmi.audio_abort_cb(&hdmi.pdev->dev); in hdmi_display_enable()
364 hdmi.audio_configured = false; in hdmi_display_enable()
368 spin_lock_irqsave(&hdmi.audio_playing_lock, flags); in hdmi_display_enable()
369 if (hdmi.audio_configured && hdmi.audio_playing) in hdmi_display_enable()
370 hdmi_start_audio_stream(&hdmi); in hdmi_display_enable()
371 hdmi.display_enabled = true; in hdmi_display_enable()
372 spin_unlock_irqrestore(&hdmi.audio_playing_lock, flags); in hdmi_display_enable()
374 mutex_unlock(&hdmi.lock); in hdmi_display_enable()
378 mutex_unlock(&hdmi.lock); in hdmi_display_enable()
388 mutex_lock(&hdmi.lock); in hdmi_display_disable()
390 spin_lock_irqsave(&hdmi.audio_playing_lock, flags); in hdmi_display_disable()
391 hdmi_stop_audio_stream(&hdmi); in hdmi_display_disable()
392 hdmi.display_enabled = false; in hdmi_display_disable()
393 spin_unlock_irqrestore(&hdmi.audio_playing_lock, flags); in hdmi_display_disable()
397 mutex_unlock(&hdmi.lock); in hdmi_display_disable()
406 mutex_lock(&hdmi.lock); in hdmi_core_enable()
414 mutex_unlock(&hdmi.lock); in hdmi_core_enable()
418 mutex_unlock(&hdmi.lock); in hdmi_core_enable()
426 mutex_lock(&hdmi.lock); in hdmi_core_disable()
430 mutex_unlock(&hdmi.lock); in hdmi_core_disable()
482 need_enable = hdmi.core_enabled == false; in hdmi_read_edid()
501 hdmi.cfg.infoframe = *avi; in hdmi_set_infoframe()
508 hdmi.cfg.hdmi_dvi_mode = hdmi_mode ? HDMI_HDMI : HDMI_DVI; in hdmi_set_hdmi_mode()
530 struct omap_dss_device *out = &hdmi.output; in hdmi_init_output()
537 out->ops.hdmi = &hdmi_ops; in hdmi_init_output()
545 struct omap_dss_device *out = &hdmi.output; in hdmi_uninit_output()
560 r = hdmi_parse_lanes_of(pdev, ep, &hdmi.phy); in hdmi_probe_of()
678 .audio_dma_addr = hdmi_wp_get_audio_dma_addr(&hdmi.wp), in hdmi_audio_register()
682 hdmi.audio_pdev = platform_device_register_data( in hdmi_audio_register()
686 if (IS_ERR(hdmi.audio_pdev)) in hdmi_audio_register()
687 return PTR_ERR(hdmi.audio_pdev); in hdmi_audio_register()
699 hdmi.pdev = pdev; in hdmi4_bind()
700 dev_set_drvdata(&pdev->dev, &hdmi); in hdmi4_bind()
702 mutex_init(&hdmi.lock); in hdmi4_bind()
703 spin_lock_init(&hdmi.audio_playing_lock); in hdmi4_bind()
711 r = hdmi_wp_init(pdev, &hdmi.wp); in hdmi4_bind()
715 r = hdmi_pll_init(pdev, &hdmi.pll, &hdmi.wp); in hdmi4_bind()
719 r = hdmi_phy_init(pdev, &hdmi.phy); in hdmi4_bind()
723 r = hdmi4_core_init(pdev, &hdmi.core); in hdmi4_bind()
736 IRQF_ONESHOT, "OMAP HDMI", &hdmi.wp); in hdmi4_bind()
758 hdmi_pll_uninit(&hdmi.pll); in hdmi4_bind()
766 if (hdmi.audio_pdev) in hdmi4_unbind()
767 platform_device_unregister(hdmi.audio_pdev); in hdmi4_unbind()
771 hdmi_pll_uninit(&hdmi.pll); in hdmi4_unbind()