| 1 |
|
| 2 | |
| 3 | * The MIPI SDCA specification is available for public downloads at
|
| 4 | * https://www.mipi.org/mipi-sdca-v1-0-download
|
| 5 | *
|
| 6 | * Copyright (C) 2025 Cirrus Logic, Inc. and
|
| 7 | * Cirrus Logic International Semiconductor Ltd.
|
| 8 |
|
| 9 |
|
| 10 | #ifndef __SDCA_JACK_H__
|
| 11 | #define __SDCA_JACK_H__
|
| 12 |
|
| 13 | struct sdca_interrupt;
|
| 14 | struct snd_kcontrol;
|
| 15 | struct snd_soc_jack;
|
| 16 |
|
| 17 | |
| 18 | * struct jack_state - Jack state structure to keep data between interrupts
|
| 19 | * @kctl: Pointer to the ALSA control attached to this jack
|
| 20 | * @jack: Pointer to the ASoC jack struct for this jack
|
| 21 | * @mask: Possible reported jack status bits for this jack
|
| 22 |
|
| 23 | struct jack_state {
|
| 24 | struct snd_kcontrol *kctl;
|
| 25 | struct snd_soc_jack *jack;
|
| 26 |
|
| 27 | unsigned int mask;
|
| 28 | };
|
| 29 |
|
| 30 | int sdca_jack_alloc_state(struct sdca_interrupt *interrupt);
|
| 31 | int sdca_jack_init_state(struct sdca_interrupt *interrupt);
|
| 32 | void sdca_jack_free_state(struct sdca_interrupt *interrupt);
|
| 33 |
|
| 34 | int sdca_jack_process(struct sdca_interrupt *interrupt);
|
| 35 | int sdca_jack_set_jack(struct sdca_interrupt_info *info, struct snd_soc_jack *jack);
|
| 36 | int sdca_jack_report(struct sdca_interrupt *interrupt);
|
| 37 |
|
| 38 | #endif |