diff options
author | Jacob Meuser <jakemsr@cvs.openbsd.org> | 2008-12-21 20:21:25 +0000 |
---|---|---|
committer | Jacob Meuser <jakemsr@cvs.openbsd.org> | 2008-12-21 20:21:25 +0000 |
commit | 278bca9bf22c007da5199f29e799bd3b911433dc (patch) | |
tree | 6b64d4493fcf1b6f3fb5da63afe626dcfb801719 | |
parent | 22499e1f27be5180c551f8d72f250bd542ef0cf8 (diff) |
add mixer_class member to struct widget_t, and define the mixer
classes in azalia.h instead of azalia_codec.c. this will allow
the mixer class to be determined outside of azalia_generic_mixer_init.
-rw-r--r-- | sys/dev/pci/azalia.h | 7 | ||||
-rw-r--r-- | sys/dev/pci/azalia_codec.c | 5 |
2 files changed, 7 insertions, 5 deletions
diff --git a/sys/dev/pci/azalia.h b/sys/dev/pci/azalia.h index 71f49443e85..13c69024aa0 100644 --- a/sys/dev/pci/azalia.h +++ b/sys/dev/pci/azalia.h @@ -1,4 +1,4 @@ -/* $OpenBSD: azalia.h,v 1.26 2008/11/30 08:36:57 jakemsr Exp $ */ +/* $OpenBSD: azalia.h,v 1.27 2008/12/21 20:21:24 jakemsr Exp $ */ /* $NetBSD: azalia.h,v 1.6 2006/01/16 14:15:26 kent Exp $ */ /*- @@ -478,6 +478,10 @@ #define HDA_MAX_CHANNELS 16 #define HDA_MAX_SENSE_PINS 16 +#define AZ_CLASS_INPUT 0 +#define AZ_CLASS_OUTPUT 1 +#define AZ_CLASS_RECORD 2 + /* memory-mapped types */ typedef struct { uint32_t low; @@ -518,6 +522,7 @@ typedef struct { int enable; uint32_t widgetcap; int type; /* = bit20-24 of widgetcap */ + int mixer_class; int nconnections; nid_t *connections; int selected; diff --git a/sys/dev/pci/azalia_codec.c b/sys/dev/pci/azalia_codec.c index c14e5b0eca8..2b5896d03c8 100644 --- a/sys/dev/pci/azalia_codec.c +++ b/sys/dev/pci/azalia_codec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: azalia_codec.c,v 1.79 2008/11/30 22:01:34 jakemsr Exp $ */ +/* $OpenBSD: azalia_codec.c,v 1.80 2008/12/21 20:21:24 jakemsr Exp $ */ /* $NetBSD: azalia_codec.c,v 1.8 2006/05/10 11:17:27 kent Exp $ */ /*- @@ -40,9 +40,6 @@ #define XNAME(co) (((struct device *)co->az)->dv_xname) #define MIXER_DELTA(n) (AUDIO_MAX_GAIN / (n)) -#define AZ_CLASS_INPUT 0 -#define AZ_CLASS_OUTPUT 1 -#define AZ_CLASS_RECORD 2 #define ENUM_OFFON .un.e={2, {{{AudioNoff}, 0}, {{AudioNon}, 1}}} #define ENUM_IO .un.e={2, {{{"input"}, 0}, {{"output"}, 1}}} #define AzaliaNfront "front" |