grub2: bring back build of aros-side grub2 tools
[AROS.git] / workbench / devs / AHI / Drivers / EMU10kx / emu10kx-ac97.h
blobe8954276bc8d523a593f48597ad1416cda06873a
1 /*
2 emu10kx.audio - AHI driver for SoundBlaster Live! series
3 Copyright (C) 2002-2005 Martin Blom <martin@blom.org>
5 This program is free software; you can redistribute it and/or
6 modify it under the terms of the GNU General Public License
7 as published by the Free Software Foundation; either version 2
8 of the License, or (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 #ifndef AHI_Drivers_EMU10kx_emu10kx_ac97_h
21 #define AHI_Drivers_EMU10kx_emu10kx_ac97_h
23 #include <config.h>
24 #include <exec/semaphores.h>
25 #include <utility/hooks.h>
27 #define EMU10KX_AC97_SEMAPHORE "emu10kx.ac97"
29 /* This is the global, public data structure used to communicate with
30 * the AC97 part of emu10kx.audio. Find it, lock it, use it and then
31 * release it. Beware of the license of this file and the driver!! */
33 struct EMU10kxAC97
35 struct SignalSemaphore Semaphore;
36 UWORD Cards;
37 UWORD Version;
38 UWORD Revision;
39 struct Hook GetFunc;
40 struct Hook SetFunc;
44 /* Message for GetFunc */
45 struct AC97GetMessage
47 ULONG CardNum;
48 ULONG Register;
51 /* Message for SetFunc */
52 struct AC97SetMessage
54 ULONG CardNum;
55 ULONG Register;
56 ULONG Value;
59 struct EMU10kxBase;
61 ULONG
62 AC97GetFunc( struct Hook* hook,
63 struct EMU10kxBase* EMU10kxBase,
64 struct AC97GetMessage* msg );
66 VOID
67 AC97SetFunc( struct Hook* hook,
68 struct EMU10kxBase* EMU10kxBase,
69 struct AC97SetMessage* msg );
72 /* Special digital volume registers. Range is 0 (mute) to 100 (full). */
74 enum EMU10kxDSPVol {
75 emu10kx_dsp_first = 0x80000000,
77 /* Input volume GPR */
78 emu10kx_dsp_ahi_front_l = 0x80000000,
79 emu10kx_dsp_ahi_front_r,
80 emu10kx_dsp_ahi_rear_l,
81 emu10kx_dsp_ahi_rear_r,
82 emu10kx_dsp_ahi_surround_l,
83 emu10kx_dsp_ahi_surround_r,
84 emu10kx_dsp_ahi_center,
85 emu10kx_dsp_ahi_lfe,
87 emu10kx_dsp_spdif_cd_l,
88 emu10kx_dsp_spdif_cd_r,
89 emu10kx_dsp_spdif_in_l,
90 emu10kx_dsp_spdif_in_r,
92 /* Output volume GPR */
93 emu10kx_dsp_spdif_front_l,
94 emu10kx_dsp_spdif_front_r,
95 emu10kx_dsp_spdif_rear_l,
96 emu10kx_dsp_spdif_rear_r,
97 emu10kx_dsp_spdif_surround_l,
98 emu10kx_dsp_spdif_surround_r,
99 emu10kx_dsp_spdif_center,
100 emu10kx_dsp_spdif_lfe,
102 emu10kx_dsp_analog_front_l,
103 emu10kx_dsp_analog_front_r,
104 emu10kx_dsp_analog_rear_l,
105 emu10kx_dsp_analog_rear_r,
106 emu10kx_dsp_analog_surround_l,
107 emu10kx_dsp_analog_surround_r,
108 emu10kx_dsp_analog_center,
109 emu10kx_dsp_analog_lfe,
111 /* AHI_FRONT-to-rear GPR */
112 emu10kx_dsp_front_rear_l,
113 emu10kx_dsp_front_rear_r,
115 /* AHI_SURROUND-to-rear GPR */
116 emu10kx_dsp_surround_rear_l,
117 emu10kx_dsp_surround_rear_r,
119 /* AHI_FRONT-to-center and AHI_FRONT-to-LFE GPRs */
120 emu10kx_dsp_front_center,
121 emu10kx_dsp_front_lfe,
123 emu10kx_dsp_last
127 #endif /* AHI_Drivers_EMU10kx_emu10kx_ac97_h */