sound/pci/ctxfi/ctmixer.c
Source file repositories/reference/linux-study-clean/sound/pci/ctxfi/ctmixer.c
File Facts
- System
- Linux kernel
- Corpus path
sound/pci/ctxfi/ctmixer.c- Extension
.c- Size
- 31895 bytes
- Lines
- 1273
- 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.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
ctmixer.hctamixer.hlinux/slab.hsound/core.hsound/control.hsound/asoundef.hsound/pcm.hsound/tlv.h
Detected Declarations
struct ct_kcontrol_initenum CT_SUM_CTLenum CT_AMIXER_CTLenum CTALSA_MIXER_CTLfunction get_amixer_indexfunction get_recording_amixerfunction get_switch_statefunction set_switch_statefunction uint16_to_float14function float14_to_uint16function ct_alsa_mix_volume_infofunction ct_alsa_mix_volume_getfunction ct_alsa_mix_volume_putfunction output_switch_infofunction output_switch_getfunction output_switch_putfunction mic_source_switch_infofunction mic_source_switch_getfunction mic_source_switch_putfunction do_line_mic_switchfunction do_digit_io_switchfunction do_switchfunction ct_alsa_mix_switch_infofunction ct_alsa_mix_switch_getfunction ct_alsa_mix_switch_putfunction dedicated_rca_infofunction dedicated_rca_getfunction dedicated_rca_putfunction ct_spdif_infofunction ct_spdif_get_maskfunction ct_spdif_getfunction ct_spdif_putfunction ct_mixer_kcontrol_newfunction ct_mixer_kcontrols_createfunction ct_mixer_recording_selectfunction ct_mixer_recording_unselectfunction ct_mixer_get_resourcesfunction ct_mixer_get_memfunction ct_mixer_topology_buildfunction mixer_set_input_portfunction port_to_amixerfunction mixer_get_output_portsfunction mixer_set_input_leftfunction mixer_set_input_rightfunction mixer_resumefunction ct_mixer_destroyfunction ct_mixer_createfunction ct_alsa_mix_create
Annotated Snippet
struct ct_kcontrol_init {
unsigned char ctl;
char *name;
};
static struct ct_kcontrol_init
ct_kcontrol_init_table[NUM_CTALSA_MIXERS] = {
[MIXER_MASTER_P] = {
.ctl = 1,
.name = "Master Playback Volume",
},
[MIXER_MASTER_C] = {
.ctl = 1,
.name = "Master Capture Volume",
},
[MIXER_PCM_P] = {
.ctl = 1,
.name = "PCM Playback Volume",
},
[MIXER_PCM_C] = {
.ctl = 1,
.name = "PCM Capture Volume",
},
[MIXER_LINEIN_P] = {
.ctl = 1,
.name = "Line Playback Volume",
},
[MIXER_LINEIN_C] = {
.ctl = 1,
.name = "Line Capture Volume",
},
[MIXER_MIC_P] = {
.ctl = 1,
.name = "Mic Playback Volume",
},
[MIXER_MIC_C] = {
.ctl = 1,
.name = "Mic Capture Volume",
},
[MIXER_SPDIFI_P] = {
.ctl = 1,
.name = "IEC958 Playback Volume",
},
[MIXER_SPDIFI_C] = {
.ctl = 1,
.name = "IEC958 Capture Volume",
},
[MIXER_SPDIFO_P] = {
.ctl = 1,
.name = "Digital Playback Volume",
},
[MIXER_WAVEF_P] = {
.ctl = 1,
.name = "Front Playback Volume",
},
[MIXER_WAVES_P] = {
.ctl = 1,
.name = "Side Playback Volume",
},
[MIXER_WAVEC_P] = {
.ctl = 1,
.name = "Center/LFE Playback Volume",
},
[MIXER_WAVER_P] = {
.ctl = 1,
.name = "Surround Playback Volume",
},
[MIXER_PCM_C_S] = {
.ctl = 1,
.name = "PCM Capture Switch",
},
[MIXER_LINEIN_C_S] = {
.ctl = 1,
.name = "Line Capture Switch",
},
[MIXER_MIC_C_S] = {
.ctl = 1,
.name = "Mic Capture Switch",
},
[MIXER_SPDIFI_C_S] = {
.ctl = 1,
.name = "IEC958 Capture Switch",
},
[MIXER_SPDIFO_P_S] = {
.ctl = 1,
.name = "Digital Playback Switch",
},
[MIXER_WAVEF_P_S] = {
.ctl = 1,
.name = "Front Playback Switch",
Annotation
- Immediate include surface: `ctmixer.h`, `ctamixer.h`, `linux/slab.h`, `sound/core.h`, `sound/control.h`, `sound/asoundef.h`, `sound/pcm.h`, `sound/tlv.h`.
- Detected declarations: `struct ct_kcontrol_init`, `enum CT_SUM_CTL`, `enum CT_AMIXER_CTL`, `enum CTALSA_MIXER_CTL`, `function get_amixer_index`, `function get_recording_amixer`, `function get_switch_state`, `function set_switch_state`, `function uint16_to_float14`, `function float14_to_uint16`.
- 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.