Re: [BUG] unsafe reset in ac97_codec.c

From: Liam Girdwood
Date: Thu Feb 26 2004 - 10:57:15 EST


Hi

I've attached a patch against 2.4.25 that now checks for the codec type
before doing the AC97 register reset.

Changes:-

o Added AC97_DEFAULT_POWER_OFF to ac97_codec_ids[]
o ac97_probe now checks hardwired codec ID's before sending a reset
o Added initial support for WM9713 AC97 codec.


Liam

On Thu, 2004-02-05 at 17:59, Alan Cox wrote:
> On Iau, 2004-02-05 at 16:31, Liam Girdwood wrote:
> > I agree, but I think we need to be aware of the codec type before we do
> > a register reset. This type of codec is now becoming popular in PDA's.
>
> Sometimes we can't even find out but yes I agree
>
> > I can see another problem with the current probe implementation.
> > Currently it sends the register reset command without first checking the
> > codec ready bit. This assumes that the AC97 link is up and completely
> > working before probe is called.
>
> It is (in theory) the job of the calling driver to ensure AC97 is up
> before doing the reset part.
>
> > I'll implement this if it's acceptable as I can test it on both types of
> > codec.
>
> Sounds right to me
>
>
> ________________________________________________________________________
> This email has been scanned for all viruses by the MessageLabs Email
> Security System.
> ________________________________________________________________________
>

Attachment: ac_power.diff.gz
Description: GNU Zip compressed data