Leon Romanovsky wrote at Monday, December 12, 2011 11:36 PM:
On Mon, Dec 12, 2011 at 22:20, Stephen Warren swarren@nvidia.com wrote:
Leon Romanovsky wrote at Monday, December 12, 2011 12:46 PM:
At this stage only Toshiba AC100/Dynabook supported.
...
+static struct snd_soc_jack_gpio tegra_alc5632_hs_jack_gpio = {
- .name = "Headset Detect",
- .report = SND_JACK_HEADSET,
- .debounce_time = 150,
+};
...
+static int tegra_alc5632_asoc_init(struct snd_soc_pcm_runtime *rtd) +{
...
- snd_soc_jack_add_gpios(&tegra_alc5632_hs_jack,
- 1, &tegra_alc5632_hs_jack_gpio);
Since tegra_alc5632_hs_jack_gpio is never set, doesn't this end up using GPIO 0 as the headset detect, which most likely is something completely unrelated to audio.
This is initial support of board file, at the coming patch set, I'll update board-paz00-pinmux.c [1] with audio related pins and I'll add platform device support. I think It is easy for review in this way.
I'm fine adding the feature later. But, I think you shouldn't call snd_soc_jack_add_gpios() until the platform data is there, or you'll end up enabling the feature already, but using the wrong GPIO.