[alsa-devel] [RFC/PATCH] pxa2xx_ac97 and gpio reset line
Robert Jarzmik
robert.jarzmik at free.fr
Sun Mar 15 12:14:18 CET 2009
Mark Brown <broonie at sirena.org.uk> writes:
<snip>
All first comments OK.
> Again, this should specify that ths only applies to PXA27x.
>
>> + if (!pdata) {
>> + is_ac97_resetgpio_113 = 1;
>> + } else {
>> + if (pdata->reset_gpio_95)
>> + is_ac97_resetgpio_95 = 1;
>> + if (pdata->reset_gpio_113)
>> + is_ac97_resetgpio_113 = 1;
>> + }
>
> This should be something more like:
>
> if (pdata) {
> switch (pdata->reset_gpio) {
> case 95:
> case 113:
> reset_gpio = pdata->reset_gpio;
> break;
> case 0:
> break;
> default:
> dev_err(dev, "Invalid reset GPIO %d\n",
> pdata->reset_gpio);
> }
> }
>
> if (cpu_is_pxa27x() && !reset_gpio)
> reset_gpio = 113;
Here I'll ask for a change.
You assume a reset gpio is _always_ provided on pxa27x CPUs. I do not. There may
be faulty boards where no gpio line is dedicated to AC97 reset, or AC97 reset
line is commanded by a helper chip.
Please check the new patch if you agree with the changes.
Cheers.
--
Robert
More information about the Alsa-devel
mailing list