sound/soc/amd/acp7x/acp7x.h
Source file repositories/reference/linux-study-clean/sound/soc/amd/acp7x/acp7x.h
File Facts
- System
- Linux kernel
- Corpus path
sound/soc/amd/acp7x/acp7x.h- Extension
.h- Size
- 2957 bytes
- Lines
- 111
- 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/device.hlinux/errno.hlinux/io.hlinux/pci.hlinux/types.hsound/acp7x_chip_offset_byte.h
Detected Declarations
struct acp_hw_opsstruct acp7x_dev_datafunction acp_hw_initfunction acp_hw_deinitfunction acp_hw_suspendfunction acp_hw_resumefunction acp_hw_suspend_runtimefunction acp_hw_runtime_resume
Annotated Snippet
struct acp_hw_ops {
int (*acp_init)(void __iomem *acp_base, struct device *dev);
int (*acp_deinit)(void __iomem *acp_base, struct device *dev);
int (*acp_suspend)(struct device *dev);
int (*acp_resume)(struct device *dev);
int (*acp_suspend_runtime)(struct device *dev);
int (*acp_resume_runtime)(struct device *dev);
};
struct acp7x_dev_data {
void __iomem *acp7x_base;
struct acp_hw_ops *hw_ops;
u32 addr;
u32 reg_range;
u32 acp_rev;
};
void acp7x_hw_init_ops(struct acp_hw_ops *hw_ops);
static inline int acp_hw_init(struct acp7x_dev_data *adata, struct device *dev)
{
if (adata && adata->hw_ops && adata->hw_ops->acp_init)
return adata->hw_ops->acp_init(adata->acp7x_base, dev);
return -EOPNOTSUPP;
}
static inline int acp_hw_deinit(struct acp7x_dev_data *adata, struct device *dev)
{
if (adata && adata->hw_ops && adata->hw_ops->acp_deinit)
return adata->hw_ops->acp_deinit(adata->acp7x_base, dev);
return -EOPNOTSUPP;
}
static inline int acp_hw_suspend(struct device *dev)
{
struct acp7x_dev_data *adata = dev_get_drvdata(dev);
if (adata && adata->hw_ops && adata->hw_ops->acp_suspend)
return adata->hw_ops->acp_suspend(dev);
return -EOPNOTSUPP;
}
static inline int acp_hw_resume(struct device *dev)
{
struct acp7x_dev_data *adata = dev_get_drvdata(dev);
if (adata && adata->hw_ops && adata->hw_ops->acp_resume)
return adata->hw_ops->acp_resume(dev);
return -EOPNOTSUPP;
}
static inline int acp_hw_suspend_runtime(struct device *dev)
{
struct acp7x_dev_data *adata = dev_get_drvdata(dev);
if (adata && adata->hw_ops && adata->hw_ops->acp_suspend_runtime)
return adata->hw_ops->acp_suspend_runtime(dev);
return -EOPNOTSUPP;
}
static inline int acp_hw_runtime_resume(struct device *dev)
{
struct acp7x_dev_data *adata = dev_get_drvdata(dev);
if (adata && adata->hw_ops && adata->hw_ops->acp_resume_runtime)
return adata->hw_ops->acp_resume_runtime(dev);
return -EOPNOTSUPP;
}
int snd_amd_acp_find_config(struct pci_dev *pci);
#endif /* __SOUND_SOC_AMD_ACP7X_H */
Annotation
- Immediate include surface: `linux/device.h`, `linux/errno.h`, `linux/io.h`, `linux/pci.h`, `linux/types.h`, `sound/acp7x_chip_offset_byte.h`.
- Detected declarations: `struct acp_hw_ops`, `struct acp7x_dev_data`, `function acp_hw_init`, `function acp_hw_deinit`, `function acp_hw_suspend`, `function acp_hw_resume`, `function acp_hw_suspend_runtime`, `function acp_hw_runtime_resume`.
- 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.