Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/ic Add convenience macro AC97_HAS_SPDIF to check if ...



details:   https://anonhg.NetBSD.org/src/rev/1e347fb188d0
branches:  trunk
changeset: 572149:1e347fb188d0
user:      reinoud <reinoud%NetBSD.org@localhost>
date:      Wed Dec 22 00:54:55 2004 +0000

description:
Add convenience macro AC97_HAS_SPDIF to check if SPDIF output is supported
in the codec in the line of AC97_IS_4CH and AC97_IS_FIXED_RATE macro's.

diffstat:

 sys/dev/ic/ac97var.h |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (17 lines):

diff -r 3687f62b7cdb -r 1e347fb188d0 sys/dev/ic/ac97var.h
--- a/sys/dev/ic/ac97var.h      Wed Dec 22 00:49:14 2004 +0000
+++ b/sys/dev/ic/ac97var.h      Wed Dec 22 00:54:55 2004 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ac97var.h,v 1.12 2004/11/10 04:20:26 kent Exp $        */
+/*     $NetBSD: ac97var.h,v 1.13 2004/12/22 00:54:55 reinoud Exp $     */
 /*     $OpenBSD: ac97.h,v 1.4 2000/07/19 09:01:35 csapuntz Exp $       */
 
 /*
@@ -88,5 +88,6 @@
        (((codec)->vtbl->get_extcaps(codec) \
        & (AC97_EXT_AUDIO_SDAC | AC97_EXT_AUDIO_CDAC | AC97_EXT_AUDIO_LDAC)) \
        == (AC97_EXT_AUDIO_SDAC | AC97_EXT_AUDIO_CDAC | AC97_EXT_AUDIO_LDAC))
-
+#define AC97_HAS_SPDIF(codec)          \
+        ((codec)->vtbl->get_extcaps(codec) & AC97_EXT_AUDIO_SPDIF)
 #endif /* _DEV_IC_AC97VAR_H_ */



Home | Main Index | Thread Index | Old Index