From b60e55dbd02de8e0fa7a23ba90e43da43180c058 Mon Sep 17 00:00:00 2001 From: Guido van Rooij Date: Mon, 10 Dec 2001 20:27:18 +0000 Subject: [PATCH] Get rid of irritating (bogus) message: pcm0: ac97 codec failed to reset extended mode (0, got 80) This was due to not masking off the correct extended function bits in the read value from the extended status reg. MFC after: 2 days --- sys/dev/sound/pcm/ac97.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/dev/sound/pcm/ac97.c b/sys/dev/sound/pcm/ac97.c index 5f6ccd0cadb0..7ae3a6726006 100644 --- a/sys/dev/sound/pcm/ac97.c +++ b/sys/dev/sound/pcm/ac97.c @@ -474,9 +474,12 @@ ac97_reinitmixer(struct ac97_info *codec) if (!codec->noext) { wrcd(codec, AC97_REGEXT_STAT, codec->extstat); - if (rdcd(codec, AC97_REGEXT_STAT) != codec->extstat) + if ((rdcd(codec, AC97_REGEXT_STAT) & AC97_EXTCAPS) + != codec->extstat) device_printf(codec->dev, "ac97 codec failed to reset extended mode (%x, got %x)\n", - codec->extstat, rdcd(codec, AC97_REGEXT_STAT)); + codec->extstat, + rdcd(codec, AC97_REGEXT_STAT) & + AC97_EXTCAPS); } if ((rdcd(codec, AC97_REG_POWER) & 2) == 0)