sound/soc/tegra/tegra_cif.h
Source file repositories/reference/linux-study-clean/sound/soc/tegra/tegra_cif.h
File Facts
- System
- Linux kernel
- Corpus path
sound/soc/tegra/tegra_cif.h- Extension
.h- Size
- 2908 bytes
- Lines
- 88
- 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/regmap.h
Detected Declarations
struct tegra_cif_conffunction tegra_set_ciffunction tegra264_set_cif
Annotated Snippet
struct tegra_cif_conf {
unsigned int threshold;
unsigned int audio_ch;
unsigned int client_ch;
unsigned int audio_bits;
unsigned int client_bits;
unsigned int expand;
unsigned int stereo_conv;
unsigned int replicate;
unsigned int truncate;
unsigned int mono_conv;
};
static inline void tegra_set_cif(struct regmap *regmap, unsigned int reg,
struct tegra_cif_conf *conf)
{
unsigned int value;
value = (conf->threshold << TEGRA_ACIF_CTRL_FIFO_TH_SHIFT) |
((conf->audio_ch - 1) << TEGRA_ACIF_CTRL_AUDIO_CH_SHIFT) |
((conf->client_ch - 1) << TEGRA_ACIF_CTRL_CLIENT_CH_SHIFT) |
(conf->audio_bits << TEGRA_ACIF_CTRL_AUDIO_BITS_SHIFT) |
(conf->client_bits << TEGRA_ACIF_CTRL_CLIENT_BITS_SHIFT) |
(conf->expand << TEGRA_ACIF_CTRL_EXPAND_SHIFT) |
(conf->stereo_conv << TEGRA_ACIF_CTRL_STEREO_CONV_SHIFT) |
(conf->replicate << TEGRA_ACIF_CTRL_REPLICATE_SHIFT) |
(conf->truncate << TEGRA_ACIF_CTRL_TRUNCATE_SHIFT) |
(conf->mono_conv << TEGRA_ACIF_CTRL_MONO_CONV_SHIFT);
regmap_update_bits(regmap, reg, TEGRA_ACIF_UPDATE_MASK, value);
}
static inline void tegra264_set_cif(struct regmap *regmap, unsigned int reg,
struct tegra_cif_conf *conf)
{
unsigned int value;
value = (conf->threshold << TEGRA_ACIF_CTRL_FIFO_TH_SHIFT) |
((conf->audio_ch - 1) << TEGRA264_ACIF_CTRL_AUDIO_CH_SHIFT) |
((conf->client_ch - 1) << TEGRA264_ACIF_CTRL_CLIENT_CH_SHIFT) |
(conf->audio_bits << TEGRA264_ACIF_CTRL_AUDIO_BITS_SHIFT) |
(conf->client_bits << TEGRA_ACIF_CTRL_CLIENT_BITS_SHIFT) |
(conf->expand << TEGRA_ACIF_CTRL_EXPAND_SHIFT) |
(conf->stereo_conv << TEGRA_ACIF_CTRL_STEREO_CONV_SHIFT) |
(conf->replicate << TEGRA_ACIF_CTRL_REPLICATE_SHIFT) |
(conf->truncate << TEGRA_ACIF_CTRL_TRUNCATE_SHIFT) |
(conf->mono_conv << TEGRA_ACIF_CTRL_MONO_CONV_SHIFT);
regmap_update_bits(regmap, reg, TEGRA_ACIF_UPDATE_MASK, value);
}
#endif
Annotation
- Immediate include surface: `linux/regmap.h`.
- Detected declarations: `struct tegra_cif_conf`, `function tegra_set_cif`, `function tegra264_set_cif`.
- 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.