include/sound/sdca.h
Source file repositories/reference/linux-study-clean/include/sound/sdca.h
File Facts
- System
- Linux kernel
- Corpus path
include/sound/sdca.h- Extension
.h- Size
- 2549 bytes
- Lines
- 92
- Domain
- Driver Families
- Bucket
- include/sound
- 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/types.hlinux/kconfig.h
Detected Declarations
struct acpi_table_swftstruct fwnode_handlestruct sdw_slavestruct sdca_devstruct sdca_function_descstruct sdca_device_dataenum sdca_quirkfunction sdca_lookup_functionsfunction sdca_dev_register_functionsfunction sdca_dev_unregister_functions
Annotated Snippet
struct sdca_function_desc {
struct fwnode_handle *node;
struct sdca_dev *func_dev;
const char *name;
u32 type;
u8 adr;
bool duplicate;
};
/**
* struct sdca_device_data - structure containing all SDCA related information
* @interface_revision: Value read from _DSD property, mainly to check
* for changes between silicon versions.
* @num_functions: Total number of supported SDCA functions. Invalid/unsupported
* functions will be skipped.
* @function: Array of function descriptors.
* @swft: Pointer to the SWFT table, if available.
*/
struct sdca_device_data {
u32 interface_revision;
int num_functions;
struct sdca_function_desc function[SDCA_MAX_FUNCTION_COUNT];
struct acpi_table_swft *swft;
};
enum sdca_quirk {
SDCA_QUIRKS_RT712_VB,
SDCA_QUIRKS_SKIP_FUNC_TYPE_PATCHING,
};
#if IS_ENABLED(CONFIG_ACPI) && IS_ENABLED(CONFIG_SND_SOC_SDCA)
void sdca_lookup_functions(struct sdw_slave *slave);
void sdca_lookup_swft(struct sdw_slave *slave);
void sdca_lookup_interface_revision(struct sdw_slave *slave);
bool sdca_device_quirk_match(struct sdw_slave *slave, enum sdca_quirk quirk);
int sdca_dev_register_functions(struct sdw_slave *slave);
void sdca_dev_unregister_functions(struct sdw_slave *slave);
#else
static inline void sdca_lookup_functions(struct sdw_slave *slave) {}
static inline void sdca_lookup_swft(struct sdw_slave *slave) {}
static inline void sdca_lookup_interface_revision(struct sdw_slave *slave) {}
static inline bool sdca_device_quirk_match(struct sdw_slave *slave, enum sdca_quirk quirk)
{
return false;
}
static inline int sdca_dev_register_functions(struct sdw_slave *slave)
{
return 0;
}
static inline void sdca_dev_unregister_functions(struct sdw_slave *slave) {}
#endif
#endif
Annotation
- Immediate include surface: `linux/types.h`, `linux/kconfig.h`.
- Detected declarations: `struct acpi_table_swft`, `struct fwnode_handle`, `struct sdw_slave`, `struct sdca_dev`, `struct sdca_function_desc`, `struct sdca_device_data`, `enum sdca_quirk`, `function sdca_lookup_functions`, `function sdca_dev_register_functions`, `function sdca_dev_unregister_functions`.
- Atlas domain: Driver Families / include/sound.
- 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.