Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 00c63e07 authored by Wentao Xu's avatar Wentao Xu
Browse files

mpq8092: gpiomux: add gpio 22 setting



gpio 22 is used for HDMI mux interrupt.

Change-Id: I1b1e2f530843465dff438d75c3d795654481cb04
Signed-off-by: default avatarWentao Xu <wentaox@codeaurora.org>
parent 2d37de8c
Loading
Loading
Loading
Loading
+27 −0
Original line number Diff line number Diff line
@@ -143,6 +143,7 @@ static struct msm_gpiomux_config mpq8092_spkr_mi2s_mclk_configs[] __initdata = {
		}
	}
};

static struct msm_gpiomux_config mpq8092_spdif_config[] __initdata = {
	{
		.gpio = 41,
@@ -160,6 +161,30 @@ static struct msm_gpiomux_config mpq8092_spdif_config[] __initdata = {
	},
};

static struct gpiomux_setting hdmi_mux_int_active_cfg = {
	.func = GPIOMUX_FUNC_GPIO,
	.drv = GPIOMUX_DRV_16MA,
	.pull = GPIOMUX_PULL_UP,
	.dir = GPIOMUX_IN,
};

static struct gpiomux_setting hdmi_mux_int_suspend_cfg = {
	.func = GPIOMUX_FUNC_GPIO,
	.drv = GPIOMUX_DRV_2MA,
	.pull = GPIOMUX_PULL_NONE,
	.dir = GPIOMUX_IN,
};

static struct msm_gpiomux_config mpq_hdmi_mux_configs[] __initdata = {
	{
		.gpio = 22, /* hdmi_mux interrupt */
		.settings = {
			[GPIOMUX_ACTIVE]    = &hdmi_mux_int_active_cfg,
			[GPIOMUX_SUSPENDED] = &hdmi_mux_int_suspend_cfg,
		},
	},
};

void __init mpq8092_init_gpiomux(void)
{
	int rc;
@@ -178,4 +203,6 @@ void __init mpq8092_init_gpiomux(void)
			ARRAY_SIZE(mpq8092_spkr_mi2s_mclk_configs));
	msm_gpiomux_install(mpq8092_spdif_config,
			ARRAY_SIZE(mpq8092_spdif_config));
	msm_gpiomux_install(mpq_hdmi_mux_configs,
			ARRAY_SIZE(mpq_hdmi_mux_configs));
}