Ejemplo n.º 1
0
static bool _tegra_dc_enable(struct tegra_dc *dc)
{

	if (dc->mode.pclk == 0) {
		switch (dc->out->type) {
		case TEGRA_DC_OUT_HDMI:
		/* DC enable called but no videomode is loaded.
		     Check if HDMI is connected, then set fallback mdoe */
		if (tegra_dc_hpd(dc)) {
			if (_tegra_dc_set_default_videomode(dc))
				return false;
		} else
			return false;

		break;

		/* Do nothing for other outputs for now */
		case TEGRA_DC_OUT_RGB:

		case TEGRA_DC_OUT_DSI:

		default:
			return false;
		}
	}

	if (!dc->out)
		return false;
	tegra_dc_io_start(dc);

	return _tegra_dc_controller_enable(dc);
}
Ejemplo n.º 2
0
static bool _tegra_dc_enable(struct tegra_dc *dc)
{
	if (dc->mode.pclk == 0)
		return false;

	if (!dc->out)
		return false;

	tegra_dc_io_start(dc);

	if (!_tegra_dc_controller_enable(dc)) {
		tegra_dc_io_end(dc);
		return false;
	}
	return true;
}