#include <linux/clk.h>
#include <linux/i2c.h>
#include <linux/module.h>
#include <linux/of_platform.h>
#if IS_ENABLED(CONFIG_SND_AC97_CODEC)
#include <sound/ac97_codec.h>
#endif
#include <sound/pcm_params.h>
#include <sound/soc.h>
#include <sound/jack.h>
#include <sound/simple_card_utils.h>
#include "fsl_esai.h"
#include "fsl_sai.h"
#include "imx-audmux.h"
#include "../codecs/sgtl5000.h"
#include "../codecs/wm8962.h"
#include "../codecs/wm8960.h"
#include "../codecs/wm8994.h"
#include "../codecs/tlv320aic31xx.h"
#include "../codecs/nau8822.h"
#include "../codecs/wm8904.h"
#define DRIVER_NAME …
#define CS427x_SYSCLK_MCLK …
#define RX …
#define TX …
#define DAI_FMT_BASE …
struct codec_priv { … };
struct cpu_priv { … };
struct fsl_asoc_card_priv { … };
static const struct snd_soc_dapm_route audio_map[] = …;
static const struct snd_soc_dapm_route audio_map_ac97[] = …;
static const struct snd_soc_dapm_route audio_map_tx[] = …;
static const struct snd_soc_dapm_route audio_map_rx[] = …;
static const struct snd_soc_dapm_widget fsl_asoc_card_dapm_widgets[] = …;
static bool fsl_asoc_card_is_ac97(struct fsl_asoc_card_priv *priv)
{ … }
static int fsl_asoc_card_hw_params(struct snd_pcm_substream *substream,
struct snd_pcm_hw_params *params)
{ … }
static int fsl_asoc_card_hw_free(struct snd_pcm_substream *substream)
{ … }
static const struct snd_soc_ops fsl_asoc_card_ops = …;
static int be_hw_params_fixup(struct snd_soc_pcm_runtime *rtd,
struct snd_pcm_hw_params *params)
{ … }
static const struct snd_soc_dai_link fsl_asoc_card_dai[] = …;
static int fsl_asoc_card_audmux_init(struct device_node *np,
struct fsl_asoc_card_priv *priv)
{ … }
static int fsl_asoc_card_spdif_init(struct device_node *codec_np[],
struct device_node *cpu_np,
const char *codec_dai_name[],
struct fsl_asoc_card_priv *priv)
{ … }
static int hp_jack_event(struct notifier_block *nb, unsigned long event,
void *data)
{ … }
static struct notifier_block hp_jack_nb = …;
static int mic_jack_event(struct notifier_block *nb, unsigned long event,
void *data)
{ … }
static struct notifier_block mic_jack_nb = …;
static int fsl_asoc_card_late_probe(struct snd_soc_card *card)
{ … }
static int fsl_asoc_card_probe(struct platform_device *pdev)
{ … }
static const struct of_device_id fsl_asoc_card_dt_ids[] = …;
MODULE_DEVICE_TABLE(of, fsl_asoc_card_dt_ids);
static struct platform_driver fsl_asoc_card_driver = …;
module_platform_driver(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_AUTHOR(…) …;
MODULE_ALIAS(…) …;
MODULE_LICENSE(…) …;