sound/soc/amd/acp/acp-rembrandt.c
Source file repositories/reference/linux-study-clean/sound/soc/amd/acp/acp-rembrandt.c
File Facts
- System
- Linux kernel
- Corpus path
sound/soc/amd/acp/acp-rembrandt.c- Extension
.c- Size
- 6292 bytes
- Lines
- 248
- 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.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/platform_device.hlinux/module.hlinux/err.hlinux/io.hsound/pcm_params.hsound/soc.hsound/soc-dai.hlinux/dma-mapping.hlinux/pci.hlinux/pm_runtime.hasm/amd/node.hamd.h../mach-config.hacp-mach.h
Detected Declarations
function acp6x_master_clock_generatefunction rembrandt_audio_probefunction rembrandt_audio_removefunction rmb_pcm_resume
Annotated Snippet
if (substream && substream->runtime) {
buf_in_frames = (substream->runtime->buffer_size);
buf_size = frames_to_bytes(substream->runtime, buf_in_frames);
config_pte_for_stream(chip, stream);
config_acp_dma(chip, stream, buf_size);
if (stream->dai_id)
restore_acp_i2s_params(substream, chip, stream);
else
restore_acp_pdm_params(substream, chip);
}
}
spin_unlock(&chip->acp_lock);
return 0;
}
static const struct dev_pm_ops rmb_dma_pm_ops = {
SYSTEM_SLEEP_PM_OPS(NULL, rmb_pcm_resume)
};
static struct platform_driver rembrandt_driver = {
.probe = rembrandt_audio_probe,
.remove = rembrandt_audio_remove,
.driver = {
.name = "acp_asoc_rembrandt",
.pm = pm_ptr(&rmb_dma_pm_ops),
},
};
module_platform_driver(rembrandt_driver);
MODULE_DESCRIPTION("AMD ACP Rembrandt Driver");
MODULE_IMPORT_NS("SND_SOC_ACP_COMMON");
MODULE_LICENSE("Dual BSD/GPL");
MODULE_ALIAS("platform:" DRV_NAME);
Annotation
- Immediate include surface: `linux/platform_device.h`, `linux/module.h`, `linux/err.h`, `linux/io.h`, `sound/pcm_params.h`, `sound/soc.h`, `sound/soc-dai.h`, `linux/dma-mapping.h`.
- Detected declarations: `function acp6x_master_clock_generate`, `function rembrandt_audio_probe`, `function rembrandt_audio_remove`, `function rmb_pcm_resume`.
- Atlas domain: Driver Families / sound/soc.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
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.