sound/soc/codecs/max98095.c

Source file repositories/reference/linux-study-clean/sound/soc/codecs/max98095.c

File Facts

System
Linux kernel
Corpus path
sound/soc/codecs/max98095.c
Extension
.c
Size
63854 bytes
Lines
2168
Domain
Driver Families
Bucket
sound/soc
Inferred role
Driver Families: exported/initcall integration point
Status
integration 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.

Dependency Surface

Detected Declarations

Annotated Snippet

struct max98095_cdata {
	unsigned int rate;
	unsigned int fmt;
	int eq_sel;
	int bq_sel;
};

struct max98095_priv {
	struct regmap *regmap;
	enum max98095_type devtype;
	struct max98095_pdata *pdata;
	struct clk *mclk;
	unsigned int sysclk;
	struct max98095_cdata dai[3];
	const char **eq_texts;
	const char **bq_texts;
	struct soc_enum eq_enum;
	struct soc_enum bq_enum;
	int eq_textcnt;
	int bq_textcnt;
	u8 lin_state;
	unsigned int mic1pre;
	unsigned int mic2pre;
	struct snd_soc_jack *headphone_jack;
	struct snd_soc_jack *mic_jack;
	struct mutex lock;
};

static const struct reg_default max98095_reg_def[] = {
	{  0xf, 0x00 }, /* 0F */
	{ 0x10, 0x00 }, /* 10 */
	{ 0x11, 0x00 }, /* 11 */
	{ 0x12, 0x00 }, /* 12 */
	{ 0x13, 0x00 }, /* 13 */
	{ 0x14, 0x00 }, /* 14 */
	{ 0x15, 0x00 }, /* 15 */
	{ 0x16, 0x00 }, /* 16 */
	{ 0x17, 0x00 }, /* 17 */
	{ 0x18, 0x00 }, /* 18 */
	{ 0x19, 0x00 }, /* 19 */
	{ 0x1a, 0x00 }, /* 1A */
	{ 0x1b, 0x00 }, /* 1B */
	{ 0x1c, 0x00 }, /* 1C */
	{ 0x1d, 0x00 }, /* 1D */
	{ 0x1e, 0x00 }, /* 1E */
	{ 0x1f, 0x00 }, /* 1F */
	{ 0x20, 0x00 }, /* 20 */
	{ 0x21, 0x00 }, /* 21 */
	{ 0x22, 0x00 }, /* 22 */
	{ 0x23, 0x00 }, /* 23 */
	{ 0x24, 0x00 }, /* 24 */
	{ 0x25, 0x00 }, /* 25 */
	{ 0x26, 0x00 }, /* 26 */
	{ 0x27, 0x00 }, /* 27 */
	{ 0x28, 0x00 }, /* 28 */
	{ 0x29, 0x00 }, /* 29 */
	{ 0x2a, 0x00 }, /* 2A */
	{ 0x2b, 0x00 }, /* 2B */
	{ 0x2c, 0x00 }, /* 2C */
	{ 0x2d, 0x00 }, /* 2D */
	{ 0x2e, 0x00 }, /* 2E */
	{ 0x2f, 0x00 }, /* 2F */
	{ 0x30, 0x00 }, /* 30 */
	{ 0x31, 0x00 }, /* 31 */
	{ 0x32, 0x00 }, /* 32 */
	{ 0x33, 0x00 }, /* 33 */
	{ 0x34, 0x00 }, /* 34 */
	{ 0x35, 0x00 }, /* 35 */
	{ 0x36, 0x00 }, /* 36 */
	{ 0x37, 0x00 }, /* 37 */
	{ 0x38, 0x00 }, /* 38 */
	{ 0x39, 0x00 }, /* 39 */
	{ 0x3a, 0x00 }, /* 3A */
	{ 0x3b, 0x00 }, /* 3B */
	{ 0x3c, 0x00 }, /* 3C */
	{ 0x3d, 0x00 }, /* 3D */
	{ 0x3e, 0x00 }, /* 3E */
	{ 0x3f, 0x00 }, /* 3F */
	{ 0x40, 0x00 }, /* 40 */
	{ 0x41, 0x00 }, /* 41 */
	{ 0x42, 0x00 }, /* 42 */
	{ 0x43, 0x00 }, /* 43 */
	{ 0x44, 0x00 }, /* 44 */
	{ 0x45, 0x00 }, /* 45 */
	{ 0x46, 0x00 }, /* 46 */
	{ 0x47, 0x00 }, /* 47 */
	{ 0x48, 0x00 }, /* 48 */
	{ 0x49, 0x00 }, /* 49 */
	{ 0x4a, 0x00 }, /* 4A */
	{ 0x4b, 0x00 }, /* 4B */

Annotation

Implementation Notes