Sync with the recent ac97 changes.

- AC97_CODEC_DOES_VRA -> AC97_EXT_AUDIO_VRA
 - Use ac97_codec_if::get_extcaps()
 - Remove VRA/VRM enabling code
This commit is contained in:
kent 2002-10-08 18:01:42 +00:00
parent a931c80c22
commit f6f836bbe6
1 changed files with 4 additions and 7 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: repulse.c,v 1.6 2002/10/02 04:55:52 thorpej Exp $ */
/* $NetBSD: repulse.c,v 1.7 2002/10/08 18:01:42 kent Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: repulse.c,v 1.6 2002/10/02 04:55:52 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: repulse.c,v 1.7 2002/10/08 18:01:42 kent Exp $");
#include <sys/types.h>
#include <sys/param.h>
@ -335,16 +335,13 @@ repulse_attach(struct device *parent, struct device *self, void *aux) {
* XXX this should be a panic(). OTOH, audio codec speed is not
* important enough to do this.
*/
if (repac_read(sc, AC97_REG_EXTENDED_ID, &a)
|| !(a & AC97_CODEC_DOES_VRA)) {
a = sc->sc_codec_if->vtbl->get_extcaps(sc->sc_codec_if);
if (!(a & AC97_EXT_AUDIO_VRA)) {
printf("%s: warning: codec doesn't support "
"hardware AC'97 2.0 Variable Rate Audio\n",
sc->sc_dev.dv_xname);
}
#endif
/* enable VRA */
repac_write(sc, AC97_REG_EXTENDED_STATUS,
AC97_ENAB_VRA | AC97_ENAB_MICVRA);
/*
* from auvia.c: disable mutes ...