sound/soc/codecs/chv3-codec.c
Source file repositories/reference/linux-study-clean/sound/soc/codecs/chv3-codec.c
File Facts
- System
- Linux kernel
- Corpus path
sound/soc/codecs/chv3-codec.c- Extension
.c- Size
- 1100 bytes
- Lines
- 43
- Domain
- Driver Families
- Bucket
- sound/soc
- 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
linux/module.hsound/soc.h
Detected Declarations
function chv3_codec_probe
Annotated Snippet
// SPDX-License-Identifier: GPL-2.0-only
#include <linux/module.h>
#include <sound/soc.h>
static struct snd_soc_dai_driver chv3_codec_dai = {
.name = "chv3-codec-hifi",
.capture = {
.stream_name = "Capture",
.channels_min = 8,
.channels_max = 8,
.rates = SNDRV_PCM_RATE_CONTINUOUS,
.formats = SNDRV_PCM_FMTBIT_S32_LE,
},
};
static const struct snd_soc_component_driver soc_component_dev_chv3_codec = {
};
static int chv3_codec_probe(struct platform_device *pdev)
{
return devm_snd_soc_register_component(&pdev->dev,
&soc_component_dev_chv3_codec, &chv3_codec_dai, 1);
}
static const struct of_device_id chv3_codec_of_match[] = {
{ .compatible = "google,chv3-codec", },
{ }
};
MODULE_DEVICE_TABLE(of, chv3_codec_of_match);
static struct platform_driver chv3_codec_platform_driver = {
.driver = {
.name = "chv3-codec",
.of_match_table = chv3_codec_of_match,
},
.probe = chv3_codec_probe,
};
module_platform_driver(chv3_codec_platform_driver);
MODULE_DESCRIPTION("ASoC Chameleon v3 codec driver");
MODULE_AUTHOR("Pawel Anikiel <pan@semihalf.com>");
MODULE_LICENSE("GPL");
Annotation
- Immediate include surface: `linux/module.h`, `sound/soc.h`.
- Detected declarations: `function chv3_codec_probe`.
- Atlas domain: Driver Families / sound/soc.
- 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.