sound/soc/codecs/rt5575.c
Source file repositories/reference/linux-study-clean/sound/soc/codecs/rt5575.c
File Facts
- System
- Linux kernel
- Corpus path
sound/soc/codecs/rt5575.c- Extension
.c- Size
- 9746 bytes
- Lines
- 352
- 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.
- 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
linux/i2c.hsound/soc.hsound/tlv.hrt5575.hrt5575-spi.h
Detected Declarations
function Copyrightfunction rt5575_get_priv_idfunction rt5575_probefunction rt5575_i2c_readfunction rt5575_i2c_writefunction rt5575_fw_load_by_spifunction rt5575_i2c_probe
Annotated Snippet
if (!IS_ENABLED(CONFIG_SND_SOC_RT5575_SPI)) {
dev_err(dev, "Please enable CONFIG_SND_SOC_RT5575_SPI\n");
return -ENODEV;
}
if (rt5575_fw_load_by_spi(rt5575))
return -ENODEV;
}
return devm_snd_soc_register_component(dev, &rt5575_soc_component_dev, rt5575_dai,
ARRAY_SIZE(rt5575_dai));
}
static const struct i2c_device_id rt5575_i2c_id[] = {
{ .name = "rt5575" },
{ }
};
MODULE_DEVICE_TABLE(i2c, rt5575_i2c_id);
static const struct of_device_id rt5575_of_match[] = {
{ .compatible = "realtek,rt5575" },
{ }
};
MODULE_DEVICE_TABLE(of, rt5575_of_match);
static struct i2c_driver rt5575_i2c_driver = {
.driver = {
.name = "rt5575",
.of_match_table = rt5575_of_match,
},
.probe = rt5575_i2c_probe,
.id_table = rt5575_i2c_id,
};
module_i2c_driver(rt5575_i2c_driver);
MODULE_DESCRIPTION("ASoC ALC5575 driver");
MODULE_AUTHOR("Oder Chiou <oder_chiou@realtek.com>");
MODULE_LICENSE("GPL");
Annotation
- Immediate include surface: `linux/i2c.h`, `sound/soc.h`, `sound/tlv.h`, `rt5575.h`, `rt5575-spi.h`.
- Detected declarations: `function Copyright`, `function rt5575_get_priv_id`, `function rt5575_probe`, `function rt5575_i2c_read`, `function rt5575_i2c_write`, `function rt5575_fw_load_by_spi`, `function rt5575_i2c_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.