From: James Wylder Date: Tue, 14 Sep 2010 03:20:04 +0000 (-0500) Subject: [ARM] tegra: stingray: board changes for cpcap-audio suspend mode X-Git-Tag: firefly_0821_release~9834^2~528 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=a2a2b6311f444eefeb236ec29e5a4548b706654d;p=firefly-linux-kernel-4.4.55.git [ARM] tegra: stingray: board changes for cpcap-audio suspend mode - Initialize VAUDIO to low power mode - Add standby_config changes to allow audio to go into low power state. - remove direct references to register 512, because access should be through the Linux regulator framework. Change-Id: I3ea23e2aabd183a3ecae0d30fce15a7365b168d8 Signed-off-by: James Wylder Signed-off-by: Iliyan Malchev --- diff --git a/arch/arm/mach-tegra/board-stingray-power.c b/arch/arm/mach-tegra/board-stingray-power.c index d4ac87c76543..2218c8a8c806 100644 --- a/arch/arm/mach-tegra/board-stingray-power.c +++ b/arch/arm/mach-tegra/board-stingray-power.c @@ -286,6 +286,7 @@ struct cpcap_spi_init_data stingray_cpcap_spi_init[] = { {CPCAP_REG_VRF1C, 0x0000}, {CPCAP_REG_VRF2C, 0x0000}, {CPCAP_REG_VRFREFC, 0x0000}, + {CPCAP_REG_VAUDIOC, 0x0065}, {CPCAP_REG_ADCC1, 0x9000}, {CPCAP_REG_ADCC2, 0x4136}, {CPCAP_REG_USBC1, 0x1201}, diff --git a/arch/arm/mach-tegra/board-stingray.c b/arch/arm/mach-tegra/board-stingray.c index c788e4ecb894..4554e814b27a 100644 --- a/arch/arm/mach-tegra/board-stingray.c +++ b/arch/arm/mach-tegra/board-stingray.c @@ -244,28 +244,28 @@ static struct platform_device cpcap_otg = { }; static struct cpcap_audio_state stingray_cpcap_audio_state = { - NULL, - CPCAP_AUDIO_MODE_NORMAL, - CPCAP_AUDIO_CODEC_OFF, - CPCAP_AUDIO_CODEC_RATE_8000_HZ, - CPCAP_AUDIO_CODEC_MUTE, - CPCAP_AUDIO_STDAC_OFF, - CPCAP_AUDIO_STDAC_RATE_44100_HZ, - CPCAP_AUDIO_STDAC_MUTE, - CPCAP_AUDIO_ANALOG_SOURCE_OFF, - CPCAP_AUDIO_OUT_NONE, - CPCAP_AUDIO_OUT_NONE, - CPCAP_AUDIO_OUT_LINEOUT, - CPCAP_AUDIO_OUT_LINEOUT, - CPCAP_AUDIO_OUT_NONE, - CPCAP_AUDIO_OUT_NONE, - CPCAP_AUDIO_BALANCE_NEUTRAL, - CPCAP_AUDIO_BALANCE_NEUTRAL, - CPCAP_AUDIO_BALANCE_NEUTRAL, - 7, /*default output gain */ - CPCAP_AUDIO_IN_NONE, - 31, /*default input_gain */ - CPCAP_AUDIO_RAT_NONE + .cpcap = NULL, + .mode = CPCAP_AUDIO_MODE_NORMAL, + .codec_mode = CPCAP_AUDIO_CODEC_OFF, + .codec_rate = CPCAP_AUDIO_CODEC_RATE_8000_HZ, + .codec_mute = CPCAP_AUDIO_CODEC_MUTE, + .stdac_mode = CPCAP_AUDIO_STDAC_OFF, + .stdac_rate = CPCAP_AUDIO_STDAC_RATE_44100_HZ, + .stdac_mute = CPCAP_AUDIO_STDAC_MUTE, + .analog_source = CPCAP_AUDIO_ANALOG_SOURCE_OFF, + .codec_primary_speaker = CPCAP_AUDIO_OUT_NONE, + .codec_secondary_speaker = CPCAP_AUDIO_OUT_NONE, + .stdac_primary_speaker = CPCAP_AUDIO_OUT_NONE, + .stdac_secondary_speaker = CPCAP_AUDIO_OUT_NONE, + .ext_primary_speaker = CPCAP_AUDIO_OUT_NONE, + .ext_secondary_speaker = CPCAP_AUDIO_OUT_NONE, + .codec_primary_balance = CPCAP_AUDIO_BALANCE_NEUTRAL, + .stdac_primary_balance = CPCAP_AUDIO_BALANCE_NEUTRAL, + .ext_primary_balance = CPCAP_AUDIO_BALANCE_NEUTRAL, + .output_gain = 7, + .microphone = CPCAP_AUDIO_IN_NONE, + .input_gain = 31, + .rat_type = CPCAP_AUDIO_RAT_NONE }; /* CPCAP is i2s master; tegra_audio_pdata.master == false */