sound/pci/ice1712/wm8776.h
Source file repositories/reference/linux-study-clean/sound/pci/ice1712/wm8776.h
File Facts
- System
- Linux kernel
- Corpus path
sound/pci/ice1712/wm8776.h- Extension
.h- Size
- 6627 bytes
- Lines
- 210
- Domain
- Driver Families
- Bucket
- sound/pci
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
- No C-style include directives detected by the generator.
Detected Declarations
struct snd_wm8776struct snd_wm8776_opsstruct snd_wm8776_ctlstruct snd_wm8776enum snd_wm8776_ctl_idenum snd_wm8776_agc_mode
Annotated Snippet
struct snd_wm8776_ops {
void (*write)(struct snd_wm8776 *wm, u8 addr, u8 data);
};
enum snd_wm8776_ctl_id {
WM8776_CTL_DAC_VOL,
WM8776_CTL_DAC_SW,
WM8776_CTL_DAC_ZC_SW,
WM8776_CTL_HP_VOL,
WM8776_CTL_HP_SW,
WM8776_CTL_HP_ZC_SW,
WM8776_CTL_AUX_SW,
WM8776_CTL_BYPASS_SW,
WM8776_CTL_DAC_IZD_SW,
WM8776_CTL_PHASE_SW,
WM8776_CTL_DEEMPH_SW,
WM8776_CTL_ADC_VOL,
WM8776_CTL_ADC_SW,
WM8776_CTL_INPUT1_SW,
WM8776_CTL_INPUT2_SW,
WM8776_CTL_INPUT3_SW,
WM8776_CTL_INPUT4_SW,
WM8776_CTL_INPUT5_SW,
WM8776_CTL_AGC_SEL,
WM8776_CTL_LIM_THR,
WM8776_CTL_LIM_ATK,
WM8776_CTL_LIM_DCY,
WM8776_CTL_LIM_TRANWIN,
WM8776_CTL_LIM_MAXATTN,
WM8776_CTL_ALC_TGT,
WM8776_CTL_ALC_ATK,
WM8776_CTL_ALC_DCY,
WM8776_CTL_ALC_MAXGAIN,
WM8776_CTL_ALC_MAXATTN,
WM8776_CTL_ALC_HLD,
WM8776_CTL_NGT_SW,
WM8776_CTL_NGT_THR,
WM8776_CTL_COUNT,
};
#define WM8776_ENUM_MAX 16
#define WM8776_FLAG_STEREO (1 << 0)
#define WM8776_FLAG_VOL_UPDATE (1 << 1)
#define WM8776_FLAG_INVERT (1 << 2)
#define WM8776_FLAG_LIM (1 << 3)
#define WM8776_FLAG_ALC (1 << 4)
struct snd_wm8776_ctl {
const char *name;
snd_ctl_elem_type_t type;
const char *const enum_names[WM8776_ENUM_MAX];
const unsigned int *tlv;
u16 reg1, reg2, mask1, mask2, min, max, flags;
void (*set)(struct snd_wm8776 *wm, u16 ch1, u16 ch2);
void (*get)(struct snd_wm8776 *wm, u16 *ch1, u16 *ch2);
};
enum snd_wm8776_agc_mode {
WM8776_AGC_OFF,
WM8776_AGC_LIM,
WM8776_AGC_ALC_R,
WM8776_AGC_ALC_L,
WM8776_AGC_ALC_STEREO
};
struct snd_wm8776 {
struct snd_card *card;
struct snd_wm8776_ctl ctl[WM8776_CTL_COUNT];
enum snd_wm8776_agc_mode agc_mode;
struct snd_wm8776_ops ops;
u16 regs[WM8776_REG_COUNT]; /* 9-bit registers */
};
void snd_wm8776_init(struct snd_wm8776 *wm);
void snd_wm8776_resume(struct snd_wm8776 *wm);
void snd_wm8776_set_power(struct snd_wm8776 *wm, u16 power);
void snd_wm8776_volume_restore(struct snd_wm8776 *wm);
int snd_wm8776_build_controls(struct snd_wm8776 *wm);
#endif /* __SOUND_WM8776_H */
Annotation
- Detected declarations: `struct snd_wm8776`, `struct snd_wm8776_ops`, `struct snd_wm8776_ctl`, `struct snd_wm8776`, `enum snd_wm8776_ctl_id`, `enum snd_wm8776_agc_mode`.
- Atlas domain: Driver Families / sound/pci.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.