1 #ifndef OXYGEN_H_INCLUDED
2 #define OXYGEN_H_INCLUDED
6 #include <linux/wait.h>
19 #define OXYGEN_MCLKS(f_single, f_double, f_quad) ((MCLK_##f_single << 0) | \
20 (MCLK_##f_double << 2) | \
23 #define OXYGEN_IO_SIZE 0x100
25 #define OXYGEN_EEPROM_ID 0x434d
28 #define PLAYBACK_0_TO_I2S 0x0001
30 #define PLAYBACK_1_TO_SPDIF 0x0004
31 #define PLAYBACK_2_TO_AC97_1 0x0008
32 #define CAPTURE_0_FROM_I2S_1 0x0010
33 #define CAPTURE_0_FROM_I2S_2 0x0020
35 #define CAPTURE_1_FROM_SPDIF 0x0080
36 #define CAPTURE_2_FROM_I2S_2 0x0100
37 #define CAPTURE_2_FROM_AC97_1 0x0200
39 #define MIDI_OUTPUT 0x0800
40 #define MIDI_INPUT 0x1000
41 #define AC97_CD_INPUT 0x2000
42 #define AC97_FMIC_SWITCH 0x4000
54 #define OXYGEN_PCI_SUBID(sv, sd) \
55 .vendor = PCI_VENDOR_ID_CMEDIA, \
60 #define BROKEN_EEPROM_DRIVER_DATA ((unsigned long)-1)
61 #define OXYGEN_PCI_SUBID_BROKEN_EEPROM \
62 OXYGEN_PCI_SUBID(PCI_VENDOR_ID_CMEDIA, 0x8788), \
63 .driver_data = BROKEN_EEPROM_DRIVER_DATA
96 unsigned int play_routing);
100 unsigned int reg,
unsigned int mute);
148 u16 saved_ac97_registers[2][0x40];
164 #ifdef CONFIG_PM_SLEEP
210 static inline void oxygen_set_bits8(
struct oxygen *
chip,
216 static inline void oxygen_set_bits16(
struct oxygen *
chip,
222 static inline void oxygen_set_bits32(
struct oxygen *
chip,
228 static inline void oxygen_clear_bits8(
struct oxygen *
chip,
234 static inline void oxygen_clear_bits16(
struct oxygen *
chip,
240 static inline void oxygen_clear_bits32(
struct oxygen *
chip,
246 static inline void oxygen_ac97_set_bits(
struct oxygen *
chip,
unsigned int codec,
252 static inline void oxygen_ac97_clear_bits(
struct oxygen *
chip,